PSF hardens GitHub orgs against 'pwn request' supply-chain attacks ahead of GitHub default block
The Python Software Foundation has proactively removed dangerous GitHub Actions triggers across its psf, python, and pypi organizations before GitHub's December 2, 2026 default block, documenting the process for other open-source projects after these triggers caused multiple PyPI supply-chain compromises.
Summary
On December 2, 2026, GitHub will begin blocking the pull_request_target trigger by default in public repositories. Ahead of this change, PSF Security Developer in Residence Seth Larson and PyPI Safety and Security Engineer Mike Fiedler have systematically removed dangerous triggers and applied restrictive event policies across the three major PSF-stewarded GitHub organizations: psf, python, and pypi. They have also published technical documentation to help other organizations replicate this hardening.
The urgency of this work is underscored by multiple real supply-chain incidents traced directly to these triggers. The December 2024 Ultralytics compromise, the March 2026 LiteLLM and Telnyx incidents, and the April 2026 elementary-data attack all involved malicious releases reaching PyPI after attackers exploited pull_request_target or issue_comment workflows to gain write access to repositories or poison build caches. The PSF's documentation effort, supported by the Alpha-Omega security fund, aims to reduce similar incidents across the broader open-source ecosystem.
Dangerous trigger mechanics and PSF organizational hardening
- pull_request_target vs. pull_request: The pull_request trigger runs fork code with a read-only token and no secrets, while pull_request_target runs with a read/write token and full repository and organization secret access, creating a 'pwn request' when workflows check out and execute the fork's code.
- issue_comment injection risk: The issue_comment trigger similarly executes with repository tokens and secrets, enabling shell injection when comment text is passed directly into templated shell commands, as seen in the elementary-data incident.
- Organizational policy enforcement: On GitHub Team and Enterprise plans, a single organization-wide policy can disable these triggers across all repositories; Free plan users must configure each repository individually.
- PSF scope of remediation: Fiedler and Larson applied policies to the psf, python, and pypi organizations, with Larson actively migrating remaining repositories in the python organization before fully enabling the restrictive event policy.
- Alpha-Omega funding model: The work was enabled by Alpha-Omega's sustained funding of both Fiedler's PyPI security role and Larson's Security Developer in Residence position, covering incident response, policy implementation, and community documentation.
Why it matters
This PSF-led initiative provides a concrete, replicable playbook for the thousands of open-source projects that rely on GitHub Actions but lack dedicated security staff, directly addressing one of the most exploited vectors in software supply-chain attacks. For Linux distributions and system administrators consuming PyPI packages, reduced compromise risk in the Python packaging pipeline translates to fewer malicious packages reaching downstream builds and containers. The Alpha-Omega funding model demonstrated here also offers a template for how security-focused grants can enable maintainers to perform ecosystem-wide hardening that individual volunteer projects cannot prioritize.
What to do
- For GitHub Team or Enterprise plans, use an organization-wide policy to disable dangerous triggers.
- For Free plan users, configure each repository individually to disable dangerous triggers.
- Set up the policy, check what it would block, and then enforce it.
Original reference: pyfound.blogspot.com →