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.
Security readout for executives and security teams
Plain-English summary
Kiota can turn malicious text in an OpenAPI description into executable code inside a generated client. The main risk arises when teams generate clients from untrusted or tampered API descriptions. Successful abuse could compromise the confidentiality, integrity, and availability of the system where the generated code is built or run.
Executive priority
Prioritize remediation for teams that ingest third-party specifications or automate client generation. Upgrade and regenerate promptly in those environments. Trusted, integrity-protected specifications substantially reduce practical risk, but existing generated clients still warrant review because vulnerable output may persist.
Technical view
Affected Kiota releases fail to apply context-appropriate escaping across multiple code-writer sinks, including serialization keys, parameter mappings, URL metadata, enums, properties, and default values. Crafted OpenAPI values can escape generated string literals and inject source code. The issue is classified as CWE-94 and scored CVSS 4.0 7.3.
Likely exposure
Exposure is highest in development, CI, or supply-chain workflows that generate clients from external, user-supplied, or insufficiently integrity-protected OpenAPI descriptions. Previously generated clients may retain unsafe injected output even after Kiota itself is upgraded, making regeneration and review important.
Exploitation context
Practical exploitation requires an attacker-controlled or compromised OpenAPI description and a user or automated workflow to generate code from it. The supplied record marks this CVE as absent from KEV and provides no evidence of active exploitation. The CVSS vector describes local access, low complexity, a prerequisite condition, and user interaction.
Researcher notes
The vulnerability spans several language-writer output contexts rather than one isolated sink. Assessment should consider both generator versions and the provenance of every input description. The supplied affected ranges are versions below 1.29.1 and versions 1.30.0 through 1.31.0. No exploit activity or additional affected products are established by the bundle.
Mitigation direction
Upgrade Kiota to version 1.29.1, 1.31.1, or later.
Regenerate existing clients with the upgraded Kiota release.
Accept OpenAPI descriptions only from trusted, integrity-protected sources.
Review vendor guidance for any later branch-specific remediation advice.
Validation and detection
Inventory Kiota versions used locally and in CI pipelines.
Identify clients generated from untrusted or potentially modified OpenAPI descriptions.
Confirm OpenAPI provenance and integrity controls across generation workflows.
Regenerate clients and review resulting changes for unexpected executable code.
Verify refreshed clients build and pass established security and regression tests.
Generated from the cited source records. This long-tail analysis has not been individually reviewed by a named human.
Potential ATT&CK relevance
Conservative CVE-to-ATT&CK context
These mappings and lookup hints may be relevant to the vulnerability behavior, CWE, affected product, or exposure path. Glexia-inferred context is not an official MITRE, ATT&CK, CWE, or CVE Program mapping.
ATT&CK lookup starting points
Use these exact CWE pages and searches to review the Glexia ATT&CK library from this CVE's weakness and description context.
cwe · medium confidence lookup
CWE-94: Code execution behavior lookup
Code execution and unsafe deserialization weaknesses often justify reviewing execution behavior and process telemetry. Open the exact CWE lookup page first, then review the ATT&CK searches from that MITRE weakness context. This is a Glexia lookup hint, not an official ATT&CK mapping.
These fields come from the CVE record and ADP containers, not from Glexia's Take. They preserve time-varying source decisions such as CISA SSVC, KEV status, CVSS metrics, and provider references.
1CVSS vectors
3Timeline events
1ADP providers
2Source links
SSVC decision data
CISA-ADPCISA Coordinator
Timestamp
Version
2.0.3
Exploitation: noneAutomatable: noTechnical Impact: total
CVSS vector scores
1 official score
We collect every scored CVSS vector available in the official CNA and ADP containers. When more than one version is present, the table keeps the source vectors side by side instead of collapsing them into the highest score.
CWE links open Glexia weakness intelligence pages with official CWE context, developer remediation guidance, and related CVE mappings.
CWE-94 · source CWE mapping
Improper Control of Generation of Code ('Code Injection')
Improper Control of Generation of Code ('Code Injection') represents a recurring weakness pattern that can create exploitable paths when design, validation, or implementation controls are missing.