Skip to content

ci: fix zizmor security alerts#15820

Merged
kevinjqliu merged 4 commits intoapache:mainfrom
kevinjqliu:kevinjqliu/code-scan-fix
Mar 30, 2026
Merged

ci: fix zizmor security alerts#15820
kevinjqliu merged 4 commits intoapache:mainfrom
kevinjqliu:kevinjqliu/code-scan-fix

Conversation

@kevinjqliu
Copy link
Copy Markdown
Contributor

@kevinjqliu kevinjqliu commented Mar 29, 2026

Make zizmor error on CI failure
Fixes https://github.com/apache/iceberg/security/code-scanning

There was a timing issue which caused these to not be caught by zizmor ci (#15799 was merged after #15793)

Fix

@github-actions github-actions bot added the INFRA label Mar 29, 2026

- name: Initialize CodeQL
uses: github/codeql-action/init@38697555549f1db7851b81482ff19f1fa5c4fedc # v4
uses: github/codeql-action/init@c10b8064de6f491fea524254123dbe5e09572f13 # v4
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.


- name: Run zizmor 🌈
uses: zizmorcore/zizmor-action@71321a20a9ded102f6e9ce5718a2fcec2c4f70d8 # v0.5.2
with:
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

by default, zizmor's advanced-security feature is on which will upload to the "security" tab, but wont error in CI.

https://github.com/zizmorcore/zizmor-action?tab=readme-ov-file#changes-introduce-security-alerts-but-no-pr-checks-are-shown

We actually want the CI check to error, so we need to turn advanced-security off

runs-on: ubuntu-latest
permissions:
security-events: write # Required for upload-sarif (used by zizmor-action) to upload SARIF files.
permissions: {}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

did we remove upload sarif?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes, see https://github.com/apache/iceberg/pull/15820/files#r3006745722

zizmor's default behavior is to not error in CI and report to the "security" tab via upload-sarif. We actually want zizmor to fail in CI during PR review so disabling its advanced-security feature

@kevinjqliu kevinjqliu merged commit d37ec8b into apache:main Mar 30, 2026
41 of 43 checks passed
@kevinjqliu kevinjqliu deleted the kevinjqliu/code-scan-fix branch March 30, 2026 20:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants