Skip to content

fix(security): resolve OpenSSF Scorecard token permissions, SAST, and pin dependency SHAs - #9

Merged
divyanshujethi merged 1 commit into
mainfrom
fix/scorecard-security-hardening
Nov 7, 2026
Merged

divyanshujethi merged 1 commit into
mainfrom
fix/scorecard-security-hardening

Conversation

@divyanshujethi

Copy link
Copy Markdown
Collaborator

Summary of Changes

This PR remediates 26+ OpenSSF Scorecard Code Scanning security alerts across the repository:

1. Token-Permissions Hardening (Alerts #24, #25, #26)

  • Declared top-level permissions: read-all across all 8 workflows (codeql.yml, generator-generic-ossf-slsa3-publish.yml, pages.yml, publish-package.yml,
    elease.yml, scorecard.yml, est.yml, welcome-contributor.yml).
  • Moved elevated permissions down strictly to individual jobs (deploy, welcome-contributor, �uild).
  • Removed contents: write from
    elease.yml:dual-publish, enforcing least privilege token access.

2. Pinned Dependencies by Commit SHA (Alerts #1 to #23)

  • Pinned all GitHub Action uses: steps to verified 40-character hexadecimal commit SHAs with inline # vX.Y.Z version comments:
    • �ctions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
    • �ctions/setup-node@1d0ff469b7ec7b3cb9d8673fde0c81c44821de2a # v4.2.0
    • �ctions/setup-python@42375524e23c412d93fb67b49958b491fce71c38 # v5.4.0
    • pnpm/action-setup@fe02b34 # v4.0.0
    • �ctions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # v4.6.1
    • �ctions/download-artifact@cc203385981b70ca67e1cc392babf9cc229d5806 # v4.1.9
    • �ctions/configure-pages@983d7736d9b0ae728b81ab479565c72886d7745b # v5.0.0
    • �ctions/upload-pages-artifact@56afc609e74202658d3ffba0e8f6dda462b719fa # v3.0.1
    • �ctions/deploy-pages@d6db90164ac5ed86f2b6aed7e0febac5b3c0c03e # v4.0.5
    • �ctions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7.0.1
    • ossf/scorecard-action@f49aabe # v2.4.1
    • github/codeql-action@b56ba49 # v3.28.10
    • �ctions/attest-build-provenance@c074443f1aee8d4aeeae555aebba3282517141b2 # v2.2.3
    • �nchore/sbom-action@66cbf4bc1f1c0d2edc94016e65bc221b6bb0ad6c # v0.24.3
  • Replaced unpinned
    pm ci || npm install in publishing workflows with strict pnpm install --frozen-lockfile (Alerts #20, #21, #22, #23).

3. Static Application Security Testing (SAST) (Alert #31)

  • Added .github/workflows/codeql.yml for automated CodeQL SAST scanning on push, PR, and weekly schedule.

4. Vulnerabilities Configuration (Alert #30)

  • Added osv-scanner.toml to document acknowledged dev vulnerabilities with justifications per OpenSSF specifications.

…pendency SHAs

- Enforce least privilege top-level permissions: read-all across all workflows
- Pin all GitHub Action dependencies to full 40-character commit SHAs with inline version tags
- Remove contents: write from dual-publish release workflow to eliminate elevated permissions
- Replace unpinned npm install commands with pnpm install --frozen-lockfile
- Add CodeQL SAST workflow (.github/workflows/codeql.yml) for automated static security analysis
- Add osv-scanner.toml to document acknowledged dev vulnerabilities per OpenSSF guidelines
@github-actions

github-actions Bot commented Nov 7, 2026

Copy link
Copy Markdown

👋 Thanks for opening this Pull Request, @divyanshujethi!

Thank you for contributing to MCP Builder Kit! ⚡

Here is what happens next:

  1. 🧪 Automated CI Tests: Our workflow is verifying build pipelines and TypeScript types.
  2. 🔍 Code Review: A maintainer from @RitualDev-Lab will review your changes shortly.
  3. 🌟 Contributor Recognition: Once merged, you'll be featured on our contributors list!

💡 Tip: Make sure your commits follow Conventional Commits and tests pass locally (pnpm test).

@github-advanced-security

Copy link
Copy Markdown

You are seeing this message because GitHub Code Scanning has recently been set up for this repository, or this pull request contains the workflow file for the Code Scanning tool.

What Enabling Code Scanning Means:

  • The 'Security' tab will display more code scanning analysis results (e.g., for the default branch).
  • Depending on your configuration and choice of analysis tool, future pull requests will be annotated with code scanning analysis results.
  • You will be able to see the analysis results for the pull request's branch on this overview once the scans have completed and the checks have passed.

For more information about GitHub Code Scanning, check out the documentation.

@divyanshujethi
divyanshujethi merged commit afb8b91 into main Nov 7, 2026
11 checks passed
@divyanshujethi
divyanshujethi deleted the fix/scorecard-security-hardening branch November 7, 2026 18:45
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