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-2024-53990 - Upgrading async-http-client to 3.0.1 #24313

Open
wants to merge 7 commits into
base: master
Choose a base branch
from

Conversation

jshah11
Copy link

@jshah11 jshah11 commented Jan 2, 2025

Description

This change removed the current library from transitive dependency to the main dependency to ensure we address the security issues.

Motivation and Context

The AsyncHttpClient (AHC) library allows Java applications to execute HTTP requests and asynchronously process HTTP responses easily. When making any HTTP request, the automatically enabled and self-managed CookieStore (aka cookie jar) will silently replace explicitly defined Cookies with any that have the same name from the cookie jar. For services with multiple users, this can result in one user's Cookie being used for another user's requests.
Issue Details: #24299

Impact

N/A

Test Plan

CI/CD

Contributor checklist

  • Please make sure your submission complies with our contributing guide, in particular code style and commit standards.
  • PR description addresses the issue accurately and concisely. If the change is non-trivial, a GitHub Issue is referenced.
  • Documented new properties (with its default value), SQL syntax, functions, or other functionality.
  • If release notes are required, they follow the release notes guidelines.
  • Adequate tests were added if applicable.
  • CI passed.

Release Notes

Please follow release notes guidelines and fill in the release notes below.

== RELEASE NOTES ==

Async Http Client library version upgrade
* Upgrade async-http-client library to 3.0.1 in response to `CVE-2024-53990 <https://www.cve.org/CVERecord?id=CVE-2024-53990>`_. :pr:`24313`

@jshah11 jshah11 requested a review from a team as a code owner January 2, 2025 01:04
@jshah11 jshah11 requested a review from presto-oss January 2, 2025 01:04
Copy link

linux-foundation-easycla bot commented Jan 2, 2025

CLA Signed

The committers listed above are authorized under a signed CLA.

@jshah11 jshah11 changed the title Removing the async-http-client library to main library to solve the i… Removing the async-http-client library dependency to main library Jan 4, 2025
@jshah11 jshah11 changed the title Removing the async-http-client library dependency to main library Using the latest async-http-client library dependency Jan 4, 2025
@jshah11 jshah11 changed the title Using the latest async-http-client library dependency CVE-2024-53990 - Upgrading async-http-client to 3.0.1 Jan 6, 2025
@@ -1679,6 +1679,10 @@
<groupId>org.roaringbitmap</groupId>
<artifactId>RoaringBitmap</artifactId>
</exclusion>
<exclusion>
Copy link
Member

Choose a reason for hiding this comment

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

Is this the only transitive dependency for async-http-client?

Copy link
Author

Choose a reason for hiding this comment

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

There was one more. I didn't realize the library was moved to a different group name. Removed that library as well

Copy link
Author

Choose a reason for hiding this comment

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

I checked this by running the dependency:tree command.

Copy link
Member

@imjalpreet imjalpreet left a comment

Choose a reason for hiding this comment

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

Thanks for the fix, please provide the dependency tree both before and after the change for review.

@jshah11
Copy link
Author

jshah11 commented Jan 6, 2025

@jshah11 jshah11 requested a review from imjalpreet January 6, 2025 11:58
@infvg
Copy link
Contributor

infvg commented Jan 6, 2025

I have a few concerns.

  1. The exclusions means that async-http-client is never truly upgraded - it's not brought in at all anymore.
  2. async-http-client version 3.0.1 requires java 11 so a true upgrade is not possible at this time.
Screenshot 2025-01-06 at 3 45 27 PM
  1. airlift resolver uses the com.ning version which has a different package within the code. In certain situations where the async module is used, this might cause issues. I've created a PR for resolver to rework the project so a switch will need to use this reworked resolver. Reworked to use maven resolver resolver#2
  2. Upgrading the dependency in druid-processing requires a couple of minor changes & hopefully it will be included in the latest druid-processing version soon. Bump async-http-client to 3.0.1 apache/druid#17558

@steveburnett
Copy link
Contributor

Suggest revising the release note to follow the Release Notes Guidelines.

== RELEASE NOTES ==

Security Changes 
* Upgrade async-http-client library to 3.0.1 in response to `CVE-2024-53990
 <https://www.cve.org/CVERecord?id=CVE-2024-53990>`_. :pr:`24313`

@jshah11
Copy link
Author

jshah11 commented Jan 9, 2025

@infvg , thanks for the feedback. Few questions:

  1. For point 2, why do you say a true upgrade is not possible at this time? I understand we might need to bump the library version for which you have the PR out, is it just because of that or are there other reasons too?
  2. For point 5, do we need to bump the version in the druid repo? If so, what was the motivation behind that?
  3. Once both the diffs out there are landed, can I bump those versions and those upgrades to the right async library?

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.

4 participants