-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Linkerd Tap doesn't seem to work with EKS Access Entries authentication #13169
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
multimac
added a commit
to multimac/linkerd2
that referenced
this issue
Oct 11, 2024
Kubernetes authorization plugins can rely on extra attributes on a user, and these are provided via `X-Remote-Extra-` headers. Currently the Linkerd Viz `tap` API doesn't include these attributes when making the `SubjectAccessReview` request which means the Tap API cannot be used by end-users who's clusters use such authz plugins. This change updates the `tap` controller to parse the `X-Remote-Extra-` headers and include them in the SubjectAccessReview request. Fixed linkerd#13169 Signed-off-by: David Symons <[email protected]>
This issue has been automatically marked as stale because it has not had recent activity. It will be closed in 14 days if no further activity occurs. Thank you for your contributions. |
We have this same issue.
We can not tap in the UI, or on the CLI
check's are fine
|
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
What is the issue?
I was trying to use
linkerd viz tap
to debug an internal issue, but kept gettingtap authorization failed
. After looking at the documentation page in the error message (https://linkerd.io/2.16/tasks/securing-linkerd-tap/), it seemed like the problem might be in Linkerd itself askubectl can-i
worksHow can it be reproduced?
I believe this might need an EKS cluster configured with EKS Access Entries for authentication :/
Logs, error output, etc
$ kubectl auth can-i watch deployments.v1alpha1.tap.linkerd.io/[xxx] --namespace [xxx] --subresource tap
yes
$ linkerd viz tap deployment/[xxx] --namespace [xxx]
HTTP error, status Code [403] (unexpected API response: {"error":"tap authorization failed (not authorized to access deployments.tap.linkerd.io), visit https://linkerd.io/tap-rbac for more information"})
output of
linkerd check -o short
Environment
Kubernetes Version: v1.30
Cluster Environment: AWS EKS
Host OS: Amazon Bottlerocket
Linkerd version: Client version: edge-24.10.2 / Server version: edge-24.10.1
Possible solution
I've made a commit which I will push up in a PR shortly, but I suspect the issue may be because the SubjectAccessReview done by the Tap controller doesn't pass in any of the "extra" user attributes
When looking at the audit logs generated by our Kubernetes control plane and comparing the
linkerd viz tap
vs.kubectl can-i
, I can see thatkubectl can-i
is passing some additional "extra" fields that seem relevant to the EKS Access Entries authentication.My commit updates ResourceAuthzForUser in linkerd/pkg/k8s/authz.go to take in the list of extra attributes, retrieved via the X-Remote-Extras- HTTP header
Additional context
No response
Would you like to work on fixing this bug?
yes
The text was updated successfully, but these errors were encountered: