{"id":"CVE-2026-53597","revision":null,"records":[{"revision":"7274d14ad99540c18a3e5c93f934d5f2","observedAt":"2026-10-23T15:48:27.903+00:00","statement":{"source":"cve-program","id":"CVE-2026-53597","aliases":[],"title":"Prompty: Arbitrary code execution via JavaScript frontmatter in TypeScript loader","description":"Prompty is a markdown file format (.prompty) for LLM prompts. From 2.0.0-alpha.1 until 2.0.0-beta.3, the @prompty/core TypeScript loader in runtime/typescript/packages/core/src/core/loader.ts used gray-matter without overriding executable js and javascript frontmatter engines, allowing an attacker-controlled .prompty file with ---js frontmatter to execute arbitrary JavaScript during prompt loading. This issue is fixed in version 2.0.0-beta.3.","state":0,"publishedAt":"2026-07-16T14:54:55.075+00:00","modifiedAt":"2026-07-18T02:51:03.9+00:00","affected":[{"ecosystem":"Vendor product","name":"prompty","ranges":[],"versions":[],"rawVersionEvidence":"{\n                    \"vendor\": \"microsoft\",\n                    \"product\": \"prompty\",\n                    \"versions\": [\n                        {\n                            \"version\": \">= 2.0.0-alpha.1, < 2.0.0-beta.3\",\n                            \"status\": \"affected\"\n                        }\n                    ]\n                }"}],"metrics":[{"system":"CVSS 4.0","vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N","score":8.7,"severity":"HIGH"}],"references":["https://github.com/microsoft/prompty/security/advisories/GHSA-c4gh-rv8h-q9vw","https://github.com/microsoft/prompty/commit/c27402da2487075be577f06aa79df627fb9d6853"],"sourceUrl":"https://www.cve.org/CVERecord?id=CVE-2026-53597","license":"CVE Program Terms of Use","key":"cve-program:CVE-2026-53597","identifiers":["CVE-2026-53597"]},"retained":false,"historicalAffected":[]},{"revision":"beb35a55226245789fc50ff63aa3d096","observedAt":"2026-10-25T13:17:16.273+00:00","statement":{"source":"nvd","id":"CVE-2026-53597","aliases":[],"title":"Prompty is a markdown file format (.prompty) for LLM prompts. From 2.0.0-alpha.1 until 2.0.0-beta.3, the @prompty/core TypeScript loader in runtime/typescript/packages/core/src/core/loader.ts used gray-matter without overriding executable j…","description":"Prompty is a markdown file format (.prompty) for LLM prompts. From 2.0.0-alpha.1 until 2.0.0-beta.3, the @prompty/core TypeScript loader in runtime/typescript/packages/core/src/core/loader.ts used gray-matter without overriding executable js and javascript frontmatter engines, allowing an attacker-controlled .prompty file with ---js frontmatter to execute arbitrary JavaScript during prompt loading. This issue is fixed in version 2.0.0-beta.3.","state":0,"publishedAt":"2026-07-16T16:19:12.86+00:00","modifiedAt":"2026-10-24T20:10:00.137+00:00","affected":[],"metrics":[{"system":"CVSS 4.0 · security-advisories@github.com · Secondary","vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X","score":8.7,"severity":"HIGH"}],"references":["https://github.com/microsoft/prompty/commit/c27402da2487075be577f06aa79df627fb9d6853","https://github.com/microsoft/prompty/security/advisories/GHSA-c4gh-rv8h-q9vw"],"sourceUrl":"https://nvd.nist.gov/vuln/detail/CVE-2026-53597","license":"NIST NVD usage terms; underlying source attribution retained","enrichment":{"sourceStatus":"Deferred","weaknesses":["CWE-94"],"productCriteria":[],"sourceDates":{"published":"2026-07-16T16:19:12.860","lastModified":"2026-10-24T20:10:00.137"},"relatedAdvisories":[],"note":"NVD analysis and CPE criteria are source context, not proof that a package or your environment is affected. Complete affected data, logical configurations and SSVC are retained in the original JSON."},"key":"nvd:CVE-2026-53597","identifiers":["CVE-2026-53597"]},"retained":false,"historicalAffected":[]},{"revision":"06e142efb2e04c048ce3de6e83f14fe9","observedAt":"2026-10-24T13:17:17.793+00:00","statement":{"source":"osv","id":"GHSA-c4gh-rv8h-q9vw","aliases":["CVE-2026-53597"],"title":"Prompty: Arbitrary code execution via JavaScript frontmatter in TypeScript loader","description":"## Summary\nThe 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.\n\n## Affected package\n- npm `@prompty/core` v2 prerelease line: `>= 2.0.0-alpha.1 < 2.0.0-beta.3`\n- Fixed in `@prompty/core@2.0.0-beta.3`\n\nThe 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`.\n\n## Impact\nApplications 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.\n\n## Remediation\nUpgrade `@prompty/core` to `2.0.0-beta.3` or later.\n\nThe 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.\n\n## Fix details\nFixed by commit `c27402da2487075be577f06aa79df627fb9d6853` and released via `typescript/2.0.0-beta.3`.","state":0,"publishedAt":"2026-07-17T19:53:34+00:00","modifiedAt":"2026-07-17T20:00:17.099953+00:00","affected":[{"ecosystem":"npm","name":"@prompty/core","ranges":[{"type":"SEMVER","events":[{"kind":"introduced","version":"2.0.0-alpha.1"},{"kind":"fixed","version":"2.0.0-beta.3"}]}],"versions":[],"rawVersionEvidence":null}],"metrics":[{"system":"CVSS_V4","vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N","score":null,"severity":null},{"system":"Publisher rating","vector":null,"score":null,"severity":"HIGH"}],"references":["https://github.com/microsoft/prompty/security/advisories/GHSA-c4gh-rv8h-q9vw","https://nvd.nist.gov/vuln/detail/CVE-2026-53597","https://github.com/microsoft/prompty/commit/c27402da2487075be577f06aa79df627fb9d6853","https://github.com/microsoft/prompty"],"sourceUrl":"https://github.com/advisories/GHSA-c4gh-rv8h-q9vw","license":"GitHub Advisory Database · CC-BY-4.0","key":"osv:GHSA-c4gh-rv8h-q9vw","identifiers":["GHSA-c4gh-rv8h-q9vw","CVE-2026-53597"]},"retained":false,"historicalAffected":[]}],"coverage":[{"source":"cisa-kev:global","scope":"Complete CISA KEV catalog; all vendors. Missing entries do not establish absence of exploitation.","generation":"2026-10-27T03:23:00.5555620+00:00","complete":true,"records":1758,"lastAttemptAt":"2026-10-27T03:23:00.555562+00:00","lastSuccessAt":"2026-10-27T03:23:00.6986702+00:00","error":null,"lastVerifiedAt":"2026-10-27T03:23:00.6986732+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null},{"source":"cve-program","scope":"Official CVE Program baseline and cumulative hourly delta; all vendors, published and rejected records","generation":"cve-187d2b72c94ceb8c4417f1032ec3109a3a3a7b730abadb561d8cdd2a96e04d27-57af8b9cb8b3567e0ff1c465b55549984a63d39a842292251efe141cd38b38c5","complete":true,"records":414860,"lastAttemptAt":"2026-10-27T04:22:56.0335839+00:00","lastSuccessAt":"2026-10-27T03:22:59.8407535+00:00","error":null,"lastVerifiedAt":"2026-10-27T03:22:59.8670088+00:00","snapshotPublishedAt":"2026-10-27T02:35:43+00:00","importing":true,"stagedRecords":88,"checkedIdentifiers":null,"expectedIdentifiers":null},{"source":"euvd","scope":"Rolling EUVD lookups of CVE aliases in current public OSV archives; 500 identifiers per refresh, rechecked after 48 hours. Not a global EUVD catalog. Successful not-found lookups count as checked; they do not imply withdrawal or safety. No reader inventory is sent.","generation":"enrichment-43321610382942b8ad8c85917eab1546","complete":false,"records":4735,"lastAttemptAt":"2026-10-27T03:23:28.43141+00:00","lastSuccessAt":"2026-10-24T23:18:49.862+00:00","error":"InvalidDataException","lastVerifiedAt":"2026-10-24T23:18:49.862+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":0,"expectedIdentifiers":13477},{"source":"first-epss:nuget","scope":"FIRST EPSS for explicit CVE aliases in the collected public NuGet archive. Not a global EPSS backfill.","generation":"2026-10-27T03:23:00.5555620+00:00","complete":true,"records":1093,"lastAttemptAt":"2026-10-27T03:23:00.555562+00:00","lastSuccessAt":"2026-10-27T03:23:00.6994805+00:00","error":null,"lastVerifiedAt":"2026-10-27T03:23:00.699481+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null},{"source":"nvd","scope":"Rolling NVD lookups of CVE aliases in current public OSV archives; 500 identifiers per refresh, rechecked after 48 hours. Not a global NVD catalog. Successful not-found lookups count as checked; they do not imply withdrawal or safety. No reader inventory is sent.","generation":"enrichment-0359020e244b476eb2e837e8432b1f32","complete":false,"records":13416,"lastAttemptAt":"2026-10-27T03:23:26.5209764+00:00","lastSuccessAt":"2026-10-27T03:23:26.517+00:00","error":null,"lastVerifiedAt":"2026-10-27T03:23:26.517+00:00","snapshotPublishedAt":null,"importing":false,"stagedRecords":0,"checkedIdentifiers":13077,"expectedIdentifiers":13477},{"source":"osv:Go","scope":"Complete OSV Go ecosystem archive, including withdrawn and malicious-package source records; statement counts are not unique CVE counts","generation":"go-c3121b113ecd88f1c92ccfa0ec9757ddc8386e4c12afd2597450b815744f800a","complete":true,"records":9779,"lastAttemptAt":"2026-10-27T03:23:00.5062933+00:00","lastSuccessAt":"2026-10-26T15:37:14.3083004+00:00","error":null,"lastVerifiedAt":"2026-10-27T03:23:00.5062933+00:00","snapshotPublishedAt":"2026-10-26T14:48:41+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null},{"source":"osv:NuGet","scope":"Complete OSV NuGet ecosystem archive, including GitHub Advisory Database records; NuGet version matching only","generation":"nuget-bad5d31e7f6a5e3d338e11d8789069b63620a403f927730769688b42f768e4f6","complete":true,"records":1965,"lastAttemptAt":"2026-10-27T03:22:59.9290096+00:00","lastSuccessAt":"2026-10-26T16:35:43.1460623+00:00","error":null,"lastVerifiedAt":"2026-10-27T03:22:59.9290096+00:00","snapshotPublishedAt":"2026-10-26T16:18:29+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null},{"source":"osv:crates.io","scope":"Complete OSV crates.io ecosystem archive, including withdrawn and malicious-package source records; statement counts are not unique CVE counts","generation":"crates.io-a393d8fe0ae8408f3e4cab413b76047090c8e4a3c0a186c79edf33c9a3d3af95","complete":true,"records":2995,"lastAttemptAt":"2026-10-27T03:23:00.5277541+00:00","lastSuccessAt":"2026-10-26T14:35:47.9640893+00:00","error":null,"lastVerifiedAt":"2026-10-27T03:23:00.5277541+00:00","snapshotPublishedAt":"2026-10-26T14:18:55+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null},{"source":"osv:npm","scope":"Complete OSV npm ecosystem archive, including withdrawn and malicious-package source records; statement counts are not unique CVE counts","generation":"npm-2c2579bb03487537529e2b647fd2d9950cfc0fec1a9832dba33e322b8dcbe369","complete":true,"records":230812,"lastAttemptAt":"2026-10-27T03:23:00.4041305+00:00","lastSuccessAt":"2026-10-26T21:37:26.5810298+00:00","error":null,"lastVerifiedAt":"2026-10-27T03:23:00.4041305+00:00","snapshotPublishedAt":"2026-10-26T21:33:12+00:00","importing":false,"stagedRecords":0,"checkedIdentifiers":null,"expectedIdentifiers":null}]}