CVE-2026-41134
Description
Kiota is an OpenAPI based HTTP Client code generator. Versions prior to 1.29.1 and 1.31.1 are affected by a code-generation literal injection vulnerability in multiple writer sinks (for example: serialization/deserialization keys, path/query parameter mappings, URL template metadata, enum/property metadata, and default value emission). When malicious values from an OpenAPI description are emitted into generated source without context-appropriate escaping, an attacker can break out of string literals and inject additional code into generated clients. This issue is only practically exploitable when the OpenAPI description used for generation is from an untrusted source, or a normally trusted OpenAPI description has been compromised/tampered with. Only generating from trusted, integrity-protected API descriptions significantly reduces the risk. To remediate the issue, upgrade Kiota to 1.29.1, 1.31.1, or later and regenerate/refresh existing generated clients as a precaution. Refreshing generated clients ensures previously generated vulnerable code is replaced with hardened output.
Weakness
- CWE-94: Improper Control of Generation of Code
CISA SSVC decision points
| Exploitation | none |
|---|---|
| Automatable | no |
| Technical impact | total |
| Scored | 2026-04-25 |
Timeline
- 2026-04-14GitHub advisory published (GHSA-2hx3-vp6r-mg3f)8 days before publication
- 2026-04-22Published by the CNA20:20 UTC
- 2026-04-25CISA SSVC decision recorded3 days after publication
Exploit and advisory records
GitHub advisory GHSA-2hx3-vp6r-mg3f, affected packages:
| Package | Vulnerable versions | Fixed in |
|---|---|---|
| NuGet Microsoft.OpenApi.Kiota | before 1.29.1 | 1.29.1 |
| NuGet Microsoft.OpenApi.Kiota | from 1.30.0 before 1.31.1 | 1.31.1 |
| NuGet Microsoft.OpenApi.Kiota.Builder | before 1.29.1 | 1.29.1 |
| NuGet Microsoft.OpenApi.Kiota.Builder | from 1.30.0 before 1.31.1 | 1.31.1 |
Affected products
Products listed as vulnerable. Upgrade to the version under "Fixed in", or a later one.
| Product | Vulnerable versions | Fixed in |
|---|---|---|
| microsoft kiota | before 1.31.1fixed in 1.31.1 | 1.31.1 |
References
Get more CVE data from the API.
curl 'https://api.contrastcyber.com/cve_lookup/CVE-2026-41134'curl 'https://api.contrastcyber.com/cve_risk_score/CVE-2026-41134'curl 'https://api.contrastcyber.com/cve_exploit/CVE-2026-41134'curl 'https://api.contrastcyber.com/cve_products/CVE-2026-41134'
Sources
- Vulnerability data from the National Vulnerability Database (NIST) and the CVE Program. CVE records: Copyright © 1999-2026, The MITRE Corporation, used under the CVE Program Terms of Use. CVE® is a registered trademark of The MITRE Corporation.
- CWE definitions: Copyright © 2006-2026, The MITRE Corporation, used under the CWE Terms of Use. CWE is a trademark of The MITRE Corporation.
- OWASP Top 10 categories by the OWASP Foundation (CC BY 3.0).
- EPSS scores by FIRST.org EPSS, used with attribution.
- KEV catalog and SSVC decisions by CISA.
- Advisory data from the GitHub Advisory Database through OSV.dev (CC BY 4.0).
- Exploit metadata from the Exploit Database (GPL-2.0-only, metadata only).
- Nuclei template names from nuclei-templates (MIT).