-
Notifications
You must be signed in to change notification settings - Fork 4.4k
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
consul exec is denied even though acl allows #3160
Comments
Did that use to work with previous versions? |
I didn't try on different versions. Only this. Should I downgrade to test? |
Could you give 0.8.3 and/or 0.8.2 a try since you have the test setup already. This helps us to understand whether this is a regression or a new issue. |
Same same.
Ran the
|
Thank you. |
Hi @MosheM123 you will need to grant the token write access to the KV prefix |
Maybe I'm missing something because even after adding write access to the
|
@MosheM123 tracked this one down - it's a bug. It looks like the remote exec code is always using the https://github.com/hashicorp/consul/blob/v0.8.4/command/agent/remote_exec.go#L246 And similarly to write the results back: https://github.com/hashicorp/consul/blob/v0.8.4/command/agent/remote_exec.go#L313 You could configure the |
@slackpad Glad to hear I helped somehow to track a bug James. |
the acl_agent_token instead of the acl_token. Fixes #3160.
* Changes remote exec KV read to call GetTokenForAgent(), which can use the acl_agent_token instead of the acl_token. Fixes #3160. * Fixes remote exec unit test with ACLs. * Adds unhappy ACL path to unit tests for remote exec.
Version 0.8.4 both on server and client.
I have acl turned on on this DC, and of course
"disable_remote_exec": false
on every server for this case.I try to run
consul exec
both with token and without token and I get errors ofPermission denied
.Attaching the ACL for anonymous and the exec command.
I have no idea what I'm doing wrong.
Anonymous ACL:
(Master ACL is similar)
the exec commands I tried:
consul monitor on visat (the node I want to exec on)
Note that the first exec with the token produces the access denied message on the node consul monitor, while the exec without the token just exits on spot and doesn't prompt log message on the node.
The text was updated successfully, but these errors were encountered: