# CVE-2026-63470: fastapi-code-generator: Call-time RCE via operation summary -> unescaped route-handler docstring

Status: published. Published: 2026-11-03. Updated: 2026-11-03.

fastapi-code-generator creates FastAPI applications from OpenAPI files. Prior to 0.8.1, the generator inserts Operation.summary into a generated route-handler docstring as a triple-double-quoted string without escaping embedded triple quotes. An attacker-controlled or attacker-influenced operation summary can close the docstring and inject a valid Python expression statement into the handler body. Syntax-breaking input only causes generation to fail, but syntactically valid generated code executes with the server process's privileges when the affected route handler is called. This call-time route-handler docstring sink is distinct from the project's separate import-time route-path and additional-response-key sinks. This issue is fixed in version 0.8.1.

## Remediation

No remediation reported in collected sources

## Affected products and versions

- koxudaxi / fastapi-code-generator: < 0.8.1 (affected). Source: CNA: GitHub_M

## Severity and prioritization

- CVSS 4.0: 9.3 (critical); 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; source: CNA: GitHub_M

- CISA KEV: No listing in collected sources

- EPSS: Not available

- SSVC: exploitation poc; automatable yes; technical impact total; source ADP: CISA-ADP

- Weaknesses: CWE-94, CWE-116

## Exploit evidence

- exploit: https://github.com/koxudaxi/fastapi-code-generator/security/advisories/GHSA-h667-4jj2-cgv4 (ADP: CISA-ADP)

## References

- https://github.com/koxudaxi/fastapi-code-generator/security/advisories/GHSA-h667-4jj2-cgv4 (CNA: GitHub_M; x_refsource_CONFIRM)

- https://github.com/koxudaxi/fastapi-code-generator/commit/49301dbdb82170d7f50877419d994b05cb1fa2bc (CNA: GitHub_M; x_refsource_MISC)

- https://github.com/koxudaxi/fastapi-code-generator/commit/b3b9bd66e0b0c4d8c686fda700258104615a1332 (CNA: GitHub_M; x_refsource_MISC)

- https://github.com/koxudaxi/fastapi-code-generator/releases/tag/0.8.1 (CNA: GitHub_M; x_refsource_MISC)

- https://github.com/koxudaxi/fastapi-code-generator/security/advisories/GHSA-h667-4jj2-cgv4 (ADP: CISA-ADP; exploit)

## Provenance

- CNA: GitHub_M: https://www.cve.org/CVERecord?id=CVE-2026-63470; retrieved 2026-11-03; source updated 2026-11-03

Revision: b90d745425a5033fab39f79b926357ee068579f7e911aa34a8534783b4069685

Canonical: https://y2.dev/cve/CVE-2026-63470

## Agent and API access

Public CVE pages, Markdown, and JSON are free to read without an account or API key.

- Public catalog: https://y2.dev/cve/index.json. Follow nextCursor with the same search, filters, sort, and limit (1–100). A null cursor marks the end.

- WebMCP: search_cve_disclosures, get_cve_disclosure, get_cve_page_markdown, get_y2_cve_access. Available in compatible browsers.

- Cyber API: https://api.y2.dev/api/v2/cyber/cves and https://api.y2.dev/api/v2/cyber/cves/{cveId}.

- Y2 Pro or Elite: create a workspace API key with the intel:cyber scope and send Authorization: Bearer <Y2_API_KEY>. Setup: https://y2.dev/docs/api/create-key.

- x402: Pay per request without an account or API key. Omit Authorization, read the HTTP 402 PAYMENT-REQUIRED challenge, validate its current requirements, and retry with PAYMENT-SIGNATURE through an authorized payment client. These browser tools never make payments. Guide: https://y2.dev/docs/api/x402.

- OpenAPI: https://y2.dev/api/openapi.yaml. Agent access metadata: https://y2.dev/cve/agent.json.

Collected public records only. Check source status for coverage and freshness.