Skip to content

ci: drop top-level contents: write from smoke workflows #94

Closed

Description

@c-vigo

Problem

OpenSSF Scorecard's TokenPermissions check scores 0 because two workflows grant contents: write at the top level (workflow scope), exposing a write token to every job and step by default:

Both workflows genuinely need contents: write (they push a scratch branch and the action under test commits to it), but only inside their single job.

Fix

In both files:

  • top level: permissions: {} (restrict default; job declares its own — same pattern as codeql.yml / scorecard.yml / sync-issues.yml)
  • job level: contents: write with a comment stating why (scratch-branch push + action commit)

Verification

Out of scope

Job-level contents: write in the release pipeline (17 remaining Scorecard alerts) — tracked separately; several of those files are devkit-managed and any change belongs upstream.

Activity

  1. added
    task
    on Jul 15, 2026
  2. c-vigo commented on Jul 15, 2026

    @c-vigo
    ContributorAuthor

    Fixed by #95 (merged as 63d951b). Scorecard alerts #27/#23 will auto-close once the change reaches main and the next analysis runs.

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

    task

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions