SecurityContext

CVE-2021-21423: projen - Insecure GitHub Workflow Execution

  • Cve: CVE-2021-21423
  • Name: projen - Insecure GitHub Workflow Execution
  • Description: `projen` is a project generation tool that synthesizes project configuration files such as `package.json`, `tsconfig.json`, `.gitignore`, GitHub Workflows, `eslint`, `jest`, and more, from a well-typed definition written in JavaScript. Users of projen's `NodeProject` project type (including any project type derived from it) include a `.github/workflows/rebuild-bot.yml` workflow that may allow any GitHub user to trigger execution of un-trusted code in the context of the "main" repository (as opposed to that of a fork). In some situations, such untrusted code may potentially be able to commit to the "main" repository. The rebuild-bot workflow is triggered by comments including `@projen rebuild` on pull-request to trigger a re-build of the projen project, and updating the pull request with the updated files. This workflow is triggered by an `issue_comment` event, and thus always executes with a `GITHUB_TOKEN` belonging to the repository into which the pull-request is made (this is in contrast with workflows triggered by `pull_request` events, which always execute with a `GITHUB_TOKEN` belonging to the repository from which the pull-request is made). Repositories that do not have branch protection configured on their default branch (typically `main` or `master`) could possibly allow an untrusted user to gain access to secrets configured on the repository (such as NPM tokens, etc). Branch protection prohibits this escalation, as the managed `GITHUB_TOKEN` would not be able to modify the contents of a protected branch and affected workflows must be defined on the default branch.
  • Impact: Untrusted users can trigger workflows that execute untrusted code, potentially leading to code execution or access to secrets in repositories without branch protection.
  • Remediation: Implement branch protection on the default branch and restrict workflow triggers to trusted users or specific events.
  • Vulnerability type: misconfiguration
  • Vulnerability impact: remote_code_execution, information_disclosure
  • Requirement type: user_interaction
  • Requirements: Attacker needs to comment '@projen rebuild' on a pull request
  • Labels source: projectdiscovery
  • Severity: high
  • Cvss score: 8.1
  • Cvss vector: CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:N
  • Epss score: 0.01392
  • Epss percentile: 0.72927
  • Assignee: [email protected]
  • Published at: 2021-04-06T19:15:14Z
  • Age in days: 2058
  • Modified at: 2026-06-17T03:35:32Z
  • Patch available: yes
  • Public exploits total: 1
  • References total: 3
  • Products total: 1
  • Oss: yes
  • Projects total: 1
  • Advisory url: https://nvd.nist.gov/vuln/detail/CVE-2021-21423
  • Nvd status: modified
  • Checked, none or zero: known exploited entries, nuclei templates, public exploits capped, rejected by nvd
  • Not known: hackerone

Cwe

IdName
CWE-527Exposure of Version-Control Repository to an Unauthorized Control Sphere

Public exploits

UrlSourceAdded date
https://github.com/pvharmo2/gha-lab-b9842b12c0poc-in-github2026-08-31

References

Same in every row:

  • Source: nvd
UrlTags
https://github.com/projen/projen/commit/36030c6a4b1acd0054673322612e7c70e9446643Patch, Third Party Advisory
https://github.com/projen/projen/security/advisories/GHSA-gg2g-m5wc-vccqMitigation, Third Party Advisory
https://www.npmjs.com/package/projenProduct, Third Party Advisory

Products

ProductAffectedPlatform boundSourcesUrl
projen_project:projen>= 0.6.0, < 0.16.41nonvd/v1/products/projen_project/projen

Projects

RepositoryLink kindsIndexedUrl
projen/projencommit, fix, package, security_advisoryyes/v1/repositories/projen/projen

Index

  • Repositories: 1
  • Checked, none or zero: repositories high signal, packages

Exploitation

  • Public exploit: yes
  • Public exploit count: 1
  • Public exploit first date: 2026-08-31
  • Remote: yes
  • Authentication required: yes
  • Checked, none or zero: known exploited, known exploited by, exploitation seen, initial access
  • Not known: known exploited since, vulncheck known exploited since, nuclei template, initial access since, hackerone reports, exposed hosts