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

[Aikido] Fix security issue in undici via major version upgrade from 5.28.4 to 6.15.0 #36

Merged
merged 1 commit into from
Jan 16, 2025

Conversation

aikido-autofix[bot]
Copy link
Contributor

@aikido-autofix aikido-autofix bot commented Jan 16, 2025

This PR will resolve the following CVEs:

CVE ID Severity Description
AIKIDO-2024-10065
MEDIUM
Affected versions of the undici library are vulnerable to memory leaks. By making multiple fetch requests with the same AbortSignal, undici adds event listeners without removing them, leading to excessive memory consumption.

Summary by Sourcery

Bug Fixes:

  • Fix memory leaks when making multiple fetch requests with the same AbortSignal in undici.

Copy link

sourcery-ai bot commented Jan 16, 2025

Reviewer's Guide by Sourcery

This pull request upgrades the undici package from version 5.28.4 to 6.15.0 to address a memory leak vulnerability. The upgrade is performed by modifying the package.json and package-lock.json files.

Sequence diagram showing memory leak issue with undici fetch requests

sequenceDiagram
    participant C as Client
    participant U as Undici (v5.28.4)
    participant AS as AbortSignal
    Note over U: Memory leak vulnerability
    C->>U: fetch request 1 with AbortSignal
    U->>AS: Add event listener
    C->>U: fetch request 2 with same AbortSignal
    U->>AS: Add event listener (not removed)
    C->>U: fetch request N with same AbortSignal
    U->>AS: Add event listener (not removed)
    Note over AS: Event listeners accumulate<br/>causing memory leak
Loading

File-Level Changes

Change Details Files
Upgrade undici package
  • Updated the undici dependency version in package.json.
  • Added an override for undici to version 6.15.0 in package.json.
  • Updated the package-lock.json file to reflect the changes in package.json.
package.json
package-lock.json

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time. You can also use
    this command to specify where the summary should be inserted.

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

Copy link

@sourcery-ai sourcery-ai bot left a comment

Choose a reason for hiding this comment

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

We have skipped reviewing this pull request. It seems to have been created by a bot (hey, aikido-autofix[bot]!). We assume it knows what it's doing!

@roderik roderik merged commit d4e7ac4 into main Jan 16, 2025
4 of 5 checks passed
@roderik roderik deleted the fix/aikido-security-update-packages-2604910-u4AS branch January 16, 2025 09:09
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.

1 participant