feat: hawkscan-action v3 β version-gated binary download for hawk 6.0.0+#286
Merged
Conversation
β¦etadata FIRST_BINARY_VERSION=6.0.0. 5.x.x β ZIP (unchanged). 6.0.0+ β binary. Action version forwarded as _STACKHAWK_ACTION_VERSION scan tag. Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
β¦tating process.env Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
Prevents argument injection via the 'command' action input. Only 'scan' and 'rescan' are valid values. Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
Allows 'validate config' and other hawk subcommands with args. Covers: scan, rescan, validate (+ any sub-subcommands like 'validate config'). Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
Fixes CodeQL 'Workflow does not contain permissions' alerts on all jobs. Minimum permissions: contents:read. Jobs posting code scanning results (live-test, verbose-debug-test, ajax-test) also get security-events:write. Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
Bwvolleyball
approved these changes
Jun 26, 2026
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.
Summary
< 6.0.0β existing ZIP path (unchanged); hawk>= 6.0.0β platform-native binary (hawk/{version}/{platform}/hawk[.exe])_STACKHAWK_ACTION_VERSION/_STACKHAWK_ACTION_REPOSITORYscan metadata so the platform can measure action adoption ahead of the 6.0.0 cutoversemveras a production dependency for the version gateenvoption instead of mutatingprocess.envfor cleaner test isolationHow it works
getDownloadObject()incli_utils.jsnow gates onsemver.gte(version, '6.0.0'). Below that threshold the ZIP path is completely unchanged. At 6.0.0+,getBinaryDownloadObject()resolves the platform/arch to the binary URL and returns{ isBinary: true }.setup.jsbranches ondownload.isBinary: single-file download β temp dir β chmod 755 (non-Windows) βaddPath.The
sourceURLaction input strips its/clisuffix viabinaryBaseUrl(), so dev builds (β¦/dev/hawk/cli) correctly resolve toβ¦/dev/hawk/{version}/{platform}/hawk.Test plan
npm run all)getDownloadObject('6.0.0', β¦)returnsisBinary: truewith correct URL shapeNotes
π€ Generated with Claude Code