Skip to content

ci: protect npm installs with Socket Firewall - #104

Draft
peakematt wants to merge 1 commit into
mainfrom
feature/help-724-add-socket-firewall
Draft

ci: protect npm installs with Socket Firewall#104
peakematt wants to merge 1 commit into
mainfrom
feature/help-724-add-socket-firewall

Conversation

@peakematt

@peakematt peakematt commented Sep 3, 2026

Copy link
Copy Markdown

authkit-react downloads public npm packages in normal continuous integration, its reusable release workflow, and its scheduled Socket analysis workflow. Those downloads currently bypass the WorkOS Socket Firewall, while the release job must still publish directly to npm after installation.

This change protects each download with action-only release ca93dd8aa351f54f4729fe3377a9be23c631c25d. The selected-repository PUBLIC_SOCKET_FIREWALL_TOKEN secret is passed only to the setup action. Public fork pull requests can use the action's validated public-registry fallback, while same-repository and default-branch jobs remain fail-closed. Checkout credentials are no longer persisted and fork-reachable permissions are read-only.

The reusable release workflow receives only the named firewall secret. It configures Socket Firewall after setup-node, installs dependencies, and invokes teardown at the same release SHA before building or publishing. This preserves npm trusted publishing and prevents the firewall credential or registry from reaching publication. The scheduled Socket CLI install uses the same setup/install/teardown boundary. The pull_request_target title-lint workflow does not check out or execute contributor-controlled code and is unchanged.

Verify the workflow structure with:

go run github.com/rhysd/actionlint/cmd/actionlint@v1.7.10 .github/workflows/*.yml

The rollout classifier reports all three npm download jobs as protected with no ordering, release-reference, token, publication, or trust violations. Two independent reviews found no public-trust or publication-boundary blockers. The same-repository token-backed install passed, and temporary external-fork run 33780874100 confirmed that GitHub withheld the token while the validated public-registry fallback completed successfully. An isolated 0.0.0-help724 publish dry run explicitly targeted https://registry.npmjs.org/ and did not publish.

Before merge, PUBLIC_SOCKET_FIREWALL_TOKEN must also be available from the separate Dependabot secret store so dependency-update pull requests remain fail-closed and green. No real package publication is performed as part of this change.

@linear-code

linear-code Bot commented Sep 3, 2026

Copy link
Copy Markdown

HELP-724

@peakematt peakematt changed the title Protect npm installs with Socket Firewall ci: protect npm installs with Socket Firewall Sep 3, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant