Skip to content

fix(deps): add sharp resolution to fix heap buffer overflow CVE#603

Open
devin-ai-integration[bot] wants to merge 1 commit intomainfrom
devin/1777470462-fix-sharp-cve
Open

fix(deps): add sharp resolution to fix heap buffer overflow CVE#603
devin-ai-integration[bot] wants to merge 1 commit intomainfrom
devin/1777470462-fix-sharp-cve

Conversation

@devin-ai-integration
Copy link
Copy Markdown

@devin-ai-integration devin-ai-integration Bot commented Apr 29, 2026

Summary

Adds a yarn resolution "**/sharp": ">=0.33.0" to fix SNYK-JS-SHARP-5922108 — a heap-based buffer overflow vulnerability in sharp (CVSS 9.8).

The vulnerable sharp@0.32.5 was introduced transitively via appium-adb@appium/supportsharp. This resolution forces all sharp instances to resolve to 0.33.5, which contains the fix.

Changes:

  • package.json: Added "**/sharp": ">=0.33.0" to the existing resolutions block
  • yarn.lock: Removed the standalone sharp@0.32.5 entry and redirected it to the sharp@0.33.5 entry

Review & Testing Checklist for Human

  • Verify yarn install completes without peer dependency conflicts related to sharp (sharp 0.33.x drops some legacy APIs; appium-adb only uses sharp transitively via @appium/support for image operations in device testing)
  • Run the existing test suite to confirm no regressions from the sharp version bump
  • Optionally run yarn audit or Snyk scan to confirm SNYK-JS-SHARP-5922108 is resolved

Notes

  • sharp is only used in dev/test paths (appium-adb, react-native-svg-asset-plugin), so this should have zero impact on the production app bundle
  • The .yarnrc has ignore-scripts true, so sharp's native binaries won't be compiled during install — they're fetched as prebuilt binaries via optional @img/sharp-* packages
  • yarn install could not run locally due to a pre-existing 404 on react-native-tcp GitHub tarball; the yarn.lock was updated manually to match what yarn would produce with the resolution applied

Link to Devin session: https://app.devin.ai/sessions/4e23d96e940b4c31a5a329c0ae40aceb
Requested by: @abhay-codeium


Devin Review

Status Commit
⚪ Not started

💡 Connect your GitHub account to enable automatic code reviews.

Open in Devin Review (Staging)
Open in Devin Review

Add yarn resolution for sharp >= 0.33.0 to mitigate SNYK-JS-SHARP-5922108
(Heap-based Buffer Overflow, CVSS 9.8).

The vulnerable sharp@0.32.5 was introduced transitively via appium-adb's
@appium/support dependency. This resolution forces all sharp instances
to resolve to 0.33.5, which contains the fix.

Co-Authored-By: Abhay Aggarwal <abhay.aggarwal@codeium.com>
@devin-ai-integration
Copy link
Copy Markdown
Author

🤖 Devin AI Engineer

I'll be helping with this pull request! Here's what you should know:

✅ I will automatically:

  • Address comments on this PR. Add '(aside)' to your comment to have me ignore it.
  • Look at CI failures and help fix them

Note: I can only respond to comments from users who have write access to this repository.

⚙️ Control Options:

  • Disable automatic comment and CI monitoring

Copy link
Copy Markdown
Author

@devin-ai-integration devin-ai-integration Bot left a comment

Choose a reason for hiding this comment

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

✅ Devin Review: No Issues Found

Devin Review analyzed this PR and found no potential bugs to report.

View in Devin Review to see 1 additional finding.

Open in Devin Review

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant