Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CVE-2022-25857/CVE-2022-38752: bump snake-yaml dependency to avoid versions with public CVEs #1790

Merged
merged 2 commits into from
Sep 17, 2022

Conversation

k-wall
Copy link
Contributor

@k-wall k-wall commented Sep 6, 2022

The package org.yaml:snakeyaml from 0 and before 1.31 are vulnerable to Denial of Service (DoS) due missing to nested depth limitation for collections.

… are vulnerable to Denial of Service (DoS) due missing to nested depth limitation for collections.
@k-wall k-wall changed the title CVE-2022-25857: … CVE-2022-25857: bump snake-yaml dependency to avoid version with public CVE Sep 6, 2022
…vulnerable to Denial of Service attacks (DOS). If the parser is running on user supplied input, an attacker may supply content that causes the parser to crash by stack-overflow.
@k-wall k-wall changed the title CVE-2022-25857: bump snake-yaml dependency to avoid version with public CVE CVE-2022-25857/CVE-2022-38752: bump snake-yaml dependency to avoid versions with public CVEs Sep 17, 2022
@frantuma frantuma merged commit eafe156 into swagger-api:master Sep 17, 2022
@k-wall k-wall deleted the CVE-2022-25857 branch September 20, 2022 10:42
@@ -402,7 +402,7 @@
</repository>
</repositories>
<properties>
<snakeyaml-version>1.30</snakeyaml-version>
<snakeyaml-version>1.32</snakeyaml-version>

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This version is only used in dependency management section of this pom and the dependency itself (org.yaml:snakeyaml) is not pulled in anywhere. So it is not bumped when you pull in swagger-parser libs, transitively still the 1.30 version coming.

org.example:untitled:jar:1.0-SNAPSHOT
\- io.swagger.parser.v3:swagger-parser:jar:2.1.3:compile
   +- io.swagger.parser.v3:swagger-parser-v2-converter:jar:2.1.3:compile
   |  +- io.swagger:swagger-core:jar:1.6.7:compile
   |  |  +- org.apache.commons:commons-lang3:jar:3.2.1:compile
   |  |  +- org.slf4j:slf4j-api:jar:1.7.22:compile
   |  |  +- io.swagger:swagger-models:jar:1.6.7:compile
   |  |  |  \- io.swagger:swagger-annotations:jar:1.6.7:compile
   |  |  +- com.google.guava:guava:jar:31.0.1-android:compile
   |  |  |  +- com.google.guava:failureaccess:jar:1.0.1:compile
   |  |  |  +- com.google.guava:listenablefuture:jar:9999.0-empty-to-avoid-conflict-with-guava:compile
   |  |  |  +- com.google.code.findbugs:jsr305:jar:3.0.2:compile
   |  |  |  +- org.checkerframework:checker-qual:jar:3.12.0:compile
   |  |  |  +- org.checkerframework:checker-compat-qual:jar:2.5.5:compile
   |  |  |  +- com.google.errorprone:error_prone_annotations:jar:2.7.1:compile
   |  |  |  \- com.google.j2objc:j2objc-annotations:jar:1.3:compile
   |  |  \- javax.validation:validation-api:jar:1.1.0.Final:compile
   |  +- io.swagger:swagger-parser:jar:1.0.62:compile
   |  +- io.swagger:swagger-compat-spec-parser:jar:1.0.62:compile
   |  |  +- com.github.java-json-tools:json-schema-validator:jar:2.2.14:compile
   |  |  |  +- com.github.java-json-tools:jackson-coreutils-equivalence:jar:1.0:compile
   |  |  |  +- com.github.java-json-tools:json-schema-core:jar:1.2.14:compile
   |  |  |  |  +- com.github.java-json-tools:uri-template:jar:0.10:compile
   |  |  |  |  \- org.mozilla:rhino:jar:1.7.7.2:compile
   |  |  |  +- com.sun.mail:mailapi:jar:1.6.2:compile
   |  |  |  +- joda-time:joda-time:jar:2.10.5:compile
   |  |  |  +- com.googlecode.libphonenumber:libphonenumber:jar:8.11.1:compile
   |  |  |  \- net.sf.jopt-simple:jopt-simple:jar:5.0.4:compile
   |  |  +- com.github.java-json-tools:json-patch:jar:1.13:compile
   |  |  |  +- com.github.java-json-tools:msg-simple:jar:1.2:compile
   |  |  |  |  \- com.github.java-json-tools:btf:jar:1.3:compile
   |  |  |  \- com.github.java-json-tools:jackson-coreutils:jar:2.0:compile
   |  |  \- org.apache.httpcomponents:httpclient:jar:4.5.13:compile
   |  |     +- org.apache.httpcomponents:httpcore:jar:4.4.13:compile
   |  |     +- commons-logging:commons-logging:jar:1.2:compile
   |  |     \- commons-codec:commons-codec:jar:1.11:compile
   |  +- io.swagger.core.v3:swagger-models:jar:2.2.3:compile
   |  \- io.swagger.parser.v3:swagger-parser-core:jar:2.1.3:compile
   +- io.swagger.parser.v3:swagger-parser-v3:jar:2.1.3:compile
   |  +- io.swagger.core.v3:swagger-core:jar:2.2.3:compile
   |  |  +- jakarta.xml.bind:jakarta.xml.bind-api:jar:2.3.2:compile
   |  |  |  \- jakarta.activation:jakarta.activation-api:jar:1.2.1:compile
   |  |  +- com.fasterxml.jackson.datatype:jackson-datatype-jsr310:jar:2.13.3:compile
   |  |  +- io.swagger.core.v3:swagger-annotations:jar:2.2.3:compile
   |  |  \- jakarta.validation:jakarta.validation-api:jar:2.0.2:compile
   |  +- com.fasterxml.jackson.core:jackson-annotations:jar:2.13.2:compile
   |  +- com.fasterxml.jackson.core:jackson-databind:jar:2.13.2.2:compile
   |  |  \- com.fasterxml.jackson.core:jackson-core:jar:2.13.2:compile
   |  \- com.fasterxml.jackson.dataformat:jackson-dataformat-yaml:jar:2.13.2:compile
   |     \- org.yaml:snakeyaml:jar:1.30:compile
   \- commons-io:commons-io:jar:2.11.0:compile

In order to truly override, you'd need to add it as direct dependency to modules where transitively is coming (and maybe excluding from the lib where it's coming from)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants