oapi-codegen 2.5.0 before 2.8.1 Code Injection via servers[].x-go-name Extension
Impact
oapi-codegen versions 2.5.0 before 2.8.1 have a code injection vulnerability via the servers[].x-go-name extension, allowing attackers to inject Go code. Attackers must control an OpenAPI document to exploit this weakness. The impact is code execution when the victim builds and imports the generated package.
Summarized by @cf/meta/llama-3.3-70b-instruct-fp8-fast. Verify details against the original sources.Affected packages
Affected products
Vendor version evidence. Product records are separate from automatic dependency matching.
oapi-codegen · VulnCheck
oapi-codegen
1 range
oapi-codegen · VulnCheck
oapi-codegen
Package identity
pkg:golang/github.com/oapi-codegen/oapi-codegen/v2Explore github.com/oapi-codegen/oapi-codegen/v2 →Identity supplied by VulnCheck. Version matching requires compatible range evidence.
Compare with this publisher’s ranges. This does not inspect your installation.
affected
2.5.0 → before 2.8.1
semver versions
Other versions: unaffected
Original source description
oapi-codegen 2.5.0 before 2.8.1 contains a code injection vulnerability that allows attackers to inject Go code by supplying a crafted servers[].x-go-name value emitted unescaped by the server-urls template. Attackers who control an OpenAPI document can define an injected func init() that executes when the victim builds and imports the generated package.
Inside the record
Evidence available
Describes the evidence in this view, not whether the product is safe.
Original records
CVE-2026-119027View the latest unmodified CVE JSON from the official source. It may be newer than this imported page.
cve.new JSON →Underlying weaknesses
The source’s classification of what caused the vulnerability.
Contributing organizations · 2
Assigning organization
Additional data publisher
What changed
Follow changes- CVE · CVE-2026-119027
Observed 2026-10-29T17:51:57.602Z · upstream updated 2026-10-29T17:20:19.252Z
Prioritization updated
before
[]
after
[ { "source": "CISA-ADP", "type": "SSVC", "role": "CISA Coordinator", "timestamp": "2026-10-29T15:37:44.678832Z", "decisions": [ { "name": "Exploitation", "value": "none" }, { "name": "Automatable", "value": "no" }, { "name": "Technical Impact", "value": "total" } ] } ]
Large field values are marked as truncated previews. Original source snapshots remain retained.
Showing up to 50 most recent observed changes.