You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat(core): add allowEnv policy option for shell commands
This adds `allowEnv` to the policy engine, mirroring the behavior
of `allowRedirection`. It allows shell commands prefixed with
environment variable assignments (e.g. `VAR=value cmd`) to execute
without prompting the user if they match a rule with `allowEnv = true`.
Also includes tests to verify parsing and enforcement logic.
Address Code Review Feedback:
- Updated `hasEnvPrefix` to detect the use of the `env` command (e.g., `env VAR=val cmd`)
- Added tests to verify `env` command detection
Co-authored-by: rmedranollamas <45878745+rmedranollamas@users.noreply.github.com>
0 commit comments