You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Using `client_secret_jwt` or `private_key_jwt` authentication methods ensures that a client secret is not sent to the OIDC provider, thereby avoiding the risk of interception by a 'man-in-the-middle' attack.
222
222
223
223
[[jwt-bearer-client-authentication]]
224
+
==== JWT Bearer
225
+
224
226
.Example: Using a JWT Bearer token to authenticate a client
225
227
226
228
[source,properties]
@@ -235,11 +237,14 @@ For more information, see the link:https://www.rfc-editor.org/rfc/rfc7523#sectio
235
237
<2> Path to a JWT bearer token.
236
238
Quarkus loads a new token from the filesystem and reloads it when the token expires.
237
239
238
-
.Example: Using a SPIFFE JWT-SVID token to authenticate a client
240
+
[[spiffe-jwt-client-authentication]]
241
+
==== SPIFFE JWT-SVID
239
242
240
243
link:https://spiffe.io[SPIFFE] (Secure Production Identity Framework for Everyone) JWT-SVID tokens can be used as client assertions for client authentication.
241
244
When the JWT source is set to `spiffe-jwt`, the `client_assertion_type` parameter is set to `urn:ietf:params:oauth:client-assertion-type:jwt-spiffe` and the token's `sub` claim must contain a valid SPIFFE ID starting with `spiffe://`.
242
245
246
+
.Example: Using a SPIFFE JWT-SVID token to authenticate a client
<1> Use a SPIFFE JWT-SVID token to authenticate the OIDC provider client.
251
256
<2> Path to a SPIFFE JWT-SVID token.
257
+
252
258
Quarkus loads a new token from the filesystem and reloads it when the token expires.
253
259
The token's `sub` claim is verified to start with the `spiffe://` scheme.
254
260
255
-
When no `token-path` is set but the xref:security-spiffe-client.adoc[SPIFFE Client extension] is present, Quarkus retrieves JWT-SVID tokens directly from the local SPIRE Agent instead of reading them from the file system.
261
+
When no `quarkus.oidc.credentials.jwt.token-path` is set but the xref:security-spiffe-client.adoc[SPIFFE Client extension] is present, Quarkus retrieves JWT-SVID tokens directly from the local SPIRE Agent instead of reading them from the file system.
262
+
256
263
Tokens are cached and refreshed automatically before they expire.
You can also use `quarkus.oidc.credentials.jwt.audience` to customize a SPIFFE JWT-SVID audience when `quarkus.oidc.credentials.jwt.source=spiffe-jwt` but no `quarkus.oidc.credentials.jwt.token-path` is set and the xref:security-spiffe-client.adoc[SPIFFE Client extension] is present. See the <<spiffe-jwt-client-authentication>> for more information.
308
+
300
309
==== Apple POST JWT
301
310
302
311
The Apple OIDC provider uses a `client_secret_post` method, in which the secret is a JWT produced with a `private_key_jwt` authentication method, but with the Apple account-specific issuer and subject claims.
Copy file name to clipboardExpand all lines: docs/src/main/asciidoc/security-oidc-expanded-configuration.adoc
+7-5Lines changed: 7 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -278,22 +278,20 @@ All other properties listed in the table above can be used to customize JWT clai
278
278
In the typical OIDC client authentication case, the token audience defaults to the OIDC token endpoint address.
279
279
When `quarkus.oidc.credentials.jwt.source` is `spiffe-jwt`, it defaults to `quarkus.oidc.auth-server-url`.
280
280
281
+
==== JWT Bearer and SPIFFE JWT-SVID
281
282
282
-
==== JWT Bearer
283
-
284
-
By default, when a client JWT authentication token must be produced, it is generated by Quarkus OIDC. In some cases, the JWT bearer token may be provided and periodically updated by Kubernetes.
283
+
By default, when a client JWT authentication token must be produced, it is generated by Quarkus OIDC. A JWT token may also be provided and periodically updated by Kubernetes or SPIFFE Spire agent.
285
284
286
285
.JWT source properties
287
286
[options="header"]
288
287
|====
289
288
|Property name |Default |Description
290
289
291
290
|quarkus.oidc.credentials.jwt.source |Generated by quarkus-oidc| How the authentication JWT token is produced
292
-
|quarkus.oidc.credentials.jwt.token-path ||If the token source is BEARER then this path must point to a JWT bearer token in the file system
291
+
|quarkus.oidc.credentials.jwt.token-path ||Must point to a token file when the source is `bearer` but is optional when the source is `spiffe-jwt`
293
292
|====
294
293
295
294
Set `quarkus.oidc.credentials.jwt.source=bearer` if the client authentication token is provided by Kubernetes, and use `quarkus.oidc.credentials.jwt.token-path` to point to the file resource containing this token.
296
-
Set `quarkus.oidc.credentials.for-all-endpoints=true` when the OIDC provider enforces authenticated access to the discovery and JWKS endpoints. See xref:security-oidc-code-flow-authentication.adoc#authenticated-access-to-all-oidc-endpoints[Authenticated access to all OIDC endpoints] for more information.
297
295
298
296
Set `quarkus.oidc.credentials.jwt.source=spiffe-jwt` to use a SPIFFE JWT-SVID token as the client assertion.
299
297
When `quarkus.oidc.credentials.jwt.token-path` is set, the token is read from the file system and reloaded when it expires.
@@ -321,6 +319,10 @@ When the tokens must be introspected, some providers may require the introspecti
321
319
322
320
Currently, introspection credentials, if configured, can only be sent as HTTP POST form parameters.
323
321
322
+
=== Authenticated access to all OIDC endpoints
323
+
324
+
Set `quarkus.oidc.credentials.for-all-endpoints=true` when the OIDC provider enforces authenticated access to the discovery and JWKS endpoints. See xref:security-oidc-code-flow-authentication.adoc#authenticated-access-to-all-oidc-endpoints[Authenticated access to all OIDC endpoints] for more information.
0 commit comments