{"description":"Trending threats, MITRE ATT\u0026CK coverage, and detection metadata. Fed continuously.","feed_url":"https://feed.craftedsignal.io/tags/software-development/feed.json","home_page_url":"https://feed.craftedsignal.io/","items":[{"_cs_actors":[],"_cs_cpes":[],"_cs_cves":[],"_cs_exploited":false,"_cs_has_poc":false,"_cs_poc_references":[],"_cs_products":["swagger-typescript-api (\u003c= 13.12.1)"],"_cs_severities":["high"],"_cs_tags":["credential-theft","supply-chain","software-development","openapi","api-security","nodejs","code-injection","npm","node.js","code-generation"],"_cs_type":"advisory","_cs_vendors":[],"content_html":"\u003cp\u003eThe \u003ccode\u003eswagger-typescript-api\u003c/code\u003e tool, specifically versions up to and including 13.12.1, is vulnerable to authorization token exfiltration (CVE-2026-54660). This vulnerability arises when the tool is used to generate API clients from an OpenAPI specification, and a developer provides an \u003ccode\u003e--authorizationToken\u003c/code\u003e flag to authenticate against a private spec. The tool's \u003ccode\u003egetRemoteRequestHeaders()\u003c/code\u003e function unconditionally attaches this token to the \u003ccode\u003eAuthorization\u003c/code\u003e header of \u003cem\u003eevery\u003c/em\u003e subsequent HTTP request made while resolving external \u003ccode\u003e$ref\u003c/code\u003e URLs within the specification. Crucially, it fails to perform a same-origin check, host allowlist, or scope-down, meaning that a maliciously crafted OpenAPI spec with an external \u003ccode\u003e$ref\u003c/code\u003e pointing to an attacker-controlled domain will cause the developer's sensitive token (such as a GitHub Personal Access Token, OAuth bearer token, or API key) to be sent verbatim to the attacker. This flaw poses a significant risk to development environments, CI/CD pipelines, and multi-tenant SaaS platforms, as the captured token grants attackers the same level of access as the legitimate developer.\u003c/p\u003e\n\u003ch2 id=\"attack-chain\"\u003eAttack Chain\u003c/h2\u003e\n\u003col\u003e\n\u003cli\u003eAn attacker crafts a malicious OpenAPI specification containing an external \u003ccode\u003e$ref\u003c/code\u003e pointing to an attacker-controlled URL (e.g., \u003ccode\u003ehttp://attacker.example/exfil-endpoint/data.json\u003c/code\u003e).\u003c/li\u003e\n\u003cli\u003eThe attacker delivers this malicious spec to a developer or injects it into a trusted spec (e.g., via a compromised repository or supply chain attack).\u003c/li\u003e\n\u003cli\u003eA developer or automated CI/CD pipeline executes \u003ccode\u003eswagger-typescript-api generate\u003c/code\u003e against the malicious or compromised OpenAPI specification, supplying a sensitive authorization token via the \u003ccode\u003e--authorizationToken\u003c/code\u003e flag.\u003c/li\u003e\n\u003cli\u003eDuring the code generation process, \u003ccode\u003eswagger-typescript-api\u003c/code\u003e attempts to resolve the external \u003ccode\u003e$ref\u003c/code\u003e URLs defined within the spec.\u003c/li\u003e\n\u003cli\u003eThe vulnerable \u003ccode\u003eswagger-typescript-api\u003c/code\u003e component \u003ccode\u003egetRemoteRequestHeaders()\u003c/code\u003e attaches the developer's full \u003ccode\u003e--authorizationToken\u003c/code\u003e value to the HTTP request without performing a same-origin check.\u003c/li\u003e\n\u003cli\u003e\u003ccode\u003eswagger-typescript-api\u003c/code\u003e makes an outbound HTTP GET request to the attacker-controlled URL, including the sensitive token in the \u003ccode\u003eAuthorization\u003c/code\u003e header.\u003c/li\u003e\n\u003cli\u003eThe attacker's server receives the request and captures the exposed authorization token.\u003c/li\u003e\n\u003cli\u003eThe attacker can then use the stolen token to gain unauthorized access to the services or resources associated with the token's scope, mimicking the developer's privileges.\u003c/li\u003e\n\u003c/ol\u003e\n\u003ch2 id=\"impact\"\u003eImpact\u003c/h2\u003e\n\u003cp\u003eThe vulnerability, identified as CVE-2026-54660, directly leads to the exposure of sensitive credentials, typically high-value authorization tokens. The impact is significant, as the stolen token grants attackers the same scope of access as the developer or system it was stolen from. This could include full source-code read/write access via a GitHub Personal Access Token, full impersonation on an API via an OAuth bearer token, or extensive account access through an AWS-style API key, depending on the token's privileges. Affected use cases include developers fetching private OpenAPI specs, CI/CD pipelines regenerating clients from private specs, and multi-tenant SaaS platforms that generate per-tenant clients. The credential theft occurs at generation time, meaning the risk is realized as soon as \u003ccode\u003eswagger-typescript-api generate\u003c/code\u003e is run with a malicious spec and an authorization token.\u003c/p\u003e\n\u003ch2 id=\"recommendation\"\u003eRecommendation\u003c/h2\u003e\n\u003cul\u003e\n\u003cli\u003ePatch CVE-2026-54660 by upgrading \u003ccode\u003eswagger-typescript-api\u003c/code\u003e to a version greater than 13.12.1 as soon as a fix is released by the maintainers.\u003c/li\u003e\n\u003cli\u003eImplement robust network egress filtering for systems running \u003ccode\u003eswagger-typescript-api\u003c/code\u003e to prevent outbound connections to untrusted external URLs, particularly on non-standard ports.\u003c/li\u003e\n\u003cli\u003eReview and restrict the scope and lifetime of \u003ccode\u003e--authorizationToken\u003c/code\u003es used with \u003ccode\u003eswagger-typescript-api\u003c/code\u003e, adhering to the principle of least privilege.\u003c/li\u003e\n\u003cli\u003eRun \u003ccode\u003eswagger-typescript-api\u003c/code\u003e in isolated environments (e.g., containers, ephemeral build agents) with minimal network access and permissions, similar to the SSRF mitigations suggested in the companion advisory.\u003c/li\u003e\n\u003c/ul\u003e\n","date_modified":"2026-07-29T14:33:31Z","date_published":"2026-07-29T14:24:07Z","id":"https://feed.craftedsignal.io/briefs/2026-07-swagger-typescript-api-token-exfil/","summary":"The `swagger-typescript-api` tool is vulnerable to authorization token exfiltration. When a developer provides an `--authorizationToken` to fetch an OpenAPI specification, the tool attaches this token to all subsequent HTTP requests made while resolving external `$ref` URLs within the spec. Critically, it lacks same-origin checks, allowing a malicious OpenAPI spec containing a `$ref` to an attacker-controlled URL to cause the authorization token (e.g., GitHub PAT, OAuth bearer) to be sent verbatim to the attacker. This credential disclosure provides an attacker with the same scope of access as the stolen token, affecting development environments, CI/CD pipelines, and multi-tenant SaaS platforms.","title":"Swagger-typescript-api Vulnerable to Authorization Token Exfiltration via Spec $ref","url":"https://feed.craftedsignal.io/briefs/2026-07-swagger-typescript-api-token-exfil/"}],"language":"en","title":"CraftedSignal Threat Feed - Software-Development","version":"https://jsonfeed.org/version/1.1"}