@@ -241,6 +241,8 @@ note that Gzipped responses from `check_session_url` are not supported, and will
241
241
`subject`. Example : ` identity.id` for `{ "identity": { "id": "1234" } }`.
242
242
- ` additional_headers` (map[string]string, optional - defaults empty) - If set, you can either add additional headers or override
243
243
existing ones.
244
+ - ` forward_http_headers` ([]string, optional - defaults ["Authorization", "Cookie"]) - If set, you can specify which headers will be
245
+ forwarded.
244
246
245
247
` ` ` yaml
246
248
# Global configuration file oathkeeper.yml
@@ -266,6 +268,24 @@ authenticators:
266
268
- sessionid
267
269
` ` `
268
270
271
+ ` ` ` yaml
272
+ # Some Access Rule: access-rule-1.yaml
273
+ id: access-rule-1
274
+ # match: ...
275
+ # upstream: ...
276
+ authenticators:
277
+ - handler: cookie_session
278
+ config:
279
+ check_session_url: https://session-store-host
280
+ only:
281
+ - sessionid
282
+ forward_http_headers:
283
+ - Connect
284
+ - Authorization
285
+ - Cookie
286
+ - X-Forwarded-For
287
+ ` ` `
288
+
269
289
` ` ` yaml
270
290
# Some Access Rule Preserving Path: access-rule-2.yaml
271
291
id: access-rule-2
@@ -343,6 +363,8 @@ note that Gzipped responses from `check_session_url` are not supported, and will
343
363
request authentication. It can't be set along with `header` or `cookie`.
344
364
- ` cookie` (string, required, one of) - The cookie (case sensitive) that must contain a Bearer token for request authentication.
345
365
It can't be set along with `header` or `query_parameter`
366
+ - ` forward_http_headers` ([]string, optional - defaults ["Authorization", "Cookie"]) - If set, you can specify which headers will be
367
+ forwarded.
346
368
347
369
` ` ` yaml
348
370
# Global configuration file oathkeeper.yml
@@ -395,6 +417,10 @@ authenticators:
395
417
# cookie: auth-token
396
418
preserve_path: true
397
419
preserve_query: true
420
+ forward_http_headers:
421
+ - Authorization
422
+ - Cookie
423
+ - X-Forwarded-For
398
424
` ` `
399
425
400
426
# ## `bearer_token` Access Rule Example
0 commit comments