Advisory Database
  • Advisories
  • Dependency Scanning
  1. npm
  2. ›
  3. swagger-typescript-api
  4. ›
  5. CVE-2026-54660

CVE-2026-54660: swagger-typescript-api vulnerable to authorization-token exfiltration via spec `$ref`

July 29, 2026

When the developer supplies an --authorizationToken (commonly required to fetch a private spec behind authentication), swagger-typescript-api attaches that token to the Authorization header of every subsequent HTTP request it makes while resolving external $ref URLs in the spec — with no same-origin check, no host allowlist, and no scope-down for cross-origin requests. A malicious OpenAPI spec containing a $ref to an attacker-controlled URL therefore causes the developer’s bearer token to be sent verbatim to that URL during code generation.

The threat model is identical to the SSRF advisory filed alongside this one (companion finding), but with credential disclosure as the primary impact. The token is typically a high-value secret: a GitHub PAT, an OAuth bearer for the API the spec describes, an enterprise SSO token, an AWS-style API key, or similar. Disclosure to an attacker-controlled URL is one curl-equivalent away from full takeover of whatever scope the token grants.

References

  • github.com/acacode/swagger-typescript-api/commit/306d59acb8ffbb00f953f807b97234b21f51d9de
  • github.com/acacode/swagger-typescript-api/pull/1779
  • github.com/acacode/swagger-typescript-api/releases/tag/v13.12.2
  • github.com/acacode/swagger-typescript-api/security/advisories/GHSA-h754-fxp7-88wx
  • github.com/advisories/GHSA-h754-fxp7-88wx
  • nvd.nist.gov/vuln/detail/CVE-2026-54660

Code Behaviors & Features

Detect and mitigate CVE-2026-54660 with GitLab Dependency Scanning

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Learn more about Dependency Scanning →

Affected versions

All versions before 13.12.2

Fixed versions

  • 13.12.2

Solution

Upgrade to version 13.12.2 or above.

Impact 7.4 HIGH

CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:H/I:N/A:N

Learn more about CVSS

Weakness

  • CWE-200: Exposure of Sensitive Information to an Unauthorized Actor
  • CWE-201: Insertion of Sensitive Information Into Sent Data
  • CWE-522: Insufficiently Protected Credentials
  • CWE-918: Server-Side Request Forgery (SSRF)

Source file

npm/swagger-typescript-api/CVE-2026-54660.yml

Spotted a mistake? Edit the file on GitLab.

  • Site Repo
  • About GitLab
  • Terms
  • Privacy Statement
  • Contact

Page generated Sat, 08 Aug 2026 00:17:33 +0000.