Security Vulnerability fix for snappy-0.2(CVE-2024-36124)#24159
Security Vulnerability fix for snappy-0.2(CVE-2024-36124)#24159namya28 wants to merge 1 commit intoprestodb:masterfrom
Conversation
|
|
5d227f4 to
5034f5a
Compare
presto-hive/pom.xml
Outdated
| <exclusion> | ||
| <groupId>org.iq80.snappy</groupId> | ||
| <artifactId>snappy</artifactId> | ||
| </exclusion> |
There was a problem hiding this comment.
There was an upper bound dependencies error for org.iq80.snappy:snappy:0.2 from this module(Attaching below for reference) :
+-com.facebook.presto:presto-hive:0.291-SNAPSHOT
+-com.facebook.hive:hive-dwrf:0.8.5
+-org.iq80.snappy:snappy:0.2
and
+-com.facebook.presto:presto-hive:0.291-SNAPSHOT
+-com.facebook.presto:presto-hive-metastore:0.291-SNAPSHOT
+-org.iq80.snappy:snappy:0.5
and
+-com.facebook.presto:presto-hive:0.291-SNAPSHOT
+-com.facebook.presto:presto-hive-metastore:0.291-SNAPSHOT
+-org.iq80.snappy:snappy:0.5
presto-hive-hadoop2/pom.xml
Outdated
| <artifactId>snappy</artifactId> | ||
| <version>0.5</version> | ||
| </dependency> | ||
|
|
There was a problem hiding this comment.
Instead of bringing in this dependency, have you tried adding this upgrade to the root pom dependency management?
There was a problem hiding this comment.
This was a transitive dependency coming from this module. I will try adding in the root pom as well. Thanks for the suggestion.
|
Could you please squash the commits and modify the commit message to follow the guidelines? The release note should also contain the CVE as per the guidelines |
presto-hive-metastore/pom.xml
Outdated
| <artifactId>snappy</artifactId> | ||
| <version>0.5</version> | ||
| </dependency> | ||
|
|
There was a problem hiding this comment.
Could we also get this in the root pom?
This upgrade eliminates the vulnerability present in the version 0.2 which fixes CVE-2024-36124.
26b240f to
f6e2e60
Compare
|
Hi @infvg , thank you for your suggestions and comments. I have addressed all the review comments. Could you please re-review the PR once again. |
|
|
||
| <dependencyManagement> | ||
| <dependencies> | ||
| <dependency> |
There was a problem hiding this comment.
What is ultimately bringing in and using this dependency?
There was a problem hiding this comment.
@tdcmeehan The version earlier used was 0.2 which was present transitively across modules , causing the vulnerability. By bringing in this dependency and the version 0.5 fixes the vulnerability as 0.5 is the vulnerable free version for this library.
There was a problem hiding this comment.
Right, but my question is what is using it?
There was a problem hiding this comment.
Should we update hive-dwrf instead of overriding it at the top level here?
There was a problem hiding this comment.
@tdcmeehan , introducing the latest version of hive-dwrf introduces a lot of vulnerabilities. (https://mvnrepository.com/artifact/com.facebook.hive/hive-dwrf/0.18.9). (Attaching the screenshot from the maven repository). Although even if we try upgrading hive-dwrf, it does not resolve the vulnerability directly as it still introduces the 0.2 version of snappy transitively.

There was a problem hiding this comment.
@tdcmeehan , could you please have a look at the comments and re-review if possible?
There was a problem hiding this comment.
What I mean is, simply fix the vulnerabilities in hive-dwrf, cut a release, then update here. https://github.com/prestodb/presto-hive-dwrf
|
Closing this PR as this CVE was fixed by upgrading the snappy version in the new hive-dwrf release. |

Description
This PR is fixing the security vulnerability for the library "snappy-0.2" (CVE-2024-36124) https://mvnrepository.com/artifact/org.iq80.snappy/snappy/0.2. The library has been upgraded to the version 0.5 (https://mvnrepository.com/artifact/org.iq80.snappy/snappy/0.5). This fixes CVE-2024-36124.
Motivation and Context
The snappy library currently used has a security vulnerability for the version 0.2. This PR focuses on upgrading the version to 0.5 to fix the current vulnerability.
Impact
Test Plan
Contributor checklist
Release Notes
Please follow release notes guidelines and fill in the release notes below.