Vulnerability in projen (CVE-2021-21423)
Summary
Vulnerability in projen (CVE-2021-21423). Confidential information can be exposed externally. Exploitable via projen. Mitigation: upgrade to 0.16.41 or later.
Original description
The description as published by the source.
Impact
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 b…
Source: OSV.dev (Open Source Vulnerabilities) NVD GitHub Advisory OSV
Auto-generated summary
Assembled by SecPulse from the source data (CVSS, CWE, affected versions) using templates — no AI involved. Check the original description and references below for exact details.
A vulnerability tracked as CVE-2021-21423 has been found in projen.
Attackers can target a specific entry point like projen over the network to misuse the product.
Confidential information can be exposed externally.
What to do: upgrade projen to 0.16.41 or later.
If unsure, ask your IT team or search "projen CVE-2021-21423" on the vendor's site.
CVE-2021-21423 (projen) — CWE-527
Attack vector: remote (network-reachable) / no user interaction
Attack surface: projen / eslint / jest / NodeProject
Patched: 0.16.41 — apply immediately
Workaround: The recommended way to address the vulnerability is to upgrade projen.
Plan: 1) Audit SBOM/dependencies, 2) Stage→prod upgrade, 3) Add WAF/proxy monitoring on affected endpoints, 4) Hunt IOCs in logs.
Refs: see the GHSA / vendor advisory / patched release linked on this page.
A vulnerability (CWE-527) exists in projen. Attackers reach the vulnerable code path via projen.
Check the vendor advisory for the affected versions of projen. Attack surface: projen / eslint / jest / NodeProject.
Severity: ?. Confidential information can be exposed externally.
Update to 0.16.41.
Workaround: The recommended way to address the vulnerability is to upgrade projen.
Search webserver/proxy logs for unusual request patterns matching this CVE's known IOCs. Run grep -r 'projen' . against your dependency files (package-lock.json, requirements.txt, go.sum) to find affected services.
Response actions
Concrete steps and command examples for SOC/SRE teams to execute in order
-
1Identify exposure identify
grep -r 'projen' . | grep -v node_modulesリポジトリと本番環境の依存ファイル (package-lock.json / requirements.txt / go.sum / Gemfile.lock 等) で
projenを grep し、稼働しているサービス・バージョンを把握する。 -
2Apply temporary workaround mitigate
The recommended way to address the vulnerability is to upgrade `projen`.パッチが適用されるまでの応急処置として、The recommended way to address the vulnerability is to upgrade
projen. を実施。回避策の副作用 (機能低下) を確認した上で。 -
3Apply patch patch
Upgrade projen to 0.16.41ステージング環境で 0.16.41 に上げて回帰テスト → 本番反映。回帰テストはアプリの主要ハッピーパスを含めること。
-
4Post-deployment verification verify
Confirm patched version is live in productionパッチ適用後、ステージングで PoC または同等の悪用パターンを再現して脆弱性が閉じたことを確認。本番ではアクセスログ・WAF でアラート再発が無いか継続監視。
Affected packages
References
- advisory nvd.nist.gov
- package github.com
- web github.com
- web github.com
- web github.com
- web npmjs.com