Skip to content

Commit 1c6843d

Browse files
committed
Re-generate CRD
1 parent da97201 commit 1c6843d

File tree

3 files changed

+34
-12
lines changed

3 files changed

+34
-12
lines changed

apis/v1alpha1/authenticationfilter_types.go

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,11 @@ type AuthenticationFilterList struct {
4242
//
4343
//nolint:lll
4444
type AuthenticationFilterSpec struct {
45+
// Basic configures HTTP Basic Authentication.
4546
Basic BasicAuth `json:"basic"`
46-
Type AuthType `json:"type"`
47+
48+
// Type selects the authentication mechanism.
49+
Type AuthType `json:"type"`
4750
}
4851

4952
// AuthType defines the authentication mechanism.
@@ -56,9 +59,18 @@ const (
5659

5760
// BasicAuth configures HTTP Basic Authentication.
5861
type BasicAuth struct {
62+
// OnFailure customizes the 401 response for failed authentication.
63+
//
64+
// +optional
5965
OnFailure *AuthFailureResponse `json:"onFailure,omitempty"`
66+
67+
// SecretRef allows referencing a Secret in the same namespace
6068
SecretRef LocalObjectReference `json:"secretRef"`
61-
Realm string `json:"realm"`
69+
70+
// Realm used by NGINX `auth_basic` directive.
71+
// https://nginx.org/en/docs/http/ngx_http_auth_basic_module.html#auth_basic
72+
// Also configures "realm="<realm_value>" in WWW-Authenticate header in error page location.
73+
Realm string `json:"realm"`
6274
}
6375

6476
// LocalObjectReference specifies a local Kubernetes object.

config/crd/bases/gateway.nginx.org_authenticationfilters.yaml

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -51,10 +51,11 @@ spec:
5151
description: Spec defines the desired state of the AuthenticationFilter.
5252
properties:
5353
basic:
54-
description: BasicAuth configures HTTP Basic Authentication.
54+
description: Basic configures HTTP Basic Authentication.
5555
properties:
5656
onFailure:
57-
description: AuthFailureResponse customizes 401/403 failures.
57+
description: OnFailure customizes the 401 response for failed
58+
authentication.
5859
properties:
5960
bodyPolicy:
6061
default: Unauthorized
@@ -87,10 +88,14 @@ spec:
8788
rule: self in [401, 403]
8889
type: object
8990
realm:
91+
description: |-
92+
Realm used by NGINX `auth_basic` directive.
93+
https://nginx.org/en/docs/http/ngx_http_auth_basic_module.html#auth_basic
94+
Also configures "realm="<realm_value>" in WWW-Authenticate header in error page location.
9095
type: string
9196
secretRef:
92-
description: LocalObjectReference specifies a local Kubernetes
93-
object.
97+
description: SecretRef allows referencing a Secret in the same
98+
namespace
9499
properties:
95100
name:
96101
type: string
@@ -102,7 +107,7 @@ spec:
102107
- secretRef
103108
type: object
104109
type:
105-
description: AuthType defines the authentication mechanism.
110+
description: Type selects the authentication mechanism.
106111
enum:
107112
- Basic
108113
type: string

deploy/crds.yaml

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -50,10 +50,11 @@ spec:
5050
description: Spec defines the desired state of the AuthenticationFilter.
5151
properties:
5252
basic:
53-
description: BasicAuth configures HTTP Basic Authentication.
53+
description: Basic configures HTTP Basic Authentication.
5454
properties:
5555
onFailure:
56-
description: AuthFailureResponse customizes 401/403 failures.
56+
description: OnFailure customizes the 401 response for failed
57+
authentication.
5758
properties:
5859
bodyPolicy:
5960
default: Unauthorized
@@ -86,10 +87,14 @@ spec:
8687
rule: self in [401, 403]
8788
type: object
8889
realm:
90+
description: |-
91+
Realm used by NGINX `auth_basic` directive.
92+
https://nginx.org/en/docs/http/ngx_http_auth_basic_module.html#auth_basic
93+
Also configures "realm="<realm_value>" in WWW-Authenticate header in error page location.
8994
type: string
9095
secretRef:
91-
description: LocalObjectReference specifies a local Kubernetes
92-
object.
96+
description: SecretRef allows referencing a Secret in the same
97+
namespace
9398
properties:
9499
name:
95100
type: string
@@ -101,7 +106,7 @@ spec:
101106
- secretRef
102107
type: object
103108
type:
104-
description: AuthType defines the authentication mechanism.
109+
description: Type selects the authentication mechanism.
105110
enum:
106111
- Basic
107112
type: string

0 commit comments

Comments
 (0)