CVE-2026-108551
published critical CVSS 4.0 · 9.3openapi-typescript-codegen through 0.31.0 Code Injection via Handlebars Templates
Package status and fixes
| Distro / vendor | Release | Package / product | Publisher status | Fixed build | Source |
|---|---|---|---|---|---|
| ferdikoomen | — | openapi-typescript-codegen0 through 0.31.0 · Other versions: unaffected | Affected | Not stated | VulnCheck |
Description
openapi-typescript-codegen through 0.31.0 contains a code injection vulnerability that allows attackers controlling an OpenAPI document to inject JavaScript by supplying unescaped values interpolated into single-quoted string literals. Attackers can embed a single quote in path keys, parameter names, servers[0].url, or info.version to execute arbitrary JavaScript when generated clients are imported or service methods called.
Related advisories
Vendor advisories explicitly linked to this CVE.
No linked advisories were found for this CVE.
Assessment
CVSS risk assessment and additional context for this vulnerability.
- CVSS version
- 4.0
- Base score
- 9.3 / 10
- Severity
- critical
- Provider
- VulnCheck · cna
- Vector string
- CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N
Additional Assessments
| Version | Score | Severity | Provider | Vector | Scenarios |
|---|---|---|---|---|---|
| 3.1 | 9.8 | critical | VulnCheck · cna | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H | — |
Publisher product statements
Version ranges and default statuses as reported by each provider.
| Vendor | Product | Version status | Source |
|---|---|---|---|
| ferdikoomen | openapi-typescript-codegen | 0 through 0.31.0 (affected · semver)Default: unaffected | VulnCheck · cna |
Weaknesses
1- CWE-94 Improper Control of Generation of Code ('Code Injection')
References
5- https://github.com/ferdikoomen/openapi-typescript-codegen
- https://github.com/ferdikoomen/openapi-typescript-codegen/blob/v0.31.0/src/templates/core/OpenAPI.hbs#L20-L23
- https://github.com/ferdikoomen/openapi-typescript-codegen/blob/v0.31.0/src/templates/exportService.hbs#L89-L110
- GitHub Issue #2809 https://github.com/ferdikoomen/openapi-typescript-codegen/issues/2809
- VulnCheck Advisory: openapi-typescript-codegen through 0.31.0 Code Injection via Handlebars Templates https://www.vulncheck.com/advisories/openapi-typescript-codegen-through-0.31.0-code-injection-via-handlebars-templates
Provider assertions
2VulnCheck · cna
openapi-typescript-codegen through 0.31.0 Code Injection via Handlebars Templates
CISA-ADP · adp
CISA ADP Vulnrichment
Provenance
- Schema
- 5.2
- Searchable
- yes
- Content hash
- 80dc43f3210b61a3a111f75dbb30329bb9fae2c07e35a71212963e86e2f648da
- Ingested
- 13 Oct 2026, 18:30:47 UTC
- Source record
- Official CVE record