CVE-2026-119028

    Dashboard / Vulnerabilities / CVE-2026-119028

    CVE-2026-119028

    Published: 29 Oct 2026Last Modified: 31 Oct 2026

    Summary: oapi-codegen 2.0.0 before 2.8.1 Code Injection via Non-String Enum Values

    Details: oapi-codegen 2.0.0 before 2.8.1 contains a code injection vulnerability that allows attackers to inject Go code by supplying non-literal enum entries in integer, number, or boolean schemas. Attackers controlling an OpenAPI document can craft an enum entry that closes the const block in constants.tmpl and injects a func init(), executing code when the generated package is built and imported.

    Affected packages

    Package

    Name:

    Purl:

    Affected ranges

    Type: GIT

    Events:

    Introduced- ba76f6c927e11747fc4d9547d18b0c0b14a80658

    Affected versions

    v2.8.0

    Common Vulnerability Scoring System

    Attack Vector
    Network
    Adjacent
    Local
    Physical
    Privileges Required
    None
    Low
    High
    User Interaction
    None
    Required
    Scope
    Unchanged
    Changed
    Confidentiality
    None
    Low
    High
    Integrity
    None
    Low
    High
    Availability
    None
    Low
    High
    CVE-2026-119028 | CVE-DB