-
-
Notifications
You must be signed in to change notification settings - Fork 779
Apply RBAC to rendering of KVP during action execution #5764
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
Conversation
RBAC for key-value pairs in the datastore was recently instroduced. The RBAC policy needs to be applied to rendering of KVP during action and workflow execution.
cognifloyd
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks sane based on reading the code.
|
I wasn't sure if within a workflow if it uses a Jinja expression to execute a key/value pair should it check that the user has permission or not. If I thought the rules for key access were same as action access then I would expect them to have permission, even without explicit permission to keyD. This allows them to run a workflow that might need to say access sensitive information to perform its function, but we don't want them to actually be able to inquire and get the value of that sensitive info. We would definitely want the RBAC check on the inputs to the workflow, but if the body of the workflow accessed them, then I'm not so sure. I'm not sure which is best, so not added as a review comment that needs to be addressed. It maybe that the TSC thinks it's better to also need the key/value permission (even though for actions you don't need access to each individual action) - but we'll need to document whichever way we go. |
|
@armab Is there a plan to add this to a release. We have urgent need of this getting to master and test it out as its a big security flaw in the current setup. |
|
@hnanchahal Yes, it's scheduled as part of the upcoming v3.8 release. |
amanda11
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
|
Here is the conclusion based on internal @StackStorm/tsc conversations about whether granting RBAC access to the workflow should give access to subsequent K/V lookups in that workflow as we do for actions:
This however has some usability issues highlighted by @amanda11 when granting RBAC access to the workflow run, |
|
@armab In the upgrade notes section we should probably add something about granting key/value permission to users that can run workflows that use key/values. Similar to last bullet we put in 3.7 in regard to change needed for sensors: https://docs.stackstorm.com/upgrade_notes.html#st2-v3-7. |
|
+1 adding some hints to the upgrade notes |
|
@armab @m4dcoder Have a question on this RBAC: Does the config support tagging a role to multiple secrets? Doc says:name: key1_write_role is something like this supported? -- |
RBAC for key-value pairs in the datastore was recently introduced. The RBAC policy needs to be applied to rendering of KVP during action and workflow execution.