Repository navigation
Add Fix for insecure-commands audit rule - #1045
Conversation
|
Thanks @mostafa! I'm reviewing now. |
woodruffw
left a comment
There was a problem hiding this comment.
This looks pretty good to me, thanks @mostafa! Just some small nits.
One additional request: could we add a negative testcase for the "maybe present" scenario, i.e. to ensure we don't suggest a fix when we aren't sure whether ACTIONS_ALLOW_UNSECURE_COMMANDS is present?
| // Check that ACTIONS_ALLOW_UNSECURE_COMMANDS is removed | ||
| assert!( | ||
| !fixed_document | ||
| .source() | ||
| .contains("ACTIONS_ALLOW_UNSECURE_COMMANDS") | ||
| ); | ||
|
|
||
| // Check that other environment variables are preserved | ||
| assert!(fixed_document.source().contains("OTHER_VAR: keep-me")); |
There was a problem hiding this comment.
Could you make this an inline snapshot instead?
|
@woodruffw Thanks for the review! I'll have a look tonight. |
Kusari Analysis ResultsAnalysis for commit: 35429ef, performed at: 2025-07-31T23:22:18Z • • Recommendation✅ PROCEED with this Pull Request Summary✅ No Flagged Issues Detected All values appear to be within acceptable risk parameters. No pinned version dependency changes, code issues or exposed secrets detected! Found this helpful? Give it a 👍 or 👎 reaction! |
|
@woodruffw Addressed your comments. |
|
Kusari PR Analysis rerun based on - 35429ef performed at: 2025-07-31T23:22:18Z - link to updated analysis |
xref #876