Skip to content

Commit 3be1229

Browse files
committed
docs: add oidc-auth allow_query_token docs and update test badge
1 parent 95267bc commit 3be1229

2 files changed

Lines changed: 4 additions & 2 deletions

File tree

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
<a href="https://github.com/barbacane-dev/barbacane/actions/workflows/ci.yml"><img src="https://github.com/barbacane-dev/barbacane/actions/workflows/ci.yml/badge.svg" alt="CI"></a>
1111
<a href="https://docs.barbacane.dev"><img src="https://img.shields.io/badge/docs-docs.barbacane.dev-blue" alt="Documentation"></a>
1212
<img src="https://img.shields.io/badge/unit%20tests-399%20passing-brightgreen" alt="Unit Tests">
13-
<img src="https://img.shields.io/badge/plugin%20tests-642%20passing-brightgreen" alt="Plugin Tests">
13+
<img src="https://img.shields.io/badge/plugin%20tests-649%20passing-brightgreen" alt="Plugin Tests">
1414
<img src="https://img.shields.io/badge/integration%20tests-192%20passing-brightgreen" alt="Integration Tests">
1515
<img src="https://img.shields.io/badge/cli%20tests-16%20passing-brightgreen" alt="CLI Tests">
1616
<img src="https://img.shields.io/badge/ui%20tests-44%20passing-brightgreen" alt="UI Tests">

docs/guide/middlewares.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -280,6 +280,7 @@ x-barbacane-middlewares:
280280
clock_skew_seconds: 60
281281
jwks_refresh_seconds: 300
282282
timeout: 5.0
283+
allow_query_token: false # RFC 6750 §2.3 query param fallback
283284
```
284285

285286
#### Configuration
@@ -293,10 +294,11 @@ x-barbacane-middlewares:
293294
| `clock_skew_seconds` | integer | `60` | Clock skew tolerance for `exp`/`nbf` validation |
294295
| `jwks_refresh_seconds` | integer | `300` | How often to refresh JWKS keys (seconds) |
295296
| `timeout` | float | `5.0` | HTTP timeout for discovery and JWKS calls (seconds) |
297+
| `allow_query_token` | boolean | `false` | Allow token extraction from the `access_token` query parameter ([RFC 6750 §2.3](https://datatracker.ietf.org/doc/html/rfc6750#section-2.3)). Use with caution — tokens in URLs risk leaking via logs and referer headers. |
296298

297299
#### How It Works
298300

299-
1. Extracts the Bearer token from the `Authorization` header
301+
1. Extracts the Bearer token from the `Authorization` header (or from the `access_token` query parameter if `allow_query_token` is enabled and no header is present)
300302
2. Parses the JWT header to determine the signing algorithm and key ID (`kid`)
301303
3. Fetches `{issuer_url}/.well-known/openid-configuration` (cached)
302304
4. Fetches the JWKS endpoint from the discovery document (cached with TTL)

0 commit comments

Comments
 (0)