Skip to content

CI: drop persisted checkout tokens and pin npm in the publish job #482

Open

Description

@wjsoj

Hi! A small CI hardening suggestion, ready in #464.

  • ci.yml (check job) and sync-hypihub-docs.yml (notify job) use actions/checkout with the default persist-credentials: true, so GITHUB_TOKEN stays in .git/config for every later step. Neither job needs git credentials after checkout, and the other workflows already set persist-credentials: false.
  • publish-npm.yml installs npm@11 (whatever 11.x is newest on release day) in the job that holds the publishing identity. fix(ci): drop persisted checkout tokens and pin npm in the publish job #464 pins it to [email protected], which supports trusted publishing.

zizmor reports exactly those two findings fewer with the change and nothing new; actionlint is unchanged; all checks pass on the PR. Nothing here is exploitable today (the token is read-only on these jobs) — it's defence in depth.

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions