feat(destination): advertise identity for pods meshed by any control plane - #1
Draft
gnarlex wants to merge 1 commit into
Draft
Conversation
gnarlex
force-pushed
the
alex/outbound-default-policy-validation
branch
from
August 28, 2026 15:31
34a9f6e to
39925e4
Compare
…plane The destination controller only advertised a `TlsIdentity` for a pod when the pod's control-plane-ns label matched the controller's own namespace. As a result, a pod meshed by a *different* Linkerd control plane was reported as unmeshed (no identity), even when all control planes share a trust root. This blocks the proxy's outbound default policy (`all-authenticated` / `cluster-authenticated`), which requires mTLS to targets that advertise a mesh identity: pods meshed by a peer control plane would be refused even though they are meshed. Relax the identity gate from `controllerNSLabel == controllerNS` to `controllerNSLabel != ""`, matching the protocol-hint gate immediately above it. The identity SAN is already built from the pod's own control-plane-ns label, so under a shared trust root it is correct for cross-control-plane peers with no further change. This leaves the threaded `controllerNS` value unused in the endpoint translators, so it is removed from `newEndpointTranslator`, `newEndpointProfileTranslator` and `createWeightedAddr` and their call sites (`Config.ControllerNS` is unchanged). This assumes a single shared trust root/domain across all control planes (Variant A). Selectively trusting meshes with distinct trust roots (via a trust-domain annotation) remains future work, as noted in the TODO. Adds a test asserting identity is advertised for a pod whose control-plane-ns differs from the controller's, with a SAN derived from the pod's own label, and documents the shared-root requirement on the `defaultOutboundPolicy` Helm value. Relates to linkerd#15615 Relates to linkerd/linkerd2-proxy#4617 Signed-off-by: Alex Klein <alex@codesphere.com>
gnarlex
force-pushed
the
alex/outbound-default-policy-mtls-gate
branch
from
August 28, 2026 15:35
e1811b3 to
7e81cb7
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The destination controller only advertised a TlsIdentity for a pod when the pod's control-plane-ns label matched the controller's own namespace. As a result, a pod meshed by a different Linkerd control plane was reported as unmeshed (no identity), even when all control planes share a trust root.
This blocks the proxy's outbound default policy (
all-authenticated/cluster-authenticated), which requires mTLS to targets that advertise a mesh identity: pods meshed by a peer control plane would be refused even though they are meshed.Relax the identity gate from
controllerNSLabel == controllerNStocontrollerNSLabel != "", matching the protocol-hint gate immediately above it. The identity SAN is already built from the pod's own control-plane-ns label, so under a shared trust root it is correct for cross-control-plane peers with no further change. This leaves the threadedcontrollerNSvalue unused in the endpoint translators, so it is removed fromnewEndpointTranslator,newEndpointProfileTranslatorandcreateWeightedAddrand their call sites (Config.ControllerNSis unchanged).This assumes a single shared trust root/domain across all control planes (Variant A). Selectively trusting meshes with distinct trust roots (via a trust-domain annotation) remains future work, as noted in the TODO.
Adds a test asserting identity is advertised for a pod whose control-plane-ns differs from the controller's, with a SAN derived from the pod's own label, and documents the shared-root requirement on the
defaultOutboundPolicyHelm value.Relates to linkerd#15615
Relates to linkerd/linkerd2-proxy#4617