diff --git a/api/v1alpha1/tls_types.go b/api/v1alpha1/tls_types.go
index d6eb14c638f..18729f0a68a 100644
--- a/api/v1alpha1/tls_types.go
+++ b/api/v1alpha1/tls_types.go
@@ -6,7 +6,7 @@
package v1alpha1
import (
- corev1 "k8s.io/api/core/v1"
+ gwapiv1 "sigs.k8s.io/gateway-api/apis/v1"
)
// +kubebuilder:validation:XValidation:rule="has(self.minVersion) && self.minVersion == '1.3' ? !has(self.ciphers) : true", message="setting ciphers has no effect if the minimum possible TLS version is 1.3"
@@ -115,7 +115,7 @@ type ClientValidationContext struct {
// the Certificate Authorities that can be used
// as a trust anchor to validate the certificates presented by the client.
//
- // A single reference to a Kubernetes ConfigMap,
+ // A single reference to a Kubernetes ConfigMap or a Kubernetes Secret,
// with the CA certificate in a key named `ca.crt` is currently supported.
//
// References to a resource in different namespace are invalid UNLESS there
@@ -124,5 +124,5 @@ type ClientValidationContext struct {
//
// +kubebuilder:validation:MaxItems=8
// +optional
- CACertificateRefs []corev1.ObjectReference `json:"caCertificateRefs,omitempty"`
+ CACertificateRefs []gwapiv1.SecretObjectReference `json:"caCertificateRefs,omitempty"`
}
diff --git a/api/v1alpha1/zz_generated.deepcopy.go b/api/v1alpha1/zz_generated.deepcopy.go
index abd1571ac13..42c79369168 100644
--- a/api/v1alpha1/zz_generated.deepcopy.go
+++ b/api/v1alpha1/zz_generated.deepcopy.go
@@ -510,8 +510,10 @@ func (in *ClientValidationContext) DeepCopyInto(out *ClientValidationContext) {
*out = *in
if in.CACertificateRefs != nil {
in, out := &in.CACertificateRefs, &out.CACertificateRefs
- *out = make([]corev1.ObjectReference, len(*in))
- copy(*out, *in)
+ *out = make([]apisv1.SecretObjectReference, len(*in))
+ for i := range *in {
+ (*in)[i].DeepCopyInto(&(*out)[i])
+ }
}
}
diff --git a/charts/gateway-helm/crds/generated/gateway.envoyproxy.io_clienttrafficpolicies.yaml b/charts/gateway-helm/crds/generated/gateway.envoyproxy.io_clienttrafficpolicies.yaml
index 69a51c47cc1..0af72696802 100644
--- a/charts/gateway-helm/crds/generated/gateway.envoyproxy.io_clienttrafficpolicies.yaml
+++ b/charts/gateway-helm/crds/generated/gateway.envoyproxy.io_clienttrafficpolicies.yaml
@@ -243,77 +243,56 @@ spec:
to Kubernetes objects that contain TLS certificates of the
Certificate Authorities that can be used as a trust anchor
to validate the certificates presented by the client. \n
- A single reference to a Kubernetes ConfigMap, with the CA
- certificate in a key named `ca.crt` is currently supported.
- \n References to a resource in different namespace are invalid
- UNLESS there is a ReferenceGrant in the target namespace
- that allows the certificate to be attached."
+ A single reference to a Kubernetes ConfigMap or a Kubernetes
+ Secret, with the CA certificate in a key named `ca.crt`
+ is currently supported. \n References to a resource in different
+ namespace are invalid UNLESS there is a ReferenceGrant in
+ the target namespace that allows the certificate to be attached."
items:
- description: "ObjectReference contains enough information
- to let you inspect or modify the referred object. ---
- New uses of this type are discouraged because of difficulty
- describing its usage when embedded in APIs. 1. Ignored
- fields. It includes many fields which are not generally
- honored. For instance, ResourceVersion and FieldPath
- are both very rarely valid in actual usage. 2. Invalid
- usage help. It is impossible to add specific help for
- individual usage. In most embedded usages, there are
- particular restrictions like, \"must refer only to types
- A and B\" or \"UID not honored\" or \"name must be restricted\".
- Those cannot be well described when embedded. 3. Inconsistent
- validation. Because the usages are different, the validation
- rules are different by usage, which makes it hard for
- users to predict what will happen. 4. The fields are both
- imprecise and overly precise. Kind is not a precise mapping
- to a URL. This can produce ambiguity during interpretation
- and require a REST mapping. In most cases, the dependency
- is on the group,resource tuple and the version of the
- actual struct is irrelevant. 5. We cannot easily change
- it. Because this type is embedded in many locations,
- updates to this type will affect numerous schemas. Don't
- make new APIs embed an underspecified API type they do
- not control. \n Instead of using this type, create a locally
- provided and used type that is well-focused on your reference.
- For example, ServiceReferences for admission registration:
- https://github.com/kubernetes/api/blob/release-1.17/admissionregistration/v1/types.go#L533
- ."
+ description: "SecretObjectReference identifies an API object
+ including its namespace, defaulting to Secret. \n The
+ API object must be valid in the cluster; the Group and
+ Kind must be registered in the cluster for this reference
+ to be valid. \n References to objects with invalid Group
+ and Kind are not valid, and must be rejected by the implementation,
+ with appropriate Conditions set on the containing object."
properties:
- apiVersion:
- description: API version of the referent.
- type: string
- fieldPath:
- description: 'If referring to a piece of an object instead
- of an entire object, this string should contain a
- valid JSON/Go field access statement, such as desiredState.manifest.containers[2].
- For example, if the object reference is to a container
- within a pod, this would take on a value like: "spec.containers{name}"
- (where "name" refers to the name of the container
- that triggered the event) or if no container name
- is specified "spec.containers[2]" (container with
- index 2 in this pod). This syntax is chosen only to
- have some well-defined way of referencing a part of
- an object. TODO: this design is not final and this
- field is subject to change in the future.'
+ group:
+ default: ""
+ description: Group is the group of the referent. For
+ example, "gateway.networking.k8s.io". When unspecified
+ or empty string, core API group is inferred.
+ maxLength: 253
+ pattern: ^$|^[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*$
type: string
kind:
- description: 'Kind of the referent. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
+ default: Secret
+ description: Kind is kind of the referent. For example
+ "Secret".
+ maxLength: 63
+ minLength: 1
+ pattern: ^[a-zA-Z]([-a-zA-Z0-9]*[a-zA-Z0-9])?$
type: string
name:
- description: 'Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names'
+ description: Name is the name of the referent.
+ maxLength: 253
+ minLength: 1
type: string
namespace:
- description: 'Namespace of the referent. More info:
- https://kubernetes.io/docs/concepts/overview/working-with-objects/namespaces/'
- type: string
- resourceVersion:
- description: 'Specific resourceVersion to which this
- reference is made, if any. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#concurrency-control-and-consistency'
- type: string
- uid:
- description: 'UID of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#uids'
+ description: "Namespace is the namespace of the referenced
+ object. When unspecified, the local namespace is inferred.
+ \n Note that when a namespace different than the local
+ namespace is specified, a ReferenceGrant object is
+ required in the referent namespace to allow that namespace's
+ owner to accept the reference. See the ReferenceGrant
+ documentation for details. \n Support: Core"
+ maxLength: 63
+ minLength: 1
+ pattern: ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$
type: string
+ required:
+ - name
type: object
- x-kubernetes-map-type: atomic
maxItems: 8
type: array
type: object
diff --git a/charts/gateway-helm/templates/_rbac.tpl b/charts/gateway-helm/templates/_rbac.tpl
index 40bd819ee78..9c80ff3a868 100644
--- a/charts/gateway-helm/templates/_rbac.tpl
+++ b/charts/gateway-helm/templates/_rbac.tpl
@@ -29,6 +29,7 @@ Namespaced
apiGroups:
- ""
resources:
+- configmaps
- secrets
- services
verbs:
diff --git a/internal/gatewayapi/clienttrafficpolicy.go b/internal/gatewayapi/clienttrafficpolicy.go
index db88d9dec6b..b6ef8f345fa 100644
--- a/internal/gatewayapi/clienttrafficpolicy.go
+++ b/internal/gatewayapi/clienttrafficpolicy.go
@@ -32,11 +32,12 @@ func hasSectionName(policy *egv1a1.ClientTrafficPolicy) bool {
return policy.Spec.TargetRef.SectionName != nil
}
-func (t *Translator) ProcessClientTrafficPolicies(clientTrafficPolicies []*egv1a1.ClientTrafficPolicy,
+func (t *Translator) ProcessClientTrafficPolicies(resources *Resources,
gateways []*GatewayContext,
xdsIR XdsIRMap, infraIR InfraIRMap) []*egv1a1.ClientTrafficPolicy {
var res []*egv1a1.ClientTrafficPolicy
+ clientTrafficPolicies := resources.ClientTrafficPolicies
// Sort based on timestamp
sort.Slice(clientTrafficPolicies, func(i, j int) bool {
return clientTrafficPolicies[i].CreationTimestamp.Before(&(clientTrafficPolicies[j].CreationTimestamp))
@@ -93,7 +94,7 @@ func (t *Translator) ProcessClientTrafficPolicies(clientTrafficPolicies []*egv1a
var err error
for _, l := range gateway.listeners {
if string(l.Name) == section {
- err = t.translateClientTrafficPolicyForListener(&policy.Spec, l, xdsIR, infraIR)
+ err = t.translateClientTrafficPolicyForListener(policy, l, xdsIR, infraIR, resources)
break
}
}
@@ -180,7 +181,7 @@ func (t *Translator) ProcessClientTrafficPolicies(clientTrafficPolicies []*egv1a
continue
}
- err = t.translateClientTrafficPolicyForListener(&policy.Spec, l, xdsIR, infraIR)
+ err = t.translateClientTrafficPolicyForListener(policy, l, xdsIR, infraIR, resources)
}
if err != nil {
@@ -286,7 +287,8 @@ func resolveCTPolicyTargetRef(policy *egv1a1.ClientTrafficPolicy, gateways []*Ga
return gateway
}
-func (t *Translator) translateClientTrafficPolicyForListener(policySpec *egv1a1.ClientTrafficPolicySpec, l *ListenerContext, xdsIR XdsIRMap, infraIR InfraIRMap) error {
+func (t *Translator) translateClientTrafficPolicyForListener(policy *egv1a1.ClientTrafficPolicy, l *ListenerContext,
+ xdsIR XdsIRMap, infraIR InfraIRMap, resources *Resources) error {
// Find IR
irKey := irStringKey(l.gateway.Namespace, l.gateway.Name)
// It must exist since we've already finished processing the gateways
@@ -308,27 +310,27 @@ func (t *Translator) translateClientTrafficPolicyForListener(policySpec *egv1a1.
// IR must exist since we're past validation
if httpIR != nil {
// Translate TCPKeepalive
- translateListenerTCPKeepalive(policySpec.TCPKeepalive, httpIR)
+ translateListenerTCPKeepalive(policy.Spec.TCPKeepalive, httpIR)
// Translate Proxy Protocol
- translateListenerProxyProtocol(policySpec.EnableProxyProtocol, httpIR)
+ translateListenerProxyProtocol(policy.Spec.EnableProxyProtocol, httpIR)
// Translate Client IP Detection
- translateClientIPDetection(policySpec.ClientIPDetection, httpIR)
+ translateClientIPDetection(policy.Spec.ClientIPDetection, httpIR)
// Translate Header Settings
- translateListenerHeaderSettings(policySpec.Headers, httpIR)
+ translateListenerHeaderSettings(policy.Spec.Headers, httpIR)
// Translate Path Settings
- translatePathSettings(policySpec.Path, httpIR)
+ translatePathSettings(policy.Spec.Path, httpIR)
// Translate HTTP1 Settings
- if err := translateHTTP1Settings(policySpec.HTTP1, httpIR); err != nil {
+ if err := translateHTTP1Settings(policy.Spec.HTTP1, httpIR); err != nil {
return err
}
// enable http3 if set and TLS is enabled
- if httpIR.TLS != nil && policySpec.HTTP3 != nil {
+ if httpIR.TLS != nil && policy.Spec.HTTP3 != nil {
httpIR.HTTP3 = &ir.HTTP3Settings{}
var proxyListenerIR *ir.ProxyListener
for _, proxyListener := range infraIR[irKey].Proxy.Listeners {
@@ -343,7 +345,9 @@ func (t *Translator) translateClientTrafficPolicyForListener(policySpec *egv1a1.
}
// Translate TLS parameters
- translateListenerTLSParameters(policySpec.TLS, httpIR)
+ if err := t.translateListenerTLSParameters(policy, httpIR, resources); err != nil {
+ return err
+ }
}
return nil
}
@@ -452,13 +456,17 @@ func translateHTTP1Settings(http1Settings *egv1a1.HTTP1Settings, httpIR *ir.HTTP
return nil
}
-func translateListenerTLSParameters(tlsParams *egv1a1.TLSSettings, httpIR *ir.HTTPListener) {
+func (t *Translator) translateListenerTLSParameters(policy *egv1a1.ClientTrafficPolicy,
+ httpIR *ir.HTTPListener, resources *Resources) error {
// Return if this listener isn't a TLS listener. There has to be
// at least one certificate defined, which would cause httpIR to
// have a TLS structure.
if httpIR.TLS == nil {
- return
+ return nil
}
+
+ tlsParams := policy.Spec.TLS
+
// Make sure that the negotiated TLS protocol version is as expected if TLS is used,
// regardless of if TLS parameters were used in the ClientTrafficPolicy or not
httpIR.TLS.MinVersion = ptr.To(ir.TLSv12)
@@ -473,10 +481,12 @@ func translateListenerTLSParameters(tlsParams *egv1a1.TLSSettings, httpIR *ir.HT
httpIR.TLS.ALPNProtocols[i] = string(tlsParams.ALPNProtocols[i])
}
}
+
// Return early if not set
if tlsParams == nil {
- return
+ return nil
}
+
if tlsParams.MinVersion != nil {
httpIR.TLS.MinVersion = ptr.To(ir.TLSVersion(*tlsParams.MinVersion))
}
@@ -492,4 +502,55 @@ func translateListenerTLSParameters(tlsParams *egv1a1.TLSSettings, httpIR *ir.HT
if len(tlsParams.SignatureAlgorithms) > 0 {
httpIR.TLS.SignatureAlgorithms = tlsParams.SignatureAlgorithms
}
+
+ if tlsParams.ClientValidation != nil {
+ from := crossNamespaceFrom{
+ group: egv1a1.GroupName,
+ kind: KindClientTrafficPolicy,
+ namespace: policy.Namespace,
+ }
+
+ irCACert := &ir.TLSCACertificate{
+ Name: irTLSCACertName(policy.Namespace, policy.Name),
+ }
+
+ for _, caCertRef := range tlsParams.ClientValidation.CACertificateRefs {
+ if caCertRef.Kind == nil || string(*caCertRef.Kind) == KindSecret { // nolint
+ secret, err := t.validateSecretRef(false, from, caCertRef, resources)
+ if err != nil {
+ return err
+ }
+
+ secretBytes, ok := secret.Data[caCertKey]
+ if !ok || len(secretBytes) == 0 {
+ return fmt.Errorf(
+ "caCertificateRef not found in secret %s", caCertRef.Name)
+ }
+
+ irCACert.Certificate = append(irCACert.Certificate, secretBytes...)
+
+ } else if string(*caCertRef.Kind) == KindConfigMap {
+ configMap, err := t.validateConfigMapRef(false, from, caCertRef, resources)
+ if err != nil {
+ return err
+ }
+
+ configMapBytes, ok := configMap.Data[caCertKey]
+ if !ok || len(configMapBytes) == 0 {
+ return fmt.Errorf(
+ "caCertificateRef not found in configMap %s", caCertRef.Name)
+ }
+
+ irCACert.Certificate = append(irCACert.Certificate, configMapBytes...)
+ } else {
+ return fmt.Errorf("unsupported caCertificateRef kind:%s", string(*caCertRef.Kind))
+ }
+ }
+
+ if len(irCACert.Certificate) > 0 {
+ httpIR.TLS.CACertificate = irCACert
+ }
+ }
+
+ return nil
}
diff --git a/internal/gatewayapi/helpers.go b/internal/gatewayapi/helpers.go
index 813dfdf1306..4c4ef61aece 100644
--- a/internal/gatewayapi/helpers.go
+++ b/internal/gatewayapi/helpers.go
@@ -26,6 +26,8 @@ const (
L4Protocol = "L4"
L7Protocol = "L7"
+
+ caCertKey = "ca.crt"
)
type protocolPort struct {
@@ -389,7 +391,11 @@ func irTLSConfigs(tlsSecrets []*v1.Secret) *ir.TLSConfig {
}
func irTLSListenerConfigName(secret *v1.Secret) string {
- return fmt.Sprintf("%s-%s", secret.Namespace, secret.Name)
+ return fmt.Sprintf("%s/%s", secret.Namespace, secret.Name)
+}
+
+func irTLSCACertName(namespace, name string) string {
+ return fmt.Sprintf("%s/%s/%s", namespace, name, caCertKey)
}
func isMergeGatewaysEnabled(resources *Resources) bool {
diff --git a/internal/gatewayapi/resource.go b/internal/gatewayapi/resource.go
index 6dc630ddc72..0cea818a637 100644
--- a/internal/gatewayapi/resource.go
+++ b/internal/gatewayapi/resource.go
@@ -40,6 +40,7 @@ type Resources struct {
ServiceImports []*mcsapi.ServiceImport `json:"serviceImports,omitempty" yaml:"serviceImports,omitempty"`
EndpointSlices []*discoveryv1.EndpointSlice `json:"endpointSlices,omitempty" yaml:"endpointSlices,omitempty"`
Secrets []*v1.Secret `json:"secrets,omitempty" yaml:"secrets,omitempty"`
+ ConfigMaps []*v1.ConfigMap `json:"configMaps,omitempty" yaml:"configMaps,omitempty"`
EnvoyProxy *egv1a1.EnvoyProxy `json:"envoyProxy,omitempty" yaml:"envoyProxy,omitempty"`
ExtensionRefFilters []unstructured.Unstructured `json:"extensionRefFilters,omitempty" yaml:"extensionRefFilters,omitempty"`
EnvoyPatchPolicies []*egv1a1.EnvoyPatchPolicy `json:"envoyPatchPolicies,omitempty" yaml:"envoyPatchPolicies,omitempty"`
@@ -57,6 +58,7 @@ func NewResources() *Resources {
Services: []*v1.Service{},
EndpointSlices: []*discoveryv1.EndpointSlice{},
Secrets: []*v1.Secret{},
+ ConfigMaps: []*v1.ConfigMap{},
ReferenceGrants: []*gwapiv1b1.ReferenceGrant{},
Namespaces: []*v1.Namespace{},
ExtensionRefFilters: []unstructured.Unstructured{},
@@ -107,6 +109,16 @@ func (r *Resources) GetSecret(namespace, name string) *v1.Secret {
return nil
}
+func (r *Resources) GetConfigMap(namespace, name string) *v1.ConfigMap {
+ for _, configMap := range r.ConfigMaps {
+ if configMap.Namespace == namespace && configMap.Name == name {
+ return configMap
+ }
+ }
+
+ return nil
+}
+
func (r *Resources) GetEndpointSlicesForBackend(svcNamespace, svcName string, backendKind string) []*discoveryv1.EndpointSlice {
var endpointSlices []*discoveryv1.EndpointSlice
for _, endpointSlice := range r.EndpointSlices {
diff --git a/internal/gatewayapi/testdata/clienttrafficpolicy-http3.out.yaml b/internal/gatewayapi/testdata/clienttrafficpolicy-http3.out.yaml
index 49ba2bb9f81..1ffbde52972 100644
--- a/internal/gatewayapi/testdata/clienttrafficpolicy-http3.out.yaml
+++ b/internal/gatewayapi/testdata/clienttrafficpolicy-http3.out.yaml
@@ -157,7 +157,7 @@ xdsIR:
alpnProtocols:
- h3
certificates:
- - name: envoy-gateway-tls-secret-1
+ - name: envoy-gateway/tls-secret-1
privateKey: LS0tLS1CRUdJTiBQUklWQVRFIEtFWS0tLS0tCk1JSUV2UUlCQURBTkJna3Foa2lHOXcwQkFRRUZBQVNDQktjd2dnU2pBZ0VBQW9JQkFRQ2QwZlBDYWtweE1nUnUKT0VXQjFiQk5FM3ZseW55aTZWbkV2VWF1OUhvakR2UHVPTFJIaGI4MmoyY1ovMHhnL1lKR09LelBuV2JERkxGNApHdWh3dDRENmFUR0xYNklPODEwTDZ0SXZIWGZNUXRJS2VwdTZ3K3p1WVo4bG1yejB1RjZlWEtqamVIbHhyb2ZrCnVNekM3OUVaU0lYZlZlczJ1SmdVRSs4VGFzSDUzQ2Y4MFNSRGlIeEdxckttdVNjWCtwejBreGdCZ1VWYTVVS20KUWdTZDFmVUxLOUEwNXAxOXkrdURPM204bVhRNkxVQ0N1STFwZHNROGFlNS9zamlxa0VjWlJjMTdWYVgxWjVVaQpvcGZnNW9SY05VTG9VTHNiek9aNTR0YlVDUmdSV2VLbGZxaElINEZ6OUlkVlUyR3dFdEdhMmV6TjgyMVBaQ3QzCjZhbVRIelJsQWdNQkFBRUNnZ0VBWTFGTUlLNDVXTkVNUHJ6RTZUY3NNdVV2RkdhQVZ4bVk5NW5SMEtwajdvb3IKY21CVys2ZXN0TTQ4S1AwaitPbXd3VFpMY29Cd3VoWGN0V1Bob1lXcDhteWUxRUlEdjNyaHRHMDdocEQ1NGg2dgpCZzh3ejdFYStzMk9sT0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MUN5dlFOT2FkZmN2cmd6dDV2SmwwT2kxQWdyaU5hWGJFUEdudWY3STQKcXBCSEdVWE5lMVdsOVdlVklxS1g0T2FFWERWQzZGQzdHOHptZWVMVzFBa1lFVm5pcFg2b1NCK0JjL1NIVlZOaApzQkxSbXRuc3pmTnRUMlFyZCttcGt4ODBaUUlEQVFBQk1BMEdDU3FHU0liM0RRRUJDd1VBQTRJQkFRQ1VKOElDCkJveUVqT3V3enBHYVJoR044QjRqT1B6aHVDT0V0ZDM3UzAybHUwN09IenlCdmJzVEd6S3dCZ0x5bVdmR2tINEIKajdDTHNwOEZ6TkhLWnVhQmdwblo5SjZETE9Od2ZXZTJBWXA3TGRmT0tWQlVkTVhRaU9tN2pKOUhob0Ntdk1ONwpic2pjaFdKb013ckZmK3dkQUthdHowcUFQeWhMeWUvRnFtaVZ4a09SWmF3K1Q5bURaK0g0OXVBU2d1SnVOTXlRClY2RXlYNmd0Z1dxMzc2SHZhWE1TLzNoYW1Zb1ZXWEk1TXhpUE9ZeG5BQmtKQjRTQ2dJUmVqYkpmVmFRdG9RNGEKejAyaVVMZW5ESUllUU9Zb2JLY01CWGYxQjRQQVFtc2VocVZJYnpzUUNHaTU0VkRyczZiWmQvN0pzMXpDcHBncwpKaUQ1SXFNaktXRHdxN2FLCi0tLS0tRU5EIENFUlRJRklDQVRFLS0tLS0K
maxVersion: "1.3"
diff --git a/internal/gatewayapi/testdata/clienttrafficpolicy-mtls.in.yaml b/internal/gatewayapi/testdata/clienttrafficpolicy-mtls.in.yaml
new file mode 100644
index 00000000000..05ff5b87294
--- /dev/null
+++ b/internal/gatewayapi/testdata/clienttrafficpolicy-mtls.in.yaml
@@ -0,0 +1,118 @@
+clientTrafficPolicies:
+- apiVersion: gateway.envoyproxy.io/v1alpha1
+ kind: ClientTrafficPolicy
+ metadata:
+ namespace: envoy-gateway
+ name: target-gateway-1
+ spec:
+ targetRef:
+ group: gateway.networking.k8s.io
+ kind: Gateway
+ name: gateway-1
+ namespace: envoy-gateway
+ tls:
+ clientValidation:
+ caCertificateRefs:
+ - name: tls-secret-1
+ namespace: envoy-gateway
+- apiVersion: gateway.envoyproxy.io/v1alpha1
+ kind: ClientTrafficPolicy
+ metadata:
+ namespace: envoy-gateway
+ name: target-gateway-2
+ spec:
+ targetRef:
+ group: gateway.networking.k8s.io
+ kind: Gateway
+ name: gateway-2
+ namespace: envoy-gateway
+ tls:
+ clientValidation:
+ caCertificateRefs:
+ - kind: ConfigMap
+ name: ca-configmap
+ namespace: envoy-gateway
+gateways:
+- apiVersion: gateway.networking.k8s.io/v1
+ kind: Gateway
+ metadata:
+ namespace: envoy-gateway
+ name: gateway-1
+ spec:
+ gatewayClassName: envoy-gateway-class
+ listeners:
+ - name: http-1
+ protocol: HTTPS
+ port: 443
+ allowedRoutes:
+ namespaces:
+ from: Same
+ tls:
+ mode: Terminate
+ certificateRefs:
+ - name: tls-secret-1
+ namespace: envoy-gateway
+ - name: http-2
+ protocol: HTTP
+ port: 8080
+ allowedRoutes:
+ namespaces:
+ from: Same
+- apiVersion: gateway.networking.k8s.io/v1
+ kind: Gateway
+ metadata:
+ namespace: envoy-gateway
+ name: gateway-2
+ spec:
+ gatewayClassName: envoy-gateway-class
+ listeners:
+ - name: http-1
+ protocol: HTTPS
+ port: 443
+ allowedRoutes:
+ namespaces:
+ from: Same
+ tls:
+ mode: Terminate
+ certificateRefs:
+ - name: tls-secret-1
+ namespace: envoy-gateway
+configMaps:
+- apiVersion: v1
+ kind: ConfigMap
+ metadata:
+ name: ca-configmap
+ namespace: envoy-gateway
+ data:
+ ca.crt: |
+ -----BEGIN CERTIFICATE-----
+ MIIDOzCCAiOgAwIBAgIUc41kpE9wK+NHgRGvBIgw8SCaz/8wDQYJKoZIhvcNAQEL
+ BQAwLTEVMBMGA1UECgwMZXhhbXBsZSBJbmMuMRQwEgYDVQQDDAtleGFtcGxlLmNv
+ bTAeFw0yNDAxMjYyMzE1MzFaFw0yNTAxMjUyMzE1MzFaMC0xFTATBgNVB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ci0tLS0tRU5EIFBSSVZBVEUgS0VZLS0tLS0K
diff --git a/internal/gatewayapi/testdata/clienttrafficpolicy-mtls.out.yaml b/internal/gatewayapi/testdata/clienttrafficpolicy-mtls.out.yaml
new file mode 100644
index 00000000000..31c3ae82535
--- /dev/null
+++ b/internal/gatewayapi/testdata/clienttrafficpolicy-mtls.out.yaml
@@ -0,0 +1,273 @@
+clientTrafficPolicies:
+- apiVersion: gateway.envoyproxy.io/v1alpha1
+ kind: ClientTrafficPolicy
+ metadata:
+ creationTimestamp: null
+ name: target-gateway-1
+ namespace: envoy-gateway
+ spec:
+ targetRef:
+ group: gateway.networking.k8s.io
+ kind: Gateway
+ name: gateway-1
+ namespace: envoy-gateway
+ tls:
+ clientValidation:
+ caCertificateRefs:
+ - group: null
+ kind: null
+ name: tls-secret-1
+ namespace: envoy-gateway
+ status:
+ conditions:
+ - lastTransitionTime: null
+ message: ClientTrafficPolicy has been accepted.
+ reason: Accepted
+ status: "True"
+ type: Accepted
+- apiVersion: gateway.envoyproxy.io/v1alpha1
+ kind: ClientTrafficPolicy
+ metadata:
+ creationTimestamp: null
+ name: target-gateway-2
+ namespace: envoy-gateway
+ spec:
+ targetRef:
+ group: gateway.networking.k8s.io
+ kind: Gateway
+ name: gateway-2
+ namespace: envoy-gateway
+ tls:
+ clientValidation:
+ caCertificateRefs:
+ - group: null
+ kind: ConfigMap
+ name: ca-configmap
+ namespace: envoy-gateway
+ status:
+ conditions:
+ - lastTransitionTime: null
+ message: ClientTrafficPolicy has been accepted.
+ reason: Accepted
+ status: "True"
+ type: Accepted
+gateways:
+- apiVersion: gateway.networking.k8s.io/v1
+ kind: Gateway
+ metadata:
+ creationTimestamp: null
+ name: gateway-1
+ namespace: envoy-gateway
+ spec:
+ gatewayClassName: envoy-gateway-class
+ listeners:
+ - allowedRoutes:
+ namespaces:
+ from: Same
+ name: http-1
+ port: 443
+ protocol: HTTPS
+ tls:
+ certificateRefs:
+ - group: null
+ kind: null
+ name: tls-secret-1
+ namespace: envoy-gateway
+ mode: Terminate
+ - allowedRoutes:
+ namespaces:
+ from: Same
+ name: http-2
+ port: 8080
+ protocol: HTTP
+ status:
+ listeners:
+ - attachedRoutes: 0
+ conditions:
+ - lastTransitionTime: null
+ message: Sending translated listener configuration to the data plane
+ reason: Programmed
+ status: "True"
+ type: Programmed
+ - lastTransitionTime: null
+ message: Listener has been successfully translated
+ reason: Accepted
+ status: "True"
+ type: Accepted
+ - lastTransitionTime: null
+ message: Listener references have been resolved
+ reason: ResolvedRefs
+ status: "True"
+ type: ResolvedRefs
+ name: http-1
+ supportedKinds:
+ - group: gateway.networking.k8s.io
+ kind: HTTPRoute
+ - group: gateway.networking.k8s.io
+ kind: GRPCRoute
+ - attachedRoutes: 0
+ conditions:
+ - lastTransitionTime: null
+ message: Sending translated listener configuration to the data plane
+ reason: Programmed
+ status: "True"
+ type: Programmed
+ - lastTransitionTime: null
+ message: Listener has been successfully translated
+ reason: Accepted
+ status: "True"
+ type: Accepted
+ - lastTransitionTime: null
+ message: Listener references have been resolved
+ reason: ResolvedRefs
+ status: "True"
+ type: ResolvedRefs
+ name: http-2
+ supportedKinds:
+ - group: gateway.networking.k8s.io
+ kind: HTTPRoute
+ - group: gateway.networking.k8s.io
+ kind: GRPCRoute
+- apiVersion: gateway.networking.k8s.io/v1
+ kind: Gateway
+ metadata:
+ creationTimestamp: null
+ name: gateway-2
+ namespace: envoy-gateway
+ spec:
+ gatewayClassName: envoy-gateway-class
+ listeners:
+ - allowedRoutes:
+ namespaces:
+ from: Same
+ name: http-1
+ port: 443
+ protocol: HTTPS
+ tls:
+ certificateRefs:
+ - group: null
+ kind: null
+ name: tls-secret-1
+ namespace: envoy-gateway
+ mode: Terminate
+ status:
+ listeners:
+ - attachedRoutes: 0
+ conditions:
+ - lastTransitionTime: null
+ message: Sending translated listener configuration to the data plane
+ reason: Programmed
+ status: "True"
+ type: Programmed
+ - lastTransitionTime: null
+ message: Listener has been successfully translated
+ reason: Accepted
+ status: "True"
+ type: Accepted
+ - lastTransitionTime: null
+ message: Listener references have been resolved
+ reason: ResolvedRefs
+ status: "True"
+ type: ResolvedRefs
+ name: http-1
+ supportedKinds:
+ - group: gateway.networking.k8s.io
+ kind: HTTPRoute
+ - group: gateway.networking.k8s.io
+ kind: GRPCRoute
+infraIR:
+ envoy-gateway/gateway-1:
+ proxy:
+ listeners:
+ - address: null
+ name: envoy-gateway/gateway-1/http-1
+ ports:
+ - containerPort: 10443
+ name: http-1
+ protocol: HTTPS
+ servicePort: 443
+ - address: null
+ name: envoy-gateway/gateway-1/http-2
+ ports:
+ - containerPort: 8080
+ name: http-2
+ protocol: HTTP
+ servicePort: 8080
+ metadata:
+ labels:
+ gateway.envoyproxy.io/owning-gateway-name: gateway-1
+ gateway.envoyproxy.io/owning-gateway-namespace: envoy-gateway
+ name: envoy-gateway/gateway-1
+ envoy-gateway/gateway-2:
+ proxy:
+ listeners:
+ - address: null
+ name: envoy-gateway/gateway-2/http-1
+ ports:
+ - containerPort: 10443
+ name: http-1
+ protocol: HTTPS
+ servicePort: 443
+ metadata:
+ labels:
+ gateway.envoyproxy.io/owning-gateway-name: gateway-2
+ gateway.envoyproxy.io/owning-gateway-namespace: envoy-gateway
+ name: envoy-gateway/gateway-2
+xdsIR:
+ envoy-gateway/gateway-1:
+ accessLog:
+ text:
+ - path: /dev/stdout
+ http:
+ - address: 0.0.0.0
+ hostnames:
+ - '*'
+ isHTTP2: false
+ name: envoy-gateway/gateway-1/http-1
+ path:
+ escapedSlashesAction: UnescapeAndRedirect
+ mergeSlashes: true
+ port: 10443
+ tls:
+ caCertificate:
+ certificate: LS0tLS1CRUdJTiBDRVJUSUZJQ0FURS0tLS0tCk1JSURPekNDQWlPZ0F3SUJBZ0lVYzQxa3BFOXdLK05IZ1JHdkJJZ3c4U0Nhei84d0RRWUpLb1pJaHZjTkFRRUwKQlFBd0xURVZNQk1HQTFVRUNnd01aWGhoYlhCc1pTQkpibU11TVJRd0VnWURWUVFEREF0bGVHRnRjR3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es: true
+ port: 8080
+ envoy-gateway/gateway-2:
+ accessLog:
+ text:
+ - path: /dev/stdout
+ http:
+ - address: 0.0.0.0
+ hostnames:
+ - '*'
+ isHTTP2: false
+ name: envoy-gateway/gateway-2/http-1
+ path:
+ escapedSlashesAction: UnescapeAndRedirect
+ mergeSlashes: true
+ port: 10443
+ tls:
+ caCertificate:
+ certificate: LS0tLS1CRUdJTiBDRVJUSUZJQ0FURS0tLS0tCk1JSURPekNDQWlPZ0F3SUJBZ0lVYzQxa3BFOXdLK05IZ1JHdkJJZ3c4U0Nhei84d0RRWUpLb1pJaHZjTkFRRUwKQlFBd0xURVZNQk1HQTFVRUNnd01aWGhoYlhCc1pTQkpibU11TVJRd0VnWURWUVFEREF0bGVHRnRjR3hsTG1OdgpiVEFlRncweU5EQXhNall5TXpFMU16RmFGdzB5TlRBeE1qVXlNekUxTXpGYU1DMHhGVEFUQmdOVkJBb01ER1Y0CllXMXdiR1VnU1c1akxqRVVNQklHQTFVRUF3d0xaWGhoYlhCc1pTNWpiMjB3Z2dFaU1BMEdDU3FHU0liM0RRRUIKQVFVQUE0SUJEd0F3Z2dFS0FvSUJBUURDTGhaNURuQ1ZFNUpKOTd5T29jcFJ3Y2xibDBVd1gzY0krMVpaTmx0bApXNmpSZ3kxR3VONlZyN0NCbUkvbVB0Z0dzOVQ3RE5STWw1Z0pKa05IU1pvbUk2R2p1UDFLVWh1dmxmYlpQV05vCnA0NVQyMzVaODJHZzhPUkpIVDVtbjFRUksrYno5cnVKZnlsZE1NbGljVUp2L1lmdDZ6TlVSeFE3QlU5Y2lHZTEKdE0rVU1TeGtvcDNkb3ZWcHRFTG5rVERKU3d0NWRuK25qNmovR3I5NXo5MC9lMmdqZlZUdG1BckFHM3hoLzJCMQovRDZOWGh3UE16WXJwbG5NM2xPcHh6ZmxPVmdqTVVsb0wxb0k3c202YysyQTE0TmVCclcvb2ZCOVJEN0RXQkhkCjc2aitoY0FXRnN4WW1zSG81T3gvdEZlVGs3R1Jka0h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Q2eTQ5QU0KNzU4TUY4T0R6cVR2Q3hMRjJYd3BScjdjSDFuZ2J4eUJ6cEdlbkpsVTI2Q2hJT1BMZUV1NTUyUVJYVGwrU2JlQQpXUzNpS01Pb3F5NGV0b0ExNWFueW43Zm01YnpINEcyZ3Yxd1pWYlBkT1dNQWRZU2I5NDIvR09CSWUzSnIyVHo3CjRJdDRROWFERnF1aG9iOTVQMUhHQkxSQ2Y5QT0KLS0tLS1FTkQgQ0VSVElGSUNBVEUtLS0tLQo=
+ maxVersion: "1.3"
+ minVersion: "1.2"
diff --git a/internal/gatewayapi/testdata/clienttrafficpolicy-tls-settings.out.yaml b/internal/gatewayapi/testdata/clienttrafficpolicy-tls-settings.out.yaml
index 13154cdb100..70adfea5072 100644
--- a/internal/gatewayapi/testdata/clienttrafficpolicy-tls-settings.out.yaml
+++ b/internal/gatewayapi/testdata/clienttrafficpolicy-tls-settings.out.yaml
@@ -150,7 +150,7 @@ xdsIR:
alpnProtocols:
- h2
certificates:
- - name: envoy-gateway-tls-secret-1
+ - name: envoy-gateway/tls-secret-1
privateKey: LS0tLS1CRUdJTiBQUklWQVRFIEtFWS0tLS0tCk1JSUV2UUlCQURBTkJna3Foa2lHOXcwQkFRRUZBQVNDQktjd2dnU2pBZ0VBQW9JQkFRQ2QwZlBDYWtweE1nUnUKT0VXQjFiQk5FM3ZseW55aTZWbkV2VWF1OUhvakR2UHVPTFJIaGI4MmoyY1ovMHhnL1lKR09LelBuV2JERkxGNApHdWh3dDRENmFUR0xYNklPODEwTDZ0SXZIWGZNUXRJS2VwdTZ3K3p1WVo4bG1yejB1RjZlWEtqamVIbHhyb2ZrCnVNekM3OUVaU0lYZlZlczJ1SmdVRSs4VGFzSDUzQ2Y4MFNSRGlIeEdxckttdVNjWCtwejBreGdCZ1VWYTVVS20KUWdTZDFmVUxLOUEwNXAxOXkrdURPM204bVhRNkxVQ0N1STFwZHNROGFlNS9zamlxa0VjWlJjMTdWYVgxWjVVaQpvcGZnNW9SY05VT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ructure.out.yaml
index 34d5ebda862..57e77d7b5f5 100644
--- a/internal/gatewayapi/testdata/gateway-infrastructure.out.yaml
+++ b/internal/gatewayapi/testdata/gateway-infrastructure.out.yaml
@@ -144,6 +144,6 @@ xdsIR:
prefix: /
tls:
certificates:
- - name: default-tls-secret-1
+ - name: default/tls-secret-1
privateKey: LS0tLS1CRUdJTiBQUklWQVRFIEtFWS0tLS0tCk1JSUV2UUlCQURBTkJna3Foa2lHOXcwQkFRRUZBQVNDQktjd2dnU2pBZ0VBQW9JQkFRQ2QwZlBDYWtweE1nUnUKT0VXQjFiQk5FM3ZseW55aTZWbkV2VWF1OUhvakR2UHVPTFJIaGI4MmoyY1ovMHhnL1lKR09LelBuV2JERkxGNApHdWh3dDRENmFUR0xYNklPODEwTDZ0SXZIWGZNUXRJS2VwdTZ3K3p1WVo4bG1yejB1RjZlWEtqamVIbHhyb2ZrCnVNekM3OUVaU0lYZlZlczJ1SmdVRSs4VGFzSDUzQ2Y4MFNSRGlIeEdxckttdVNjWCtwejBreGdCZ1VWYTVVS20KUWdTZDFmVUxLOUEwNXAxOXkrdURPM204bVhRNkxVQ0N1STFwZHNROGFlNS9zamlxa0VjWlJjMTdWYVgxWjVVaQpvcGZnNW9SY05VTG9VTHNiek9aNTR0YlVDUmdSV2VLbGZxaElINEZ6OUlkVlUyR3dFdEdhMmV6TjgyMVBaQ3QzCjZhbVRIelJsQWdNQkFBRUNnZ0VBWTFGTUlLNDVXTkVNUHJ6RTZUY3NNdVV2RkdhQVZ4bVk5NW5SMEtwajdvb3IKY21CVys2ZXN0TTQ4S1AwaitPbXd3VFpMY29Cd3VoWGN0V1Bob1lXcDhteWUxRUlEdjNyaHRHMDdocEQ1NGg2dgpCZzh3ejdFYStzMk9sT0N6UnlKNzBSY281YlhjWDNGaGJjdnFlRWJwaFFyQnpOSEtLMjZ4cmZqNWZIT3p6T1FGCmJHdUZ3SDVic3JGdFhlajJXM3c4eW90N0ZQSDV3S3RpdnhvSWU5RjMyOXNn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0JjL1NIVlZOaApzQkxSbXRuc3pmTnRUMlFyZCttcGt4ODBaUUlEQVFBQk1BMEdDU3FHU0liM0RRRUJDd1VBQTRJQkFRQ1VKOElDCkJveUVqT3V3enBHYVJoR044QjRqT1B6aHVDT0V0ZDM3UzAybHUwN09IenlCdmJzVEd6S3dCZ0x5bVdmR2tINEIKajdDTHNwOEZ6TkhLWnVhQmdwblo5SjZETE9Od2ZXZTJBWXA3TGRmT0tWQlVkTVhRaU9tN2pKOUhob0Ntdk1ONwpic2pjaFdKb013ckZmK3dkQUthdHowcUFQeWhMeWUvRnFtaVZ4a09SWmF3K1Q5bURaK0g0OXVBU2d1SnVOTXlRClY2RXlYNmd0Z1dxMzc2SHZhWE1TLzNoYW1Zb1ZXWEk1TXhpUE9ZeG5BQmtKQjRTQ2dJUmVqYkpmVmFRdG9RNGEKejAyaVVMZW5ESUllUU9Zb2JLY01CWGYxQjRQQVFtc2VocVZJYnpzUUNHaTU0VkRyczZiWmQvN0pzMXpDcHBncwpKaUQ1SXFNaktXRHdxN2FLCi0tLS0tRU5EIENFUlRJRklDQVRFLS0tLS0K
diff --git a/internal/gatewayapi/testdata/gateway-with-listener-with-tls-secret-in-other-namespace-allowed-by-refgrant.out.yaml b/internal/gatewayapi/testdata/gateway-with-listener-with-tls-secret-in-other-namespace-allowed-by-refgrant.out.yaml
index 7165c0b5780..f72ccd5db18 100644
--- a/internal/gatewayapi/testdata/gateway-with-listener-with-tls-secret-in-other-namespace-allowed-by-refgrant.out.yaml
+++ b/internal/gatewayapi/testdata/gateway-with-listener-with-tls-secret-in-other-namespace-allowed-by-refgrant.out.yaml
@@ -133,6 +133,6 @@ xdsIR:
prefix: /
tls:
certificates:
- - name: default-tls-secret-1
+ - name: default/tls-secret-1
privateKey: LS0tLS1CRUdJTiBQUklWQVRFIEtFWS0tLS0tCk1JSUV2UUlCQURBTkJna3Foa2lHOXcwQkFRRUZBQVNDQktjd2dnU2pBZ0VBQW9JQkFRQ2QwZlBDYWtweE1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UFQeWhMeWUvRnFtaVZ4a09SWmF3K1Q5bURaK0g0OXVBU2d1SnVOTXlRClY2RXlYNmd0Z1dxMzc2SHZhWE1TLzNoYW1Zb1ZXWEk1TXhpUE9ZeG5BQmtKQjRTQ2dJUmVqYkpmVmFRdG9RNGEKejAyaVVMZW5ESUllUU9Zb2JLY01CWGYxQjRQQVFtc2VocVZJYnpzUUNHaTU0VkRyczZiWmQvN0pzMXpDcHBncwpKaUQ1SXFNaktXRHdxN2FLCi0tLS0tRU5EIENFUlRJRklDQVRFLS0tLS0K
diff --git a/internal/gatewayapi/testdata/gateway-with-listener-with-tls-terminate-and-passthrough.out.yaml b/internal/gatewayapi/testdata/gateway-with-listener-with-tls-terminate-and-passthrough.out.yaml
index 03bff1ce9d8..e8683486282 100644
--- a/internal/gatewayapi/testdata/gateway-with-listener-with-tls-terminate-and-passthrough.out.yaml
+++ b/internal/gatewayapi/testdata/gateway-with-listener-with-tls-terminate-and-passthrough.out.yaml
@@ -202,7 +202,7 @@ xdsIR:
prefix: /
tls:
certificates:
- - name: envoy-gateway-tls-secret-1
+ - name: envoy-gateway/tls-secret-1
privateKey: LS0tLS1CRUdJTiBQUklWQVRFIEtFWS0tLS0tCk1JSUV2UUlCQURBTkJna3Foa2lHOXcwQkFRRUZBQVNDQktjd2dnU2pBZ0VBQW9JQkFRQ2QwZlBDYWtweE1nUnUKT0VXQjFiQk5FM3ZseW55aTZWbkV2VWF1OUhvakR2UHVPTFJIaGI4MmoyY1ovMHhnL1lKR09LelBuV2JERkxGNApHdWh3dDRENmFUR0xYNklPODEwTDZ0SXZIWGZNUXRJS2VwdTZ3K3p1WVo4bG1yejB1RjZlWEtqamVIbHhyb2ZrCnVNekM3OUVaU0lYZlZlczJ1SmdVRSs4VGFzSDUzQ2Y4MFNSRGlIeEdxckttdVNjWCtwejBreGdCZ1VWYTVVS20KUWdTZDFmVUxLOUEwNXAxOXkrdURPM204bVhRNkxVQ0N1STFwZHNROGFlNS9zamlxa0VjWlJjM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id-multiple-tls-configuration-with-same-algorithm-different-fqdn.out.yaml b/internal/gatewayapi/testdata/gateway-with-listener-with-valid-multiple-tls-configuration-with-same-algorithm-different-fqdn.out.yaml
index 4ed7fc048bf..e2cd9a173fe 100644
--- a/internal/gatewayapi/testdata/gateway-with-listener-with-valid-multiple-tls-configuration-with-same-algorithm-different-fqdn.out.yaml
+++ b/internal/gatewayapi/testdata/gateway-with-listener-with-valid-multiple-tls-configuration-with-same-algorithm-different-fqdn.out.yaml
@@ -135,9 +135,9 @@ xdsIR:
prefix: /
tls:
certificates:
- - name: envoy-gateway-tls-secret-ecdsa-1
+ - name: envoy-gateway/tls-secret-ecdsa-1
privateKey: LS0tLS1CRUdJTiBFQyBQUklWQVRFIEtFWS0tLS0tCk1IY0NBUUVFSUxEbnZNM1RKM3NHYm9EeTF4T3dqSVppVFNWeWZXVWF5YVExcWdrdUdacEtvQW9HQ0NxR1NNNDkKQXdFSG9VUURRZ0FFSDVWdHJjenJQS091alV5RTMyaDU2UnVrdHUzSVhTVnJJMkNibXh5UUpqcEY3di9rNVNqTQpSVXZjUnBCdmpnQWROaGhUNGNUMXV4YW1TMFlmQ2JXMVhRPT0KLS0tLS1FTkQgRUMgUFJJVkFURSBLRVktLS0tLQo=
serverCertificate: LS0tLS1CRUdJTiBDRVJUSUZJQ0FURS0tLS0tCk1JSUJHekNCd2dJSkFJL3gxc0NEL0lSa01Bb0dDQ3FHU000OUJBTUNNQll4RkRBU0JnTlZCQU1NQzJadmJ5NWkKWVhJdVkyOXRNQjRYRFRJek1ERXdOVEl4TlRNeU9Wb1hEVEkwTURFd05USXhOVE15T1Zvd0ZqRVVNQklHQTFVRQpBd3dMWm05dkxtSmhjaTVqYjIwd1dUQVRCZ2NxaGtqT1BRSUJCZ2dxaGtqT1BRTUJCd05DQUFRZmxXMnR6T3M4Cm82Nk5USVRmYUhucEc2UzI3Y2hkSldzallKdWJISkFtT2tYdS8rVGxLTXhGUzl4R2tHK09BQjAyR0ZQaHhQVzcK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0RENmsKZisrQ2U3dXNkMG1RTzFTbmRZSVdqMlFMaUl6ME5aSDhCL1FyNGk3SjBJS3dzUWxVbnVuWnF2NUtZOVRMUWEwbgpNQW9HQ0NxR1NNNDlCQU1DQTJnQU1HVUNNUUNHVGpQa2hqZE1KcWUrVjFGRWpteUk2andEV0FDalhucFRuaXhVCnM2dUNKZjVNNUw1TmpGYmkydGplMGlES0UxVUNNQXdxSjZmOUs2bUhUd2JxVGkzTVNFMmQxODl6aUcyWVZCaUQKYmVXcHc0UjF5ZTdHRFJvVm9veG9ob2lERjdsNm13PT0KLS0tLS1FTkQgQ0VSVElGSUNBVEUtLS0tLQo=
diff --git a/internal/gatewayapi/testdata/gateway-with-listener-with-valid-multiple-tls-configuration.out.yaml b/internal/gatewayapi/testdata/gateway-with-listener-with-valid-multiple-tls-configuration.out.yaml
index c8df40b5660..741785be4b6 100644
--- a/internal/gatewayapi/testdata/gateway-with-listener-with-valid-multiple-tls-configuration.out.yaml
+++ b/internal/gatewayapi/testdata/gateway-with-listener-with-valid-multiple-tls-configuration.out.yaml
@@ -135,9 +135,9 @@ xdsIR:
prefix: /
tls:
certificates:
- - name: envoy-gateway-tls-secret-1
+ - name: envoy-gateway/tls-secret-1
privateKey: LS0tLS1CRUdJTiBQUklWQVRFIEtFWS0tLS0tCk1JSUV2UUlCQURBTkJna3Foa2lHOXcwQkFRRUZBQVNDQktjd2dnU2pBZ0VBQW9JQkFRQ2QwZlBDYWtweE1nUnUKT0VXQjFiQk5FM3ZseW55aTZWbkV2VWF1OUhvakR2UHVPTFJIaGI4MmoyY1ovMHhnL1lKR09LelBuV2JERkxGNApHdWh3dDRENmFUR0xYNklPODEwTDZ0SXZIWGZNUXRJS2VwdTZ3K3p1WVo4bG1yejB1RjZlWEtqamVIbHhyb2ZrCnVNekM3OUVaU0lYZlZlczJ1SmdVRSs4VGFzSDUzQ2Y4MFNSRGlIeEdxckttdVNjWCtwejBreGdCZ1VWYTVVS20KUWdTZDFmVUxLOUEwNX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QVRFLS0tLS0K
- - name: envoy-gateway-tls-secret-ecdsa-1
+ - name: envoy-gateway/tls-secret-ecdsa-1
privateKey: LS0tLS1CRUdJTiBFQyBQUklWQVRFIEtFWS0tLS0tCk1IY0NBUUVFSUxEbnZNM1RKM3NHYm9EeTF4T3dqSVppVFNWeWZXVWF5YVExcWdrdUdacEtvQW9HQ0NxR1NNNDkKQXdFSG9VUURRZ0FFSDVWdHJjenJQS091alV5RTMyaDU2UnVrdHUzSVhTVnJJMkNibXh5UUpqcEY3di9rNVNqTQpSVXZjUnBCdmpnQWROaGhUNGNUMXV4YW1TMFlmQ2JXMVhRPT0KLS0tLS1FTkQgRUMgUFJJVkFURSBLRVktLS0tLQo=
serverCertificate: LS0tLS1CRUdJTiBDRVJUSUZJQ0FURS0tLS0tCk1JSUJHekNCd2dJSkFJL3gxc0NEL0lSa01Bb0dDQ3FHU000OUJBTUNNQll4RkRBU0JnTlZCQU1NQzJadmJ5NWkKWVhJdVkyOXRNQjRYRFRJek1ERXdOVEl4TlRNeU9Wb1hEVEkwTURFd05USXhOVE15T1Zvd0ZqRVVNQklHQTFVRQpBd3dMWm05dkxtSmhjaTVqYjIwd1dUQVRCZ2NxaGtqT1BRSUJCZ2dxaGtqT1BRTUJCd05DQUFRZmxXMnR6T3M4Cm82Nk5USVRmYUhucEc2UzI3Y2hkSldzallKdWJISkFtT2tYdS8rVGxLTXhGUzl4R2tHK09BQjAyR0ZQaHhQVzcKRnFaTFJoOEp0YlZkTUFvR0NDcUdTTTQ5QkFNQ0EwZ0FNRVVDSVFEdlplU1pBZ1VWV2VpM3o0ZEhOTEd0aHpiaQoxRHZ0anRQekhYZ1R3WS92YmdJZ05KWStNcTRweFJnNit3eU04R1R4czVUV3k5Zml5RGhMUEU5QnhlbEsxSjQ9Ci0tLS0tRU5EIENFUlRJRklDQVRFLS0tLS0K
diff --git a/internal/gatewayapi/testdata/gateway-with-listener-with-valid-tls-configuration.out.yaml b/internal/gatewayapi/testdata/gateway-with-listener-with-valid-tls-configuration.out.yaml
index 3bfd5c50811..bc02d7f9543 100644
--- a/internal/gatewayapi/testdata/gateway-with-listener-with-valid-tls-configuration.out.yaml
+++ b/internal/gatewayapi/testdata/gateway-with-listener-with-valid-tls-configuration.out.yaml
@@ -132,6 +132,6 @@ xdsIR:
prefix: /
tls:
certificates:
- - name: envoy-gateway-tls-secret-1
+ - name: envoy-gateway/tls-secret-1
privateKey: LS0tLS1CRUdJTiBQUklWQVRFIEtFWS0tLS0tCk1JSUV2UUlCQURBTkJna3Foa2lHOXcwQkFRRUZBQVNDQktjd2dnU2pBZ0VBQW9JQkFRQ2QwZlBDYWtweE1nUnUKT0VXQjFiQk5FM3ZseW55aTZWbkV2VWF1OUhvakR2UHVPTFJIaGI4MmoyY1ovMHhnL1lKR09LelBuV2JERkxGNApHdWh3dDRENmFUR0xYNklPODEwTDZ0SXZIWGZNUXRJS2VwdTZ3K3p1WVo4bG1yejB1RjZlWEtqamVIbHhyb2ZrCnVNekM3OUVaU0lYZlZlczJ1SmdVRSs4VGFzSDUzQ2Y4MFNSRGlIeEdxckttdVNjWCtwejBreGdCZ1VWYTVVS20KUWdTZDFmVUxLOUEwNXAxOXkrdURPM204bVhRNkxVQ0N1STFwZHNROGFlNS9zamlxa0VjWlJjMTdWYVgxWjVVaQpvcGZnNW9SY05VTG9VTHNiek9aNTR0YlVDUmdSV2VLbGZxaElINEZ6OUlkVlUyR3dFdEdhMmV6TjgyMVBaQ3QzCjZhbVRIelJsQWdNQkFBRUNnZ0VBWTFGTUlLNDVXTkVNUHJ6RTZUY3NNdVV2RkdhQVZ4bVk5NW5SMEtwajdvb3IKY21CVys2ZXN0TTQ4S1AwaitPbXd3VFpMY29Cd3VoWGN0V1Bob1lXcDhteWUxRUlEdjNyaHRHMDdocEQ1NGg2dgpCZzh3ejdFYStzMk9sT0N6UnlKNzBSY281YlhjWDNGaGJjdnFlRWJwaFFyQnpOSEtLMjZ4cmZqNWZIT3p6T1FGCmJHdUZ3SDVic3JG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T2FFWERWQzZGQzdHOHptZWVMVzFBa1lFVm5pcFg2b1NCK0JjL1NIVlZOaApzQkxSbXRuc3pmTnRUMlFyZCttcGt4ODBaUUlEQVFBQk1BMEdDU3FHU0liM0RRRUJDd1VBQTRJQkFRQ1VKOElDCkJveUVqT3V3enBHYVJoR044QjRqT1B6aHVDT0V0ZDM3UzAybHUwN09IenlCdmJzVEd6S3dCZ0x5bVdmR2tINEIKajdDTHNwOEZ6TkhLWnVhQmdwblo5SjZETE9Od2ZXZTJBWXA3TGRmT0tWQlVkTVhRaU9tN2pKOUhob0Ntdk1ONwpic2pjaFdKb013ckZmK3dkQUthdHowcUFQeWhMeWUvRnFtaVZ4a09SWmF3K1Q5bURaK0g0OXVBU2d1SnVOTXlRClY2RXlYNmd0Z1dxMzc2SHZhWE1TLzNoYW1Zb1ZXWEk1TXhpUE9ZeG5BQmtKQjRTQ2dJUmVqYkpmVmFRdG9RNGEKejAyaVVMZW5ESUllUU9Zb2JLY01CWGYxQjRQQVFtc2VocVZJYnpzUUNHaTU0VkRyczZiWmQvN0pzMXpDcHBncwpKaUQ1SXFNaktXRHdxN2FLCi0tLS0tRU5EIENFUlRJRklDQVRFLS0tLS0K
diff --git a/internal/gatewayapi/testdata/gateway-with-stale-status-condition.out.yaml b/internal/gatewayapi/testdata/gateway-with-stale-status-condition.out.yaml
index 987cff5897e..aae3821da4d 100644
--- a/internal/gatewayapi/testdata/gateway-with-stale-status-condition.out.yaml
+++ b/internal/gatewayapi/testdata/gateway-with-stale-status-condition.out.yaml
@@ -132,6 +132,6 @@ xdsIR:
prefix: /
tls:
certificates:
- - name: default-tls-secret-1
+ - name: default/tls-secret-1
privateKey: LS0tLS1CRUdJTiBQUklWQVRFIEtFWS0tLS0tCk1JSUV2UUlCQURBTkJna3Foa2lHOXcwQkFRRUZBQVNDQktjd2dnU2pBZ0VBQW9JQkFRQ2QwZlBDYWtweE1nUnUKT0VXQjFiQk5FM3ZseW55aTZWbkV2VWF1OUhvakR2UHVP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SnVOTXlRClY2RXlYNmd0Z1dxMzc2SHZhWE1TLzNoYW1Zb1ZXWEk1TXhpUE9ZeG5BQmtKQjRTQ2dJUmVqYkpmVmFRdG9RNGEKejAyaVVMZW5ESUllUU9Zb2JLY01CWGYxQjRQQVFtc2VocVZJYnpzUUNHaTU0VkRyczZiWmQvN0pzMXpDcHBncwpKaUQ1SXFNaktXRHdxN2FLCi0tLS0tRU5EIENFUlRJRklDQVRFLS0tLS0K
diff --git a/internal/gatewayapi/testdata/httproute-attaching-to-gateway-with-two-listeners-with-different-ports.out.yaml b/internal/gatewayapi/testdata/httproute-attaching-to-gateway-with-two-listeners-with-different-ports.out.yaml
index ebaafcee77f..fbb816e0e08 100644
--- a/internal/gatewayapi/testdata/httproute-attaching-to-gateway-with-two-listeners-with-different-ports.out.yaml
+++ b/internal/gatewayapi/testdata/httproute-attaching-to-gateway-with-two-listeners-with-different-ports.out.yaml
@@ -196,6 +196,6 @@ xdsIR:
prefix: /
tls:
certificates:
- - name: envoy-gateway-tls-secret-1
+ - name: envoy-gateway/tls-secret-1
privateKey: LS0tLS1CRUdJTiBQUklWQVRFIEtFWS0tLS0tCk1JSUV2UUlCQURBTkJna3Foa2lHOXcwQkFRRUZBQVNDQktjd2dnU2pBZ0VBQW9JQkFRQ2QwZlBDYWtweE1nUnUKT0VXQjFiQk5FM3ZseW55aTZWbkV2VWF1OUhvakR2UHVPTFJIaGI4MmoyY1ovMHhnL1lKR09LelBuV2JERkxGNApHdWh3dDRENmFUR0xYNklPODEwTDZ0SXZIWGZNUXRJS2VwdTZ3K3p1WVo4bG1yejB1RjZlWEtqamVIbHhyb2ZrCnVNekM3OUVaU0lYZlZlczJ1SmdVRSs4VGFzSDUzQ2Y4MFNSRGlIeEdxckttdVNjWCtwejBreGdCZ1VWYTVVS20KUWdTZDFmVUxLOUEwNXAxOXkrdURPM204bVhRNkxVQ0N1STFwZHNROGFlNS9zamlxa0VjWlJjMTdWYVgxWjVVaQpvcGZnNW9SY05VTG9V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/tcproute-attaching-to-gateway-with-listener-tls-terminate.out.yaml
index f70ca85e266..5a2f7ef478a 100644
--- a/internal/gatewayapi/testdata/tcproute-attaching-to-gateway-with-listener-tls-terminate.out.yaml
+++ b/internal/gatewayapi/testdata/tcproute-attaching-to-gateway-with-listener-tls-terminate.out.yaml
@@ -112,6 +112,6 @@ xdsIR:
tls:
terminate:
certificates:
- - name: envoy-gateway-tls-secret-1
+ - name: envoy-gateway/tls-secret-1
privateKey: LS0tLS1CRUdJTiBQUklWQVRFIEtFWS0tLS0tCk1JSUV2UUlCQURBTkJna3Foa2lHOXcwQkFRRUZBQVNDQktjd2dnU2pBZ0VBQW9JQkFRQ2QwZlBDYWtweE1nUnUKT0VXQjFiQk5FM3ZseW55aTZWbkV2VWF1OUhvakR2UHVPTFJIaGI4MmoyY1ovMHhnL1lKR09LelBuV2JERkxGNApHdWh3dDRENmFUR0xYNklPODEwTDZ0SXZIWGZNUXRJS2VwdTZ3K3p1WVo4bG1yejB1RjZlWEtqamVIbHhyb2ZrCnVNekM3OUVaU0lYZlZlczJ1SmdVRSs4VGFzSDUzQ2Y4MFNSRGlIeEdxckttdVNjWCtwejBreGdCZ1VWYTVVS20KUWdTZDFmVUxLOUEwNXAxOXkrdURPM204bVhRNkxVQ0N1STFwZHNROGFlNS9zamlxa0VjWlJjMTdWYVgxWjVVaQpvcGZnNW9SY05VTG9VTHNiek9aNTR0YlVDUmdSV2VLbGZxaElINEZ6OUlkVlUyR3dFdEdhMmV6TjgyMVBaQ3QzCjZhbVRIelJsQWdNQkFBRUNnZ0VBWTFGTUlLNDVXTkVNUHJ6RTZUY3NNdVV2RkdhQVZ4bVk5NW5SMEtwajdvb3IKY21CVys2ZXN0TTQ4S1AwaitPbXd3VFpMY29Cd3VoWGN0V1Bob1lXcDhteWUxRUlEdjNyaHRHMDdocEQ1NGg2dgpCZzh3ejdFYStzMk9sT0N6UnlKNzBSY281YlhjWDNGaGJjdnFlRWJwaFFyQnpOSEtLMjZ4cmZqNW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XBCSEdVWE5lMVdsOVdlVklxS1g0T2FFWERWQzZGQzdHOHptZWVMVzFBa1lFVm5pcFg2b1NCK0JjL1NIVlZOaApzQkxSbXRuc3pmTnRUMlFyZCttcGt4ODBaUUlEQVFBQk1BMEdDU3FHU0liM0RRRUJDd1VBQTRJQkFRQ1VKOElDCkJveUVqT3V3enBHYVJoR044QjRqT1B6aHVDT0V0ZDM3UzAybHUwN09IenlCdmJzVEd6S3dCZ0x5bVdmR2tINEIKajdDTHNwOEZ6TkhLWnVhQmdwblo5SjZETE9Od2ZXZTJBWXA3TGRmT0tWQlVkTVhRaU9tN2pKOUhob0Ntdk1ONwpic2pjaFdKb013ckZmK3dkQUthdHowcUFQeWhMeWUvRnFtaVZ4a09SWmF3K1Q5bURaK0g0OXVBU2d1SnVOTXlRClY2RXlYNmd0Z1dxMzc2SHZhWE1TLzNoYW1Zb1ZXWEk1TXhpUE9ZeG5BQmtKQjRTQ2dJUmVqYkpmVmFRdG9RNGEKejAyaVVMZW5ESUllUU9Zb2JLY01CWGYxQjRQQVFtc2VocVZJYnpzUUNHaTU0VkRyczZiWmQvN0pzMXpDcHBncwpKaUQ1SXFNaktXRHdxN2FLCi0tLS0tRU5EIENFUlRJRklDQVRFLS0tLS0K
diff --git a/internal/gatewayapi/translator.go b/internal/gatewayapi/translator.go
index fbbd0490066..5163deca337 100644
--- a/internal/gatewayapi/translator.go
+++ b/internal/gatewayapi/translator.go
@@ -15,19 +15,21 @@ import (
)
const (
- KindEnvoyProxy = "EnvoyProxy"
- KindGateway = "Gateway"
- KindGatewayClass = "GatewayClass"
- KindGRPCRoute = "GRPCRoute"
- KindHTTPRoute = "HTTPRoute"
- KindNamespace = "Namespace"
- KindTLSRoute = "TLSRoute"
- KindTCPRoute = "TCPRoute"
- KindUDPRoute = "UDPRoute"
- KindService = "Service"
- KindServiceImport = "ServiceImport"
- KindSecret = "Secret"
- KindSecurityPolicy = "SecurityPolicy"
+ KindConfigMap = "ConfigMap"
+ KindClientTrafficPolicy = "ClientTrafficPolicy"
+ KindEnvoyProxy = "EnvoyProxy"
+ KindGateway = "Gateway"
+ KindGatewayClass = "GatewayClass"
+ KindGRPCRoute = "GRPCRoute"
+ KindHTTPRoute = "HTTPRoute"
+ KindNamespace = "Namespace"
+ KindTLSRoute = "TLSRoute"
+ KindTCPRoute = "TCPRoute"
+ KindUDPRoute = "UDPRoute"
+ KindService = "Service"
+ KindServiceImport = "ServiceImport"
+ KindSecret = "Secret"
+ KindSecurityPolicy = "SecurityPolicy"
GroupMultiClusterService = "multicluster.x-k8s.io"
// OwningGatewayNamespaceLabel is the owner reference label used for managed infra.
@@ -152,7 +154,7 @@ func (t *Translator) Translate(resources *Resources) *TranslateResult {
t.ProcessEnvoyPatchPolicies(resources.EnvoyPatchPolicies, xdsIR)
// Process ClientTrafficPolicies
- clientTrafficPolicies := t.ProcessClientTrafficPolicies(resources.ClientTrafficPolicies, gateways, xdsIR, infraIR)
+ clientTrafficPolicies := t.ProcessClientTrafficPolicies(resources, gateways, xdsIR, infraIR)
// Process all Addresses for all relevant Gateways.
t.ProcessAddresses(gateways, xdsIR, infraIR, resources)
diff --git a/internal/gatewayapi/validate.go b/internal/gatewayapi/validate.go
index 5511da30361..e694f1f9e7a 100644
--- a/internal/gatewayapi/validate.go
+++ b/internal/gatewayapi/validate.go
@@ -735,23 +735,76 @@ func (t *Translator) validateHostname(hostname string) error {
func (t *Translator) validateSecretRef(
allowCrossNamespace bool,
from crossNamespaceFrom,
- secretRef gwapiv1b1.SecretObjectReference,
+ secretObjRef gwapiv1b1.SecretObjectReference,
resources *Resources) (*v1.Secret, error) {
- if secretRef.Group != nil && string(*secretRef.Group) != "" {
- return nil, errors.New("secret ref group must be unspecified/empty")
- }
- if secretRef.Kind != nil && string(*secretRef.Kind) != KindSecret {
- return nil, fmt.Errorf("secret ref kind must be %s", KindSecret)
+ if err := t.validateSecretObjectRef(allowCrossNamespace, from, secretObjRef, resources); err != nil {
+ return nil, err
}
secretNamespace := from.namespace
+ if secretObjRef.Namespace != nil {
+ secretNamespace = string(*secretObjRef.Namespace)
+ }
+ secret := resources.GetSecret(secretNamespace, string(secretObjRef.Name))
+
+ if secret == nil {
+ return nil, fmt.Errorf(
+ "secret %s/%s does not exist", secretNamespace, secretObjRef.Name)
+ }
+
+ return secret, nil
+}
+
+func (t *Translator) validateConfigMapRef(
+ allowCrossNamespace bool,
+ from crossNamespaceFrom,
+ secretObjRef gwapiv1b1.SecretObjectReference,
+ resources *Resources) (*v1.ConfigMap, error) {
+
+ if err := t.validateSecretObjectRef(allowCrossNamespace, from, secretObjRef, resources); err != nil {
+ return nil, err
+ }
+
+ configMapNamespace := from.namespace
+ if secretObjRef.Namespace != nil {
+ configMapNamespace = string(*secretObjRef.Namespace)
+ }
+ configMap := resources.GetConfigMap(configMapNamespace, string(secretObjRef.Name))
+
+ if configMap == nil {
+ return nil, fmt.Errorf(
+ "configmap %s/%s does not exist", configMapNamespace, secretObjRef.Name)
+ }
+
+ return configMap, nil
+}
+
+func (t *Translator) validateSecretObjectRef(
+ allowCrossNamespace bool,
+ from crossNamespaceFrom,
+ secretRef gwapiv1b1.SecretObjectReference,
+ resources *Resources) error {
+ var kind string
+ if secretRef.Group != nil && string(*secretRef.Group) != "" {
+ return errors.New("secret ref group must be unspecified/empty")
+ }
+
+ if secretRef.Kind == nil { // nolint
+ kind = KindSecret
+ } else if string(*secretRef.Kind) == KindSecret {
+ kind = KindSecret
+ } else if string(*secretRef.Kind) == KindConfigMap {
+ kind = KindConfigMap
+ } else {
+ return fmt.Errorf("secret ref kind must be %s", KindSecret)
+ }
if secretRef.Namespace != nil &&
string(*secretRef.Namespace) != "" &&
string(*secretRef.Namespace) != from.namespace {
if !allowCrossNamespace {
- return nil, fmt.Errorf(
+ return fmt.Errorf(
"secret ref namespace must be unspecified/empty or %s",
from.namespace)
}
@@ -760,29 +813,20 @@ func (t *Translator) validateSecretRef(
from,
crossNamespaceTo{
group: "",
- kind: KindSecret,
+ kind: kind,
namespace: string(*secretRef.Namespace),
name: string(secretRef.Name),
},
resources.ReferenceGrants,
) {
- return nil,
- fmt.Errorf(
- "certificate ref to secret %s/%s not permitted by any ReferenceGrant",
- *secretRef.Namespace, secretRef.Name)
+ return fmt.Errorf(
+ "certificate ref to secret %s/%s not permitted by any ReferenceGrant",
+ *secretRef.Namespace, secretRef.Name)
}
- secretNamespace = string(*secretRef.Namespace)
- }
-
- secret := resources.GetSecret(secretNamespace, string(secretRef.Name))
-
- if secret == nil {
- return nil, fmt.Errorf(
- "secret %s/%s does not exist", secretNamespace, secretRef.Name)
}
- return secret, nil
+ return nil
}
// TODO: zhaohuabing combine this function with the one in the route translator
diff --git a/internal/gatewayapi/zz_generated.deepcopy.go b/internal/gatewayapi/zz_generated.deepcopy.go
index 56335dc5bc9..eb31a82d5e9 100644
--- a/internal/gatewayapi/zz_generated.deepcopy.go
+++ b/internal/gatewayapi/zz_generated.deepcopy.go
@@ -160,6 +160,17 @@ func (in *Resources) DeepCopyInto(out *Resources) {
}
}
}
+ if in.ConfigMaps != nil {
+ in, out := &in.ConfigMaps, &out.ConfigMaps
+ *out = make([]*corev1.ConfigMap, len(*in))
+ for i := range *in {
+ if (*in)[i] != nil {
+ in, out := &(*in)[i], &(*out)[i]
+ *out = new(corev1.ConfigMap)
+ (*in).DeepCopyInto(*out)
+ }
+ }
+ }
if in.EnvoyProxy != nil {
in, out := &in.EnvoyProxy, &out.EnvoyProxy
*out = new(apiv1alpha1.EnvoyProxy)
diff --git a/internal/ir/xds.go b/internal/ir/xds.go
index 89e9ad5a602..39038b0f7db 100644
--- a/internal/ir/xds.go
+++ b/internal/ir/xds.go
@@ -275,6 +275,8 @@ const (
type TLSConfig struct {
// Certificates contains the set of certificates associated with this listener
Certificates []TLSCertificate `json:"certificates,omitempty" yaml:"certificates,omitempty"`
+ // CACertificate to verify the client
+ CACertificate *TLSCACertificate `json:"caCertificate,omitempty" yaml:"caCertificate,omitempty"`
// MinVersion defines the minimal version of the TLS protocol supported by this listener.
MinVersion *TLSVersion `json:"minVersion,omitempty" yaml:"version,omitempty"`
// MaxVersion defines the maximal version of the TLS protocol supported by this listener.
@@ -300,6 +302,15 @@ type TLSCertificate struct {
PrivateKey []byte `json:"privateKey,omitempty" yaml:"privateKey,omitempty"`
}
+// TLSCACertificate holds CA Certificate to validate clients
+// +k8s:deepcopy-gen=true
+type TLSCACertificate struct {
+ // Name of the Secret object.
+ Name string `json:"name" yaml:"name"`
+ // Certificate content.
+ Certificate []byte `json:"certificate,omitempty" yaml:"certificate,omitempty"`
+}
+
func (t TLSCertificate) Validate() error {
var errs error
if len(t.ServerCertificate) == 0 {
diff --git a/internal/ir/zz_generated.deepcopy.go b/internal/ir/zz_generated.deepcopy.go
index a0bb675b814..800cc33f1ed 100644
--- a/internal/ir/zz_generated.deepcopy.go
+++ b/internal/ir/zz_generated.deepcopy.go
@@ -1792,6 +1792,26 @@ func (in *TLS) DeepCopy() *TLS {
return out
}
+// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
+func (in *TLSCACertificate) DeepCopyInto(out *TLSCACertificate) {
+ *out = *in
+ if in.Certificate != nil {
+ in, out := &in.Certificate, &out.Certificate
+ *out = make([]byte, len(*in))
+ copy(*out, *in)
+ }
+}
+
+// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TLSCACertificate.
+func (in *TLSCACertificate) DeepCopy() *TLSCACertificate {
+ if in == nil {
+ return nil
+ }
+ out := new(TLSCACertificate)
+ in.DeepCopyInto(out)
+ return out
+}
+
// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (in *TLSCertificate) DeepCopyInto(out *TLSCertificate) {
*out = *in
@@ -1827,6 +1847,11 @@ func (in *TLSConfig) DeepCopyInto(out *TLSConfig) {
(*in)[i].DeepCopyInto(&(*out)[i])
}
}
+ if in.CACertificate != nil {
+ in, out := &in.CACertificate, &out.CACertificate
+ *out = new(TLSCACertificate)
+ (*in).DeepCopyInto(*out)
+ }
if in.MinVersion != nil {
in, out := &in.MinVersion, &out.MinVersion
*out = new(TLSVersion)
diff --git a/internal/provider/kubernetes/controller.go b/internal/provider/kubernetes/controller.go
index 515783dc4f1..3240d7b90b7 100644
--- a/internal/provider/kubernetes/controller.go
+++ b/internal/provider/kubernetes/controller.go
@@ -31,7 +31,7 @@ import (
gwapiv1b1 "sigs.k8s.io/gateway-api/apis/v1beta1"
mcsapi "sigs.k8s.io/mcs-api/pkg/apis/v1alpha1"
- "github.com/envoyproxy/gateway/api/v1alpha1"
+ egv1a1 "github.com/envoyproxy/gateway/api/v1alpha1"
"github.com/envoyproxy/gateway/api/v1alpha1/validation"
"github.com/envoyproxy/gateway/internal/envoygateway/config"
"github.com/envoyproxy/gateway/internal/gatewayapi"
@@ -50,7 +50,7 @@ type gatewayAPIReconciler struct {
store *kubernetesProviderStore
namespace string
namespaceLabel *metav1.LabelSelector
- envoyGateway *v1alpha1.EnvoyGateway
+ envoyGateway *egv1a1.EnvoyGateway
mergeGateways bool
resources *message.ProviderResources
@@ -74,7 +74,7 @@ func newGatewayAPIController(mgr manager.Manager, cfg *config.Server, su status.
byNamespaceSelector := cfg.EnvoyGateway.Provider != nil &&
cfg.EnvoyGateway.Provider.Kubernetes != nil &&
cfg.EnvoyGateway.Provider.Kubernetes.Watch != nil &&
- cfg.EnvoyGateway.Provider.Kubernetes.Watch.Type == v1alpha1.KubernetesWatchModeTypeNamespaceSelector &&
+ cfg.EnvoyGateway.Provider.Kubernetes.Watch.Type == egv1a1.KubernetesWatchModeTypeNamespaceSelector &&
(cfg.EnvoyGateway.Provider.Kubernetes.Watch.NamespaceSelector.MatchLabels != nil ||
len(cfg.EnvoyGateway.Provider.Kubernetes.Watch.NamespaceSelector.MatchExpressions) > 0)
@@ -115,7 +115,7 @@ type resourceMappings struct {
allAssociatedNamespaces map[string]struct{}
// Map for storing backendRefs' NamespaceNames referred by various Route objects.
allAssociatedBackendRefs map[gwapiv1.BackendObjectReference]struct{}
- // Map for storing referenceGrant NamespaceNames for BackendRefs, SecretRefs.
+ // Map for storing referenceGrant NamespaceNames for BackendRefs, SecretRefs, ConfigMapRefs.
allAssociatedRefGrants map[types.NamespacedName]*gwapiv1b1.ReferenceGrant
// extensionRefFilters is a map of filters managed by an extension.
// The key is the namespaced name of the filter and the value is the
@@ -251,7 +251,7 @@ func (r *gatewayAPIReconciler) Reconcile(ctx context.Context, _ reconcile.Reques
}
// Add all EnvoyPatchPolicies
- envoyPatchPolicies := v1alpha1.EnvoyPatchPolicyList{}
+ envoyPatchPolicies := egv1a1.EnvoyPatchPolicyList{}
if err := r.client.List(ctx, &envoyPatchPolicies); err != nil {
return reconcile.Result{}, fmt.Errorf("error listing EnvoyPatchPolicies: %w", err)
}
@@ -260,13 +260,13 @@ func (r *gatewayAPIReconciler) Reconcile(ctx context.Context, _ reconcile.Reques
policy := policy
// Discard Status to reduce memory consumption in watchable
// It will be recomputed by the gateway-api layer
- policy.Status = v1alpha1.EnvoyPatchPolicyStatus{}
+ policy.Status = egv1a1.EnvoyPatchPolicyStatus{}
resourceTree.EnvoyPatchPolicies = append(resourceTree.EnvoyPatchPolicies, &policy)
}
// Add all ClientTrafficPolicies
- clientTrafficPolicies := v1alpha1.ClientTrafficPolicyList{}
+ clientTrafficPolicies := egv1a1.ClientTrafficPolicyList{}
if err := r.client.List(ctx, &clientTrafficPolicies); err != nil {
return reconcile.Result{}, fmt.Errorf("error listing ClientTrafficPolicies: %w", err)
}
@@ -275,13 +275,16 @@ func (r *gatewayAPIReconciler) Reconcile(ctx context.Context, _ reconcile.Reques
policy := policy
// Discard Status to reduce memory consumption in watchable
// It will be recomputed by the gateway-api layer
- policy.Status = v1alpha1.ClientTrafficPolicyStatus{}
+ policy.Status = egv1a1.ClientTrafficPolicyStatus{}
resourceTree.ClientTrafficPolicies = append(resourceTree.ClientTrafficPolicies, &policy)
}
+ // Add the referenced ConfigMaps in ClientTrafficPolicies to the resourceTree
+ r.processCtpConfigMapRefs(ctx, resourceTree, resourceMap)
+
// Add all BackendTrafficPolicies
- backendTrafficPolicies := v1alpha1.BackendTrafficPolicyList{}
+ backendTrafficPolicies := egv1a1.BackendTrafficPolicyList{}
if err := r.client.List(ctx, &backendTrafficPolicies); err != nil {
return reconcile.Result{}, fmt.Errorf("error listing BackendTrafficPolicies: %w", err)
}
@@ -290,12 +293,12 @@ func (r *gatewayAPIReconciler) Reconcile(ctx context.Context, _ reconcile.Reques
policy := policy
// Discard Status to reduce memory consumption in watchable
// It will be recomputed by the gateway-api layer
- policy.Status = v1alpha1.BackendTrafficPolicyStatus{}
+ policy.Status = egv1a1.BackendTrafficPolicyStatus{}
resourceTree.BackendTrafficPolicies = append(resourceTree.BackendTrafficPolicies, &policy)
}
// Add all SecurityPolicies
- securityPolicies := v1alpha1.SecurityPolicyList{}
+ securityPolicies := egv1a1.SecurityPolicyList{}
if err := r.client.List(ctx, &securityPolicies); err != nil {
return reconcile.Result{}, fmt.Errorf("error listing SecurityPolicies: %w", err)
}
@@ -304,7 +307,7 @@ func (r *gatewayAPIReconciler) Reconcile(ctx context.Context, _ reconcile.Reques
policy := policy
// Discard Status to reduce memory consumption in watchable
// It will be recomputed by the gateway-api layer
- policy.Status = v1alpha1.SecurityPolicyStatus{}
+ policy.Status = egv1a1.SecurityPolicyStatus{}
resourceTree.SecurityPolicies = append(resourceTree.SecurityPolicies, &policy)
}
@@ -474,6 +477,107 @@ func (r *gatewayAPIReconciler) processSecretRef(
return nil
}
+// processCtpConfigMapRefs adds the referenced ConfigMaps in ClientTrafficPolicies
+// to the resourceTree
+func (r *gatewayAPIReconciler) processCtpConfigMapRefs(
+ ctx context.Context, resourceTree *gatewayapi.Resources, resourceMap *resourceMappings) {
+ for _, policy := range resourceTree.ClientTrafficPolicies {
+ tls := policy.Spec.TLS
+
+ if tls != nil && tls.ClientValidation != nil {
+ for _, caCertRef := range tls.ClientValidation.CACertificateRefs {
+ if caCertRef.Kind != nil && string(*caCertRef.Kind) == gatewayapi.KindConfigMap {
+ if err := r.processConfigMapRef(
+ ctx,
+ resourceMap,
+ resourceTree,
+ gatewayapi.KindClientTrafficPolicy,
+ policy.Namespace,
+ policy.Name,
+ caCertRef); err != nil {
+ // we don't return an error here, because we want to continue
+ // reconciling the rest of the ClientTrafficPolicies despite that this
+ // reference is invalid.
+ // This ClientTrafficPolicy will be marked as invalid in its status
+ // when translating to IR because the referenced configmap can't be
+ // found.
+ r.log.Error(err,
+ "failed to process CACertificateRef for ClientTrafficPolicy",
+ "policy", policy, "caCertificateRef", caCertRef.Name)
+ }
+ } else if caCertRef.Kind == nil || string(*caCertRef.Kind) == gatewayapi.KindSecret {
+ if err := r.processSecretRef(
+ ctx,
+ resourceMap,
+ resourceTree,
+ gatewayapi.KindClientTrafficPolicy,
+ policy.Namespace,
+ policy.Name,
+ caCertRef); err != nil {
+ r.log.Error(err,
+ "failed to process CACertificateRef for SecurityPolicy",
+ "policy", policy, "caCertificateRef", caCertRef.Name)
+ }
+ }
+ }
+ }
+ }
+}
+
+// processConfigMapRef adds the referenced ConfigMap to the resourceTree if it's valid.
+// - If it exists in the same namespace as the owner.
+// - If it exists in a different namespace, and there is a ReferenceGrant.
+func (r *gatewayAPIReconciler) processConfigMapRef(
+ ctx context.Context,
+ resourceMap *resourceMappings,
+ resourceTree *gatewayapi.Resources,
+ ownerKind string,
+ ownerNS string,
+ ownerName string,
+ configMapRef gwapiv1b1.SecretObjectReference,
+) error {
+ configMap := new(corev1.ConfigMap)
+ configMapNS := gatewayapi.NamespaceDerefOr(configMapRef.Namespace, ownerNS)
+ err := r.client.Get(ctx,
+ types.NamespacedName{Namespace: configMapNS, Name: string(configMapRef.Name)},
+ configMap,
+ )
+ if err != nil && !kerrors.IsNotFound(err) {
+ return fmt.Errorf("unable to find the ConfigMap: %s/%s", configMapNS, string(configMapRef.Name))
+ }
+
+ if configMapNS != ownerNS {
+ from := ObjectKindNamespacedName{
+ kind: ownerKind,
+ namespace: ownerNS,
+ name: ownerName,
+ }
+ to := ObjectKindNamespacedName{
+ kind: gatewayapi.KindConfigMap,
+ namespace: configMapNS,
+ name: configMap.Name,
+ }
+ refGrant, err := r.findReferenceGrant(ctx, from, to)
+ switch {
+ case err != nil:
+ return fmt.Errorf("failed to find ReferenceGrant: %w", err)
+ case refGrant == nil:
+ return fmt.Errorf(
+ "no matching ReferenceGrants found: from %s/%s to %s/%s",
+ from.kind, from.namespace, to.kind, to.namespace)
+ default:
+ // RefGrant found
+ resourceMap.allAssociatedRefGrants[utils.NamespacedName(refGrant)] = refGrant
+ r.log.Info("added ReferenceGrant to resource map", "namespace", refGrant.Namespace,
+ "name", refGrant.Name)
+ }
+ }
+ resourceMap.allAssociatedNamespaces[configMapNS] = struct{}{} // TODO Zhaohuabing do we need this line?
+ resourceTree.ConfigMaps = append(resourceTree.ConfigMaps, configMap)
+ r.log.Info("processing ConfigMap", "namespace", configMapNS, "name", string(configMapRef.Name))
+ return nil
+}
+
func (r *gatewayAPIReconciler) getNamespace(ctx context.Context, name string) (*corev1.Namespace, error) {
nsKey := types.NamespacedName{Name: name}
ns := new(corev1.Namespace)
@@ -649,7 +753,7 @@ func (r *gatewayAPIReconciler) watchResources(ctx context.Context, mgr manager.M
epPredicates = append(epPredicates, predicate.NewPredicateFuncs(r.hasMatchingNamespaceLabels))
}
if err := c.Watch(
- source.Kind(mgr.GetCache(), &v1alpha1.EnvoyProxy{}),
+ source.Kind(mgr.GetCache(), &egv1a1.EnvoyProxy{}),
handler.EnqueueRequestsFromMapFunc(r.enqueueClass),
epPredicates...,
); err != nil {
@@ -835,6 +939,22 @@ func (r *gatewayAPIReconciler) watchResources(ctx context.Context, mgr manager.M
return err
}
+ // Watch ConfigMap CRUDs and process affected ClienTraffiPolicies.
+ configMapPredicates := []predicate.Predicate{
+ predicate.GenerationChangedPredicate{},
+ predicate.NewPredicateFuncs(r.validateConfigMapForReconcile),
+ }
+ if r.namespaceLabel != nil {
+ configMapPredicates = append(configMapPredicates, predicate.NewPredicateFuncs(r.hasMatchingNamespaceLabels))
+ }
+ if err := c.Watch(
+ source.Kind(mgr.GetCache(), &corev1.ConfigMap{}),
+ handler.EnqueueRequestsFromMapFunc(r.enqueueClass),
+ configMapPredicates...,
+ ); err != nil {
+ return err
+ }
+
// Watch ReferenceGrant CRUDs and process affected Gateways.
rgPredicates := []predicate.Predicate{predicate.GenerationChangedPredicate{}}
if r.namespaceLabel != nil {
@@ -872,7 +992,7 @@ func (r *gatewayAPIReconciler) watchResources(ctx context.Context, mgr manager.M
if r.envoyGateway.ExtensionAPIs != nil && r.envoyGateway.ExtensionAPIs.EnableEnvoyPatchPolicy {
// Watch EnvoyPatchPolicy CRUDs
if err := c.Watch(
- source.Kind(mgr.GetCache(), &v1alpha1.EnvoyPatchPolicy{}),
+ source.Kind(mgr.GetCache(), &egv1a1.EnvoyPatchPolicy{}),
handler.EnqueueRequestsFromMapFunc(r.enqueueClass),
eppPredicates...,
); err != nil {
@@ -887,13 +1007,17 @@ func (r *gatewayAPIReconciler) watchResources(ctx context.Context, mgr manager.M
}
if err := c.Watch(
- source.Kind(mgr.GetCache(), &v1alpha1.ClientTrafficPolicy{}),
+ source.Kind(mgr.GetCache(), &egv1a1.ClientTrafficPolicy{}),
handler.EnqueueRequestsFromMapFunc(r.enqueueClass),
ctpPredicates...,
); err != nil {
return err
}
+ if err := addCtpIndexers(ctx, mgr); err != nil {
+ return err
+ }
+
// Watch BackendTrafficPolicy
btpPredicates := []predicate.Predicate{predicate.GenerationChangedPredicate{}}
if r.namespaceLabel != nil {
@@ -901,7 +1025,7 @@ func (r *gatewayAPIReconciler) watchResources(ctx context.Context, mgr manager.M
}
if err := c.Watch(
- source.Kind(mgr.GetCache(), &v1alpha1.BackendTrafficPolicy{}),
+ source.Kind(mgr.GetCache(), &egv1a1.BackendTrafficPolicy{}),
handler.EnqueueRequestsFromMapFunc(r.enqueueClass),
btpPredicates...,
); err != nil {
@@ -915,7 +1039,7 @@ func (r *gatewayAPIReconciler) watchResources(ctx context.Context, mgr manager.M
}
if err := c.Watch(
- source.Kind(mgr.GetCache(), &v1alpha1.SecurityPolicy{}),
+ source.Kind(mgr.GetCache(), &egv1a1.SecurityPolicy{}),
handler.EnqueueRequestsFromMapFunc(r.enqueueClass),
spPredicates...,
); err != nil {
@@ -953,7 +1077,7 @@ func (r *gatewayAPIReconciler) enqueueClass(_ context.Context, _ client.Object)
}
func (r *gatewayAPIReconciler) hasManagedClass(obj client.Object) bool {
- ep, ok := obj.(*v1alpha1.EnvoyProxy)
+ ep, ok := obj.(*egv1a1.EnvoyProxy)
if !ok {
panic(fmt.Sprintf("unsupported object type %T", obj))
}
@@ -991,7 +1115,7 @@ func (r *gatewayAPIReconciler) processParamsRef(ctx context.Context, gc *gwapiv1
return fmt.Errorf("unsupported parametersRef for gatewayclass %s", gc.Name)
}
- epList := new(v1alpha1.EnvoyProxyList)
+ epList := new(egv1a1.EnvoyProxyList)
// The EnvoyProxy must be in the same namespace as EG.
if err := r.client.List(ctx, epList, &client.ListOptions{Namespace: r.namespace}); err != nil {
diff --git a/internal/provider/kubernetes/indexers.go b/internal/provider/kubernetes/indexers.go
index 0931d19d907..f4daed5960e 100644
--- a/internal/provider/kubernetes/indexers.go
+++ b/internal/provider/kubernetes/indexers.go
@@ -35,6 +35,8 @@ const (
backendUDPRouteIndex = "backendUDPRouteIndex"
secretSecurityPolicyIndex = "secretSecurityPolicyIndex"
backendSecurityPolicyIndex = "backendSecurityPolicyIndex"
+ configMapCtpIndex = "configMapCtpIndex"
+ secretCtpIndex = "secretCtpIndex"
)
func addReferenceGrantIndexers(ctx context.Context, mgr manager.Manager) error {
@@ -425,3 +427,57 @@ func backendSecurityPolicyIndexFunc(rawObj client.Object) []string {
// This should not happen because the CEL validation should catch it.
return []string{}
}
+
+// addCtpIndexers adds indexing on ClientTrafficPolicy, for ConfigMap or Secret objects that are
+// referenced in ClientTrafficPolicy objects. This helps in querying for ClientTrafficPolicies that are
+// affected by a particular ConfigMap or Secret CRUD.
+func addCtpIndexers(ctx context.Context, mgr manager.Manager) error {
+ if err := mgr.GetFieldIndexer().IndexField(ctx, &v1alpha1.ClientTrafficPolicy{}, configMapCtpIndex, configMapCtpIndexFunc); err != nil {
+ return err
+ }
+ if err := mgr.GetFieldIndexer().IndexField(ctx, &v1alpha1.ClientTrafficPolicy{}, secretCtpIndex, secretCtpIndexFunc); err != nil {
+ return err
+ }
+
+ return nil
+}
+
+func configMapCtpIndexFunc(rawObj client.Object) []string {
+ ctp := rawObj.(*v1alpha1.ClientTrafficPolicy)
+ var configMapReferences []string
+ if ctp.Spec.TLS != nil && ctp.Spec.TLS.ClientValidation != nil {
+ for _, caCertRef := range ctp.Spec.TLS.ClientValidation.CACertificateRefs {
+ if caCertRef.Kind != nil && string(*caCertRef.Kind) == gatewayapi.KindConfigMap {
+ // If an explicit configmap namespace is not provided, use the ctp namespace to
+ // lookup the provided config map Name.
+ configMapReferences = append(configMapReferences,
+ types.NamespacedName{
+ Namespace: gatewayapi.NamespaceDerefOr(caCertRef.Namespace, ctp.Namespace),
+ Name: string(caCertRef.Name),
+ }.String(),
+ )
+ }
+ }
+ }
+ return configMapReferences
+}
+
+func secretCtpIndexFunc(rawObj client.Object) []string {
+ ctp := rawObj.(*v1alpha1.ClientTrafficPolicy)
+ var secretReferences []string
+ if ctp.Spec.TLS != nil && ctp.Spec.TLS.ClientValidation != nil {
+ for _, caCertRef := range ctp.Spec.TLS.ClientValidation.CACertificateRefs {
+ if caCertRef.Kind == nil || (string(*caCertRef.Kind) == gatewayapi.KindSecret) {
+ // If an explicit namespace is not provided, use the ctp namespace to
+ // lookup the provided secrent Name.
+ secretReferences = append(secretReferences,
+ types.NamespacedName{
+ Namespace: gatewayapi.NamespaceDerefOr(caCertRef.Namespace, ctp.Namespace),
+ Name: string(caCertRef.Name),
+ }.String(),
+ )
+ }
+ }
+ }
+ return secretReferences
+}
diff --git a/internal/provider/kubernetes/predicates.go b/internal/provider/kubernetes/predicates.go
index 237044423d7..a4145bac29d 100644
--- a/internal/provider/kubernetes/predicates.go
+++ b/internal/provider/kubernetes/predicates.go
@@ -21,7 +21,7 @@ import (
gwapiv1a2 "sigs.k8s.io/gateway-api/apis/v1alpha2"
mcsapi "sigs.k8s.io/mcs-api/pkg/apis/v1alpha1"
- "github.com/envoyproxy/gateway/api/v1alpha1"
+ egv1a1 "github.com/envoyproxy/gateway/api/v1alpha1"
"github.com/envoyproxy/gateway/internal/gatewayapi"
"github.com/envoyproxy/gateway/internal/provider/utils"
)
@@ -148,6 +148,10 @@ func (r *gatewayAPIReconciler) validateSecretForReconcile(obj client.Object) boo
return true
}
+ if r.isCtpReferencingSecret(&nsName) {
+ return true
+ }
+
return false
}
@@ -174,7 +178,7 @@ func (r *gatewayAPIReconciler) isGatewayReferencingSecret(nsName *types.Namespac
}
func (r *gatewayAPIReconciler) isSecurityPolicyReferencingSecret(nsName *types.NamespacedName) bool {
- spList := &v1alpha1.SecurityPolicyList{}
+ spList := &egv1a1.SecurityPolicyList{}
if err := r.client.List(context.Background(), spList, &client.ListOptions{
FieldSelector: fields.OneTermEqualSelector(secretSecurityPolicyIndex, nsName.String()),
}); err != nil {
@@ -185,6 +189,18 @@ func (r *gatewayAPIReconciler) isSecurityPolicyReferencingSecret(nsName *types.N
return len(spList.Items) > 0
}
+func (r *gatewayAPIReconciler) isCtpReferencingSecret(nsName *types.NamespacedName) bool {
+ ctpList := &egv1a1.ClientTrafficPolicyList{}
+ if err := r.client.List(context.Background(), ctpList, &client.ListOptions{
+ FieldSelector: fields.OneTermEqualSelector(secretCtpIndex, nsName.String()),
+ }); err != nil {
+ r.log.Error(err, "unable to find associated ClientTrafficPolicies")
+ return false
+ }
+
+ return len(ctpList.Items) > 0
+}
+
// validateServiceForReconcile tries finding the owning Gateway of the Service
// if it exists, finds the Gateway's Deployment, and further updates the Gateway
// status Ready condition. All Services are pushed for reconciliation.
@@ -227,7 +243,7 @@ func (r *gatewayAPIReconciler) validateServiceForReconcile(obj client.Object) bo
}
func (r *gatewayAPIReconciler) isSecurityPolicyReferencingBackend(nsName *types.NamespacedName) bool {
- spList := &v1alpha1.SecurityPolicyList{}
+ spList := &egv1a1.SecurityPolicyList{}
if err := r.client.List(context.Background(), spList, &client.ListOptions{
FieldSelector: fields.OneTermEqualSelector(backendSecurityPolicyIndex, nsName.String()),
}); err != nil {
@@ -452,3 +468,26 @@ func (r *gatewayAPIReconciler) handleNode(obj client.Object) bool {
r.store.addNode(node)
return true
}
+
+// validateConfigMapForReconcile checks whether the ConfigMap belongs to a valid ClientTrafficPolicy.
+func (r *gatewayAPIReconciler) validateConfigMapForReconcile(obj client.Object) bool {
+ configMap, ok := obj.(*corev1.ConfigMap)
+ if !ok {
+ r.log.Info("unexpected object type, bypassing reconciliation", "object", obj)
+ return false
+ }
+
+ ctpList := &egv1a1.ClientTrafficPolicyList{}
+ if err := r.client.List(context.Background(), ctpList, &client.ListOptions{
+ FieldSelector: fields.OneTermEqualSelector(configMapCtpIndex, utils.NamespacedName(configMap).String()),
+ }); err != nil {
+ r.log.Error(err, "unable to find associated ClientTrafficPolicy")
+ return false
+ }
+
+ if len(ctpList.Items) == 0 {
+ return false
+ }
+
+ return true
+}
diff --git a/internal/xds/translator/listener.go b/internal/xds/translator/listener.go
index a558e935595..fcc6a2a6e8b 100644
--- a/internal/xds/translator/listener.go
+++ b/internal/xds/translator/listener.go
@@ -389,7 +389,6 @@ func buildDownstreamQUICTransportSocket(tlsConfig *ir.TLSConfig) (*corev3.Transp
TlsParams: buildTLSParams(tlsConfig),
AlpnProtocols: buildALPNProtocols(tlsConfig.ALPNProtocols),
},
- RequireClientCertificate: &wrappers.BoolValue{Value: false},
},
}
@@ -402,6 +401,16 @@ func buildDownstreamQUICTransportSocket(tlsConfig *ir.TLSConfig) (*corev3.Transp
})
}
+ if tlsConfig.CACertificate != nil {
+ tlsCtx.DownstreamTlsContext.RequireClientCertificate = &wrappers.BoolValue{Value: true}
+ tlsCtx.DownstreamTlsContext.CommonTlsContext.ValidationContextType = &tlsv3.CommonTlsContext_ValidationContextSdsSecretConfig{
+ ValidationContextSdsSecretConfig: &tlsv3.SdsSecretConfig{
+ Name: tlsConfig.CACertificate.Name,
+ SdsConfig: makeConfigSource(),
+ },
+ }
+ }
+
tlsCtxAny, err := anypb.New(tlsCtx)
if err != nil {
return nil, err
@@ -432,6 +441,16 @@ func buildXdsDownstreamTLSSocket(tlsConfig *ir.TLSConfig) (*corev3.TransportSock
})
}
+ if tlsConfig.CACertificate != nil {
+ tlsCtx.RequireClientCertificate = &wrappers.BoolValue{Value: true}
+ tlsCtx.CommonTlsContext.ValidationContextType = &tlsv3.CommonTlsContext_ValidationContextSdsSecretConfig{
+ ValidationContextSdsSecretConfig: &tlsv3.SdsSecretConfig{
+ Name: tlsConfig.CACertificate.Name,
+ SdsConfig: makeConfigSource(),
+ },
+ }
+ }
+
tlsCtxAny, err := anypb.New(tlsCtx)
if err != nil {
return nil, err
@@ -494,8 +513,7 @@ func buildALPNProtocols(alpn []string) []string {
return alpn
}
-func buildXdsDownstreamTLSSecret(tlsConfig ir.TLSCertificate) *tlsv3.Secret {
- // Build the tls secret
+func buildXdsTLSCertSecret(tlsConfig ir.TLSCertificate) *tlsv3.Secret {
return &tlsv3.Secret{
Name: tlsConfig.Name,
Type: &tlsv3.Secret_TlsCertificate{
@@ -511,6 +529,19 @@ func buildXdsDownstreamTLSSecret(tlsConfig ir.TLSCertificate) *tlsv3.Secret {
}
}
+func buildXdsTLSCaCertSecret(caCertificate *ir.TLSCACertificate) *tlsv3.Secret {
+ return &tlsv3.Secret{
+ Name: caCertificate.Name,
+ Type: &tlsv3.Secret_ValidationContext{
+ ValidationContext: &tlsv3.CertificateValidationContext{
+ TrustedCa: &corev3.DataSource{
+ Specifier: &corev3.DataSource_InlineBytes{InlineBytes: caCertificate.Certificate},
+ },
+ },
+ },
+ }
+}
+
func buildXdsUDPListener(clusterName string, udpListener *ir.UDPListener, accesslog *ir.AccessLog) (*listenerv3.Listener, error) {
if udpListener == nil {
return nil, errors.New("udp listener is nil")
diff --git a/internal/xds/translator/testdata/in/xds-ir/mutual-tls.yaml b/internal/xds/translator/testdata/in/xds-ir/mutual-tls.yaml
new file mode 100644
index 00000000000..ea7ebf48a4d
--- /dev/null
+++ b/internal/xds/translator/testdata/in/xds-ir/mutual-tls.yaml
@@ -0,0 +1,34 @@
+http:
+- name: "first-listener"
+ address: "0.0.0.0"
+ port: 10080
+ hostnames:
+ - "*"
+ path:
+ mergeSlashes: true
+ escapedSlashesAction: UnescapeAndRedirect
+ tls:
+ alpnProtocols:
+ - h2
+ - http/1.1
+ certificates:
+ - name: secret-1
+ # byte slice representation of "key-data"
+ serverCertificate: [99, 101, 114, 116, 45, 100, 97, 116, 97]
+ # byte slice representation of "key-data"
+ privateKey: [107, 101, 121, 45, 100, 97, 116, 97]
+ - name: secret-2
+ serverCertificate: [99, 101, 114, 116, 45, 100, 97, 116, 97]
+ privateKey: [107, 101, 121, 45, 100, 97, 116, 97]
+ caCertificate:
+ name: ca-cert
+ certificate: [99, 101, 114, 116, 45, 100, 97, 116, 97]
+ routes:
+ - name: "first-route"
+ hostname: "*"
+ destination:
+ name: "first-route-dest"
+ settings:
+ - endpoints:
+ - host: "1.2.3.4"
+ port: 50000
diff --git a/internal/xds/translator/testdata/out/xds-ir/http3.listeners.yaml b/internal/xds/translator/testdata/out/xds-ir/http3.listeners.yaml
index d3db1540bc4..5c05193ce62 100644
--- a/internal/xds/translator/testdata/out/xds-ir/http3.listeners.yaml
+++ b/internal/xds/translator/testdata/out/xds-ir/http3.listeners.yaml
@@ -47,7 +47,6 @@
sdsConfig:
ads: {}
resourceApiVersion: V3
- requireClientCertificate: false
name: envoy-gateway/gateway-1/tls-quic
udpListenerConfig:
downstreamSocketConfig: {}
diff --git a/internal/xds/translator/testdata/out/xds-ir/mutual-tls.clusters.yaml b/internal/xds/translator/testdata/out/xds-ir/mutual-tls.clusters.yaml
new file mode 100644
index 00000000000..c8692b81602
--- /dev/null
+++ b/internal/xds/translator/testdata/out/xds-ir/mutual-tls.clusters.yaml
@@ -0,0 +1,14 @@
+- commonLbConfig:
+ localityWeightedLbConfig: {}
+ connectTimeout: 10s
+ dnsLookupFamily: V4_ONLY
+ edsClusterConfig:
+ edsConfig:
+ ads: {}
+ resourceApiVersion: V3
+ serviceName: first-route-dest
+ lbPolicy: LEAST_REQUEST
+ name: first-route-dest
+ outlierDetection: {}
+ perConnectionBufferLimitBytes: 32768
+ type: EDS
diff --git a/internal/xds/translator/testdata/out/xds-ir/mutual-tls.endpoints.yaml b/internal/xds/translator/testdata/out/xds-ir/mutual-tls.endpoints.yaml
new file mode 100644
index 00000000000..3b3f2d09076
--- /dev/null
+++ b/internal/xds/translator/testdata/out/xds-ir/mutual-tls.endpoints.yaml
@@ -0,0 +1,12 @@
+- clusterName: first-route-dest
+ endpoints:
+ - lbEndpoints:
+ - endpoint:
+ address:
+ socketAddress:
+ address: 1.2.3.4
+ portValue: 50000
+ loadBalancingWeight: 1
+ loadBalancingWeight: 1
+ locality:
+ region: first-route-dest/backend/0
diff --git a/internal/xds/translator/testdata/out/xds-ir/mutual-tls.listeners.yaml b/internal/xds/translator/testdata/out/xds-ir/mutual-tls.listeners.yaml
new file mode 100644
index 00000000000..eee06c74b93
--- /dev/null
+++ b/internal/xds/translator/testdata/out/xds-ir/mutual-tls.listeners.yaml
@@ -0,0 +1,56 @@
+- address:
+ socketAddress:
+ address: 0.0.0.0
+ portValue: 10080
+ filterChains:
+ - filters:
+ - name: envoy.filters.network.http_connection_manager
+ typedConfig:
+ '@type': type.googleapis.com/envoy.extensions.filters.network.http_connection_manager.v3.HttpConnectionManager
+ commonHttpProtocolOptions:
+ headersWithUnderscoresAction: REJECT_REQUEST
+ http2ProtocolOptions:
+ initialConnectionWindowSize: 1048576
+ initialStreamWindowSize: 65536
+ maxConcurrentStreams: 100
+ httpFilters:
+ - name: envoy.filters.http.router
+ typedConfig:
+ '@type': type.googleapis.com/envoy.extensions.filters.http.router.v3.Router
+ mergeSlashes: true
+ normalizePath: true
+ pathWithEscapedSlashesAction: UNESCAPE_AND_REDIRECT
+ rds:
+ configSource:
+ ads: {}
+ resourceApiVersion: V3
+ routeConfigName: first-listener
+ statPrefix: https
+ upgradeConfigs:
+ - upgradeType: websocket
+ useRemoteAddress: true
+ transportSocket:
+ name: envoy.transport_sockets.tls
+ typedConfig:
+ '@type': type.googleapis.com/envoy.extensions.transport_sockets.tls.v3.DownstreamTlsContext
+ commonTlsContext:
+ alpnProtocols:
+ - h2
+ - http/1.1
+ tlsCertificateSdsSecretConfigs:
+ - name: secret-1
+ sdsConfig:
+ ads: {}
+ resourceApiVersion: V3
+ - name: secret-2
+ sdsConfig:
+ ads: {}
+ resourceApiVersion: V3
+ validationContextSdsSecretConfig:
+ name: ca-cert
+ sdsConfig:
+ ads: {}
+ resourceApiVersion: V3
+ requireClientCertificate: true
+ name: first-listener
+ perConnectionBufferLimitBytes: 32768
diff --git a/internal/xds/translator/testdata/out/xds-ir/mutual-tls.routes.yaml b/internal/xds/translator/testdata/out/xds-ir/mutual-tls.routes.yaml
new file mode 100644
index 00000000000..2734c7cc42a
--- /dev/null
+++ b/internal/xds/translator/testdata/out/xds-ir/mutual-tls.routes.yaml
@@ -0,0 +1,12 @@
+- ignorePortInHostMatching: true
+ name: first-listener
+ virtualHosts:
+ - domains:
+ - '*'
+ name: first-listener/*
+ routes:
+ - match:
+ prefix: /
+ name: first-route
+ route:
+ cluster: first-route-dest
diff --git a/internal/xds/translator/testdata/out/xds-ir/mutual-tls.secrets.yaml b/internal/xds/translator/testdata/out/xds-ir/mutual-tls.secrets.yaml
new file mode 100644
index 00000000000..052882baf5f
--- /dev/null
+++ b/internal/xds/translator/testdata/out/xds-ir/mutual-tls.secrets.yaml
@@ -0,0 +1,16 @@
+- name: secret-1
+ tlsCertificate:
+ certificateChain:
+ inlineBytes: Y2VydC1kYXRh
+ privateKey:
+ inlineBytes: a2V5LWRhdGE=
+- name: secret-2
+ tlsCertificate:
+ certificateChain:
+ inlineBytes: Y2VydC1kYXRh
+ privateKey:
+ inlineBytes: a2V5LWRhdGE=
+- name: ca-cert
+ validationContext:
+ trustedCa:
+ inlineBytes: Y2VydC1kYXRh
diff --git a/internal/xds/translator/translator.go b/internal/xds/translator/translator.go
index cb6da9cc772..3e8de622b4f 100644
--- a/internal/xds/translator/translator.go
+++ b/internal/xds/translator/translator.go
@@ -185,11 +185,18 @@ func (t *Translator) processHTTPListenerXdsTranslation(
// 1:1 between IR TLSListenerConfig and xDS Secret
if httpListener.TLS != nil {
for t := range httpListener.TLS.Certificates {
- secret := buildXdsDownstreamTLSSecret(httpListener.TLS.Certificates[t])
+ secret := buildXdsTLSCertSecret(httpListener.TLS.Certificates[t])
if err := tCtx.AddXdsResource(resourcev3.SecretType, secret); err != nil {
errs = errors.Join(errs, err)
}
}
+
+ if httpListener.TLS.CACertificate != nil {
+ caSecret := buildXdsTLSCaCertSecret(httpListener.TLS.CACertificate)
+ if err := tCtx.AddXdsResource(resourcev3.SecretType, caSecret); err != nil {
+ errs = errors.Join(errs, err)
+ }
+ }
}
// store virtual hosts by domain
@@ -357,11 +364,17 @@ func processTCPListenerXdsTranslation(tCtx *types.ResourceVersionTable, tcpListe
if tcpListener.TLS != nil && tcpListener.TLS.Terminate != nil {
for _, s := range tcpListener.TLS.Terminate.Certificates {
- secret := buildXdsDownstreamTLSSecret(s)
+ secret := buildXdsTLSCertSecret(s)
if err := tCtx.AddXdsResource(resourcev3.SecretType, secret); err != nil {
errs = errors.Join(errs, err)
}
}
+ if tcpListener.TLS.Terminate.CACertificate != nil {
+ caSecret := buildXdsTLSCaCertSecret(tcpListener.TLS.Terminate.CACertificate)
+ if err := tCtx.AddXdsResource(resourcev3.SecretType, caSecret); err != nil {
+ errs = errors.Join(errs, err)
+ }
+ }
}
}
return errs
diff --git a/internal/xds/translator/translator_test.go b/internal/xds/translator/translator_test.go
index a324c8a1442..2a3c34a2133 100644
--- a/internal/xds/translator/translator_test.go
+++ b/internal/xds/translator/translator_test.go
@@ -94,6 +94,10 @@ func TestTranslateXds(t *testing.T) {
name: "simple-tls",
requireSecrets: true,
},
+ {
+ name: "mutual-tls",
+ requireSecrets: true,
+ },
{
name: "http3",
requireSecrets: true,
diff --git a/site/content/en/latest/api/extension_types.md b/site/content/en/latest/api/extension_types.md
index b64355f7978..fee368f9d7f 100644
--- a/site/content/en/latest/api/extension_types.md
+++ b/site/content/en/latest/api/extension_types.md
@@ -313,7 +313,7 @@ _Appears in:_
| Field | Type | Required | Description |
| --- | --- | --- | --- |
-| `caCertificateRefs` | _[ObjectReference](https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.26/#objectreference-v1-core) array_ | false | CACertificateRefs contains one or more references to Kubernetes objects that contain TLS certificates of the Certificate Authorities that can be used as a trust anchor to validate the certificates presented by the client.
A single reference to a Kubernetes ConfigMap, with the CA certificate in a key named `ca.crt` is currently supported.
References to a resource in different namespace are invalid UNLESS there is a ReferenceGrant in the target namespace that allows the certificate to be attached. |
+| `caCertificateRefs` | _[SecretObjectReference](https://gateway-api.sigs.k8s.io/references/spec/#gateway.networking.k8s.io/v1.SecretObjectReference) array_ | false | CACertificateRefs contains one or more references to Kubernetes objects that contain TLS certificates of the Certificate Authorities that can be used as a trust anchor to validate the certificates presented by the client.
A single reference to a Kubernetes ConfigMap or a Kubernetes Secret, with the CA certificate in a key named `ca.crt` is currently supported.
References to a resource in different namespace are invalid UNLESS there is a ReferenceGrant in the target namespace that allows the certificate to be attached. |
#### Compression