Your RSA-2048 keys break in 2030. Find every one of them before attackers do.
📦 npm
Not in CISA KEV

CVE-2026-53597 — @prompty/core

Fix: microsoft/prompty@c27402d

CVE-2026-53597 is a Code Injection vulnerability in @prompty/core. A fix is available for @prompty/core — see the affected versions and patch details below.

Prompty: Arbitrary code execution via JavaScript frontmatter in TypeScript loader

Also known asGHSA-c4gh-rv8h-q9vw
Published
Updated
Affected
1 pkg
Patched
1 / 1
Exploits
None indexed
Exploitation data as of Oct 15, 2026 · OSV.dev, NVD, FIRST.org (EPSS)

Exploitation Status

No confirmed exploitation observed yet

  • CISA’s own triage has not observed active exploitation or public proof-of-concept code for this CVE as of its last assessment.

Exploitation and automatability from CISA’s SSVC triage for CVE-2026-53597.

EPSS Exploitation Probability

via FIRST.org ↗
1.0%probability of exploitation in next 30 days
Lower Risk+0.04%
Lower risk than most CVEs61th percentile — riskier than 61% of all scored CVEsHighest risk
0.43%0.78%1.13%1.47%0.9%1.0%Aug 26Oct 26

Probability of exploitation in the next 30 days, from FIRST.org EPSS.

Real-World Exposure

1 pkg affected

How broadly this vulnerability is actually deployed: weekly install volume shows current usage, and reverse-dependency count shows how many other packages break if it stays unpatched.

3other npm packages depend on this — each one inherits the vulnerability until it's patched upstream
@prompty/corenpm
160downloads / week

Description

Summary

The TypeScript Prompty loader used gray-matter without overriding executable frontmatter engines. gray-matter supports JavaScript frontmatter blocks such as ---js and evaluates them while parsing. An attacker-controlled .prompty file could therefore execute arbitrary JavaScript during prompt loading.

Affected package

  • npm @prompty/core v2 prerelease line: >= 2.0.0-alpha.1 < 2.0.0-beta.3
  • Fixed in @prompty/[email protected]

The legacy v1 JavaScript runtime had a historical hardening change for this issue. During the v2 TypeScript runtime rebuild, the loader again called gray-matter directly and the vulnerable behavior was present in the v2 prerelease packages until 2.0.0-beta.3.

Impact

Applications that load untrusted .prompty files, user-provided prompt paths, or prompt bundles from less-trusted locations could execute arbitrary JavaScript in the host Node.js process during frontmatter parsing.

Remediation

Upgrade @prompty/core to 2.0.0-beta.3 or later.

The fix explicitly overrides the js and javascript gray-matter engines and rejects JavaScript frontmatter in .prompty files. Prompty frontmatter is YAML-only; executable frontmatter is unsupported. A regression test now verifies that ---js frontmatter is rejected and not evaluated.

Fix details

Fixed by commit c27402da2487075be577f06aa79df627fb9d6853 and released via typescript/2.0.0-beta.3.

Affected Packages

1 total 1 fixed
EcosystemPackageVulnerable rangeFix
📦npm@prompty/core≥ 2.0.0-alpha.1&&< 2.0.0-beta.32.0.0-beta.3npm install @prompty/core@2.0.0-beta.3

Detection & mitigation playbook

Open-source dependency
  1. Detect

    Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for @prompty/core, including transitive dependencies — a direct dependency you never call can still pull in a vulnerable version.

  2. Fix

    Update @prompty/core to 2.0.0-beta.3 or later, then make sure no transitive (indirect) dependency still pins the vulnerable range — O3 confirms CVE-2026-53597 is resolved across your whole dependency graph.

  3. Workarounds

    Stop passing untrusted input into the interpreter or shell: call the affected binary with an argument array rather than a composed command string, reject anything outside a strict allowlist of expected values, and run the component under an account that cannot reach beyond the work it legitimately does.

Frequently Asked Questions

## Summary The TypeScript Prompty loader used `gray-matter` without overriding executable frontmatter engines. `gray-matter` supports JavaScript frontmatter blocks such as `---js` and evaluates them while parsing. An attacker-controlled `.prompty` file could therefore execute arbitrary JavaScript during prompt loading. ## Affected package - npm `@prompty/core` v2 prerelease line: `>= 2.0.0-alpha.1 < 2.0.0-beta.3` - Fixed in `@prompty/[email protected]` The legacy v1 JavaScript runtime had a historical hardening change for this issue. During the v2 TypeScript runtime rebuild, the loader again
O3 Security · Impact-Aware SCA

Is CVE-2026-53597 in your dependencies?

Find it across npm, including transitive dependencies.

CVE-2026-53597: @prompty/core — Fixed in 2.0.0-beta.3