CVE-2017-1000207: Deserialization of Untrusted Data in swagger-codegen
8.8
CVSS Score
3.0
Basic Information
CVE ID
GHSA ID
EPSS Score
0.61323%
CWE
Published
10/19/2018
Updated
1/9/2023
KEV Status
No
Technology
Java
Technical Details
CVSS Vector
CVSS:3.0/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
Package Name | Ecosystem | Vulnerable Versions | First Patched Version |
---|---|---|---|
io.swagger:swagger-parser | maven | < 1.0.31 | 1.0.31 |
io.swagger:swagger-codegen | maven | < 2.2.2 | 2.2.2 |
Vulnerability Intelligence
Miggo AI
Root Cause Analysis
The vulnerability stems from unsafe YAML deserialization using SnakeYAML
's default Constructor in swagger-parser
. The LGTM blog analysis explicitly identifies this pattern as the root cause (CVE-2017-1000207), and the fix in swagger-parser
PR #481 involved modifying YAML parsing to use a restricted constructor. While swagger-codegen
's 'generate'/'validate
' commands trigger the vulnerability, the actual vulnerable implementation resides in the YAML parsing logic of swagger-parser
. The YamlParser.parse
method is the direct entry point for this unsafe deserialization.