feat: always ask for approval for non-readonly commands#510
Merged
Conversation
Member
Author
|
/cc @zvdy |
janetkuo
reviewed
Aug 26, 2025
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.
Two big changes related to command approval flow.
kubectl get pods | wc -lor generic bash script command multiple commands, we will always ask for approval even if the kubectl commands are readonly (this is to avoid exfilteration attacks).Why
We are seeing requests for using the tool against production clusters and without the above changes, I see a serious risk of prompt injection attacks.
It may appear that the above changes may cause
prompt fatiguebecause it will ask the user to approve commands but majority of the use-cases involves read-only kubectl commands and our current static filter will cover those pretty well and not request user to approve those commands.Follow ups (coming)
fixes #449