CVE-2026-59862 json
Kiota: Code Generation Literal Injection in the Python Generator
published 2026-07-16 3 mo ago modified 2026-10-24 15 d ago also GHSA-7f3j-j7jj-r3vr , EUVD-2026-44927
- cvss
- 7.5
- version 3.1, CNA
- cisa kev
- Not listed
- not in CISA's catalog
- epss
- 1.4%
- EPSS 1.4% chance of exploitation in 30 days, percentile 72%
- public exploits
- 0
- none known
Summary
Kiota is an OpenAPI based HTTP Client code generator. Prior to 1.29.1 and 1.32.0, Kiota's Python generator let attacker-controlled enum value descriptions from x-ms-enum.values[].description flow through KiotaBuilder.SetEnumOptions into Documentation.DescriptionTemplate and PythonConventionService.RemoveInvalidDescriptionCharacters without newline sanitization, allowing generated inline comments to split and execute attacker-controlled Python code at module scope when generated modules were imported. This issue is fixed in version 1.29.1 and 1.32.0.
Patch / fix
- nuget Microsoft.OpenAPI.Kiota 1.32.0
- nuget Microsoft.OpenAPI.Kiota.Builder 1.32.0
- nuget Microsoft.OpenApi.Kiota 1.29.1
- nuget Microsoft.OpenApi.Kiota.Builder 1.29.1
CISA SSVC
- Exploitation
- none
- Automatable
- yes
- Technical impact
- total
- Assessed
- 3 mo ago
Exploit prediction
1.38% chance of exploitation in the next 30 days, higher than 72% of all scored CVEs (FIRST EPSS, 2026-11-08).
CVSS scores
| assigned by | version | score | vector |
|---|---|---|---|
| CNA | 3.1 | 7.5 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H |
| GitHub | 3.1 | 7.5 | CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H |
Affected packages
| ecosystem | package | affected | fixed in |
|---|---|---|---|
| nuget | Microsoft.OpenAPI.Kiota | >=1.30.0, <1.32.0 |
1.32.0 |
| nuget | Microsoft.OpenAPI.Kiota.Builder | >=1.30.0, <1.32.0 |
1.32.0 |
| nuget | Microsoft.OpenApi.Kiota | <1.29.1 |
1.29.1 |
| nuget | Microsoft.OpenApi.Kiota.Builder | <1.29.1 |
1.29.1 |
Affected products
- microsoft kiota
Classification
- Weakness
-
- CWE-94 Improper Control of Generation of Code
References
Sources
- CVE List CVE-2026-59862
- GitHub Advisory GHSA-7f3j-j7jj-r3vr
- NVD CVE-2026-59862
Fencer Vulns keeps one entry per vulnerability: the CVE id wins, then GHSA, and records that alias each other are merged, except that two CVEs always keep separate entries. The same data is available as JSON.