Deserialization of Untrusted Data in swagger-parser
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| io.swagger:swagger-codegen Maven |
|
|
| io.swagger:swagger-parser Maven |
|
|
| Product | Affected | Fixed in |
|---|---|---|
| io.swagger:swagger-codegen Maven |
|
|
| io.swagger:swagger-parser Maven |
|
|
A vulnerability in Swagger-Parser's (version <= 1.0.30) yaml parsing functionality results in arbitrary code being executed when a maliciously crafted yaml Open-API specification is parsed. This in particular, affects the 'generate' and 'validate' command in swagger-codegen (<= 2.2.2) and can lead to arbitrary code being executed when these commands are used on a well-crafted yaml specification.
From the CVE record · mitre
Swagger-Parser can execute arbitrary code when it parses a maliciously crafted YAML OpenAPI specification. This also affects swagger-codegen's generate and validate commands when they process such a specification; exploitation requires the specification to be parsed.
Engineers using Maven io.swagger:swagger-parser versions before 1.0.31 or io.swagger:swagger-codegen versions before 2.2.2 should check their dependencies.