hn.today

De-fanging dangerous triggers in GitHub Actions across an organization

alpha-omega.dev3 points0 comments
Screenshot of De-fanging dangerous triggers in GitHub Actions across an organization

GitHub Actions’ pull_request_target and issue_comment triggers can let anyone initiate workflows that run with repository or organization secrets and write-capable tokens. They are especially dangerous when a workflow checks out and executes code from a contributor’s fork, or inserts a public comment into a shell command. Such weaknesses have enabled supply-chain attacks, including compromised PyPI releases involving Ultralytics, LiteLLM, Telnyx, and elementary-data. GitHub plans to block pull_request_target by default in public repositories on December 2, 2026, but organizations can reduce exposure sooner by setting event policies: paid plans can apply them across an organization, while Free plans require repository-by-repository controls.

The recommended approach is an explicit allowlist of needed events, starting with pull_request, push, release, repository_dispatch, schedule, workflow_dispatch, and workflow_run; the latter still requires care with untrusted artifacts and is unsuitable for sensitive publishing. Teams can search workflow files and recent runs, use Zizmor to find insecure patterns, then apply a policy in Evaluate mode and inspect Policy Insights before enforcing it. Blocking triggers may disrupt labelers, comment-command bots, issue triage, merge queues, and reusable workflows, so maintainers should be consulted and alternatives arranged. Add events back only deliberately. Registry safeguards such as PyPI Trusted Publishing can block some dangerous publishing paths, but do not replace workflow-level protections.

Read on alpha-omega.dev0 comments on Hacker News

Summary generated by AI from the linked article. hn.today is not affiliated with Hacker News or Y Combinator.

More in Security

U.S. Tracked Alice Huang's Contacts with China Spy Agency During Nvidia Affair

U.S. Tracked Alice Huang's Contacts with China Spy Agency During Nvidia Affair

U.S. intelligence reports say Alice Huang maintained contact with China’s Ministry of State Security while in a relationship with Nvidia chief Jensen Huang, and her business partner also worked with the agency. U.S. officials are investigating whether the pair helped route Nvidia chips through Southeast Asia to China in violation of export controls. (nytimes.com)

The daily digest

Today's best Hacker News stories, summarized and screenshotted, one email a day.