Skip to content
Merged
Changes from 1 commit
Commits
Show all changes
67 commits
Select commit Hold shift + click to select a range
d91a5f4
Add Implementable Proposal for AuthenticationFilter
shaun-nx Nov 6, 2025
9047c3e
Update auth header code block
shaun-nx Nov 6, 2025
c937366
Fix pre-commit and lint errors
shaun-nx Nov 6, 2025
1b8bac2
Update Golang API with defaults and CEL validation with kubebuilder
shaun-nx Nov 7, 2025
2f143e9
Add additional defaults and CEL validations
shaun-nx Nov 7, 2025
61f479c
Merge branch 'main' into proposal/authentication-filter
shaun-nx Nov 7, 2025
47ff38b
Fix typos
shaun-nx Nov 7, 2025
40b8224
Update comments in GolangAPI to decribe relative NGINX directives
shaun-nx Nov 7, 2025
24966b8
Update API and Security Considerations for ReferenceGrant integration
shaun-nx Nov 7, 2025
ecceb93
Merge branch 'main' into proposal/authentication-filter
shaun-nx Nov 7, 2025
da1b17e
Fix pre-commit errors
shaun-nx Nov 7, 2025
38dd8f7
Fix typos and grammer
shaun-nx Nov 7, 2025
e362745
Update BasicAuth AIP and examples to use `secretRef`
shaun-nx Nov 7, 2025
dd5aaa8
Update KeyCache to use v1alpha1.Duration
shaun-nx Nov 7, 2025
bf3ed2b
Merge branch 'main' into proposal/authentication-filter
shaun-nx Nov 14, 2025
eb49b32
Merge branch 'main' into proposal/authentication-filter
shaun-nx Nov 18, 2025
a86a3ae
Move kubebuilder validation, remove mountpath and configmap options, …
shaun-nx Nov 18, 2025
79b957d
Update jwks_uri internal uri
shaun-nx Nov 19, 2025
e0ec4fb
Fix typos
shaun-nx Nov 19, 2025
d3ebed4
Fix comment indentation
shaun-nx Nov 19, 2025
4f1c893
Adjust struct indentation
shaun-nx Nov 19, 2025
5ff7389
Pre-commit check
shaun-nx Nov 19, 2025
dd24287
Ensure no default for JWT key mode
shaun-nx Nov 19, 2025
14b84a9
Use SecretObjectReference for secretRef, remove references to ConfigM…
shaun-nx Nov 19, 2025
8526c7f
Add references to NGINX directives
shaun-nx Nov 19, 2025
93486eb
Remove `key` from `secretRef`
shaun-nx Nov 19, 2025
d91b389
Remove trailing whitespace
shaun-nx Nov 19, 2025
b6fb76b
Add additional comments
shaun-nx Nov 19, 2025
73594af
Update comments and restructure api
shaun-nx Nov 19, 2025
7aede4c
Update security details on headers
shaun-nx Nov 19, 2025
acbb54c
Merge branch 'main' into proposal/authentication-filter
shaun-nx Nov 19, 2025
4aae8e7
Merge branch 'main' into proposal/authentication-filter
shaun-nx Nov 20, 2025
1029c3e
Remove JWT key word from fields
shaun-nx Nov 20, 2025
c864630
Add default Real for basic auth
shaun-nx Nov 20, 2025
ef57f2a
Fix typo
shaun-nx Nov 20, 2025
22d2726
Update Status section on using NGINX OSS with JWT auth
shaun-nx Nov 20, 2025
9e6b3c9
Set optioanl JWT fields as stretch goals
shaun-nx Nov 20, 2025
21b5611
Add stretch goals
shaun-nx Nov 20, 2025
65c1adc
Update secret ref to use LocalObjectReferenceWithKey struct
shaun-nx Nov 20, 2025
a0c8c04
Fix typo and update validation section
shaun-nx Nov 20, 2025
b3fb4a0
Merge branch 'main' into proposal/authentication-filter
shaun-nx Nov 25, 2025
bc9f915
Correct typos and spacing
shaun-nx Nov 25, 2025
1a83425
Add CEL validation for `LocalObjectReferenceWithKey` struct
shaun-nx Nov 25, 2025
2d7c5ee
Merge branch 'main' into proposal/authentication-filter
shaun-nx Nov 25, 2025
7c7dc79
Code review changes
shaun-nx Nov 25, 2025
623930f
Merge branch 'main' into proposal/authentication-filter
shaun-nx Nov 25, 2025
f4da411
Update KeyMode and FileKeySource variables
shaun-nx Nov 25, 2025
d5a68bd
Update LocalObjectReferenceWithKey
shaun-nx Nov 25, 2025
af626ac
Update docs/proposals/authentication-filter.md
shaun-nx Nov 26, 2025
9845608
Update docs/proposals/authentication-filter.md
shaun-nx Nov 26, 2025
1316068
Update docs/proposals/authentication-filter.md
shaun-nx Nov 26, 2025
d9268a0
Update docs/proposals/authentication-filter.md
shaun-nx Nov 26, 2025
f931a65
Update defaults and add details describing Realms
shaun-nx Nov 26, 2025
70caae2
Change `LocalObjectReferenceWithKey` to `LocalObjectReference`
shaun-nx Nov 26, 2025
33e2916
Add details on how files are generated for basic and jwt auth
shaun-nx Nov 26, 2025
13fc5ba
Pre-commit checks
shaun-nx Nov 26, 2025
91c5e1e
Update JWT keytype and file
shaun-nx Nov 26, 2025
1b2dc5f
Use permalinks
shaun-nx Nov 26, 2025
7b88681
Update docs/proposals/authentication-filter.md
shaun-nx Nov 26, 2025
601b83d
Update Status section
shaun-nx Nov 26, 2025
35736cf
Fix Gateway API ExternalAuthFilter GEP reference
shaun-nx Nov 26, 2025
547e4be
Fix typos
shaun-nx Nov 26, 2025
3b4e5d8
Set Realm as a required field. Remove default for leeway
shaun-nx Nov 26, 2025
30f490b
Remove `omitempty` from required fields
shaun-nx Nov 26, 2025
07d8a82
Remove `Path` config from JWKCache
shaun-nx Nov 26, 2025
1ab9708
Add details on secret creation. Make `key` optional for secretRef
shaun-nx Nov 26, 2025
b97ebe6
Remove `key` for secretRef
shaun-nx Nov 26, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 19 additions & 6 deletions docs/proposals/authentication-filter.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,21 @@ This document also focus on HTTP Basic Authentication and JWT Authentication. Ot
| **JWT (JSON Web Token)** | ❌ | ✅ | [ngx_http_auth_jwt_module](https://nginx.org/en/docs/http/ngx_http_auth_jwt_module.html) | Tokens are used for stateless authentication between client and server. |
| **OpenID Connect** | ❌ | ✅ | [ngx_http_oidc_module](https://nginx.org/en/docs/http/ngx_http_oidc_module.html)| Allows authentication through third-party providers like Google. |

### Understanding authentication terminoligy

#### Realms

[RFC 7617](https://www.rfc-editor.org/rfc/rfc7617) gives an overview of the Realm parameter, which is used by `auth_basic` and `auth_jwt` directives in NGINX.

```text
The realm value is a free-form string
that can only be compared for equality with other realms on that
server. The server will service the request only if it can validate
the user-id and password for the protection space applying to the
requested resource.
```


## API, Customer Driven Interfaces, and User Experience

This portion of the proposal will cover API design and interaction experience for use of Basic Auth and JWT.
Expand Down Expand Up @@ -144,7 +159,7 @@ type BasicAuth struct {
// Also configures "realm="<realm_value>" in WWW-Authenticate header in error page location.
//
// +optional
// +kubebuilder:default="Restricted"
// +kubebuilder:default=""
Realm *string `json:"realm,omitempty"`

// OnFailure customizes the 401 response for failed authentication.
Expand Down Expand Up @@ -173,7 +188,7 @@ type JWTAuth struct {
// Configures "realm="<realm_value>" in WWW-Authenticate header in error page location.
//
// +optional
// +kubebuilder:default="Restricted"
// +kubebuilder:default=""
Realm *string `json:"realm,omitempty"`

// Mode selects how JWT keys are provided: local file or remote JWKS.
Expand Down Expand Up @@ -502,7 +517,7 @@ http {

For JWT Auth, there is two options.

1. Local JWKS file stored as as a Secret or as a ConfigMap
1. Local JWKS file stored as as a Secret
2. Remote JWKS from an IdP provider like Keycloak

#### Example JWT AuthenticationFilter with Local JWKS
Expand Down Expand Up @@ -558,7 +573,7 @@ spec:
scheme: Bearer
```

#### Secret referenced by filter (if using secretRef)
#### Secret referenced by filter

```yaml
apiVersion: v1
Expand All @@ -570,8 +585,6 @@ data:
jwks.json: ewogICJrZXlzIjogWwogICAgewogICAgICAia3R5IjogIlJTQSIsCiAgICAgICJ1c2UiOiAic2lnIiwKICAgICAgImtpZCI6ICJleGFtcGxlLWtleS1pZCIsCiAgICAgICJhbGciOiAiUlMyNTYiLAogICAgICAibiI6ICJiYXNlNjR1cmwtbW9kdWx1cyIsCiAgICAgICJlIjogIkFRQUIiCiAgICB9CiAgXQp9Cg==
```

Note: Secret data values must be base64-encoded and are decoded by the kubelet on mount, producing a valid jwks.json file. ConfigMap data values are plain text and should contain the raw JSON (not base64).

#### HTTPRoute that will reference this filter

```yaml
Expand Down
Loading