Skip to content

Add zizmor security analysis + harden workflows#179

Closed
Seldaek wants to merge 3 commits into
mainfrom
add-zizmor-dependabot
Closed

Add zizmor security analysis + harden workflows#179
Seldaek wants to merge 3 commits into
mainfrom
add-zizmor-dependabot

Conversation

@Seldaek

@Seldaek Seldaek commented May 29, 2026

Copy link
Copy Markdown
Member

Adds a zizmor GitHub Actions security-analysis workflow (pedantic, matching composer/packagist) and a dependabot.yml (github-actions, monthly + 7-day cooldown), and hardens the existing workflows so zizmor passes:

  • Pinned actions to commit SHAs at their latest releases (actions/checkout, shivammathur/setup-php, actions/upload-artifact).
  • Permissions: explicit contents: read; added concurrency limits and persist-credentials: false on checkouts.
  • tests.yml: reference the workflow env vars via cmd %VAR% syntax instead of ${{ env.* }} in run blocks (avoids template injection; still cmd shell).
  • builds.yml: switched the iscc / installer .exe / composer --version steps from shell: cmd to shell: pwsh (the .exe now uses a .\ prefix) so zizmor can analyze them.

Verified locally with zizmor (pedantic, incl. online audits): no findings. The Windows build steps that changed shells are worth a close look in review since they couldn't be tested locally.

Seldaek added 3 commits May 29, 2026 09:14
- Pin actions to commit SHAs at latest releases (checkout, setup-php, upload-artifact)
- Add explicit contents: read permissions and concurrency limits
- persist-credentials: false on checkouts
- tests.yml: reference workflow env vars via cmd %VAR% syntax instead of ${{ }} to avoid template injection
- builds.yml: switch the iscc/installer/composer steps from shell: cmd to pwsh (the .exe gets a .\ prefix) so zizmor can analyze them
Compiling with iscc under pwsh fails (Inno Setup 'Invalid number of parameters' in userdata.iss), so the iscc / installer .exe / composer steps go back to shell: cmd. This leaves 3 advisory zizmor 'misfeature' findings (cmd limits its analysis) that can't be resolved without breaking the Windows build.
@Seldaek

Seldaek commented May 29, 2026

Copy link
Copy Markdown
Member Author

Reverted the shell: cmdpwsh change: iscc fails to compile under pwsh (Invalid number of parameters in userdata.iss). Those 3 steps are back on cmd, so zizmor still reports 3 help-level misfeature findings (cmd limits analysis) — left as-is since cmd is required for the Inno Setup build. All other hardening (pins, permissions, concurrency, template-injection fixes) stands.

@Seldaek

Seldaek commented May 29, 2026

Copy link
Copy Markdown
Member Author

Hmm that revert did not help fix the build.. so I'm not sure if it was already broken or not, will let you take a look first @johnstevenson as I am not very familiar here.

Anyway would need to get this merged to get CI running again as I enabled some Actions restrictions at the org level.

@johnstevenson

Copy link
Copy Markdown
Member

I'll take a closer look.

@johnstevenson

Copy link
Copy Markdown
Member

@Seldaek Most of your woes were caused by a breaking change in a more recent version of Inno Setup, although getting stuff to work in Powershell was a bit of a fight.

I cherry-picked your commits to #180

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants