Repository navigation
fix: widen aio-lib-ims peer dependency to include v8 - #81
Merged
yeshwanthkai merged 1 commit intoAug 6, 2026
Merged
Conversation
Allows aio-lib-ims-jwt to satisfy its peer dependency against the already-installed aio-lib-ims v8 instead of forcing npm to nest a legacy aio-lib-ims v7 copy. That legacy copy pulls in aio-lib-state@3.x -> @azure/cosmos@3.x -> uuid@8.3.2, which is vulnerable to a buffer bounds check issue in v3/v5/v6 (GHSA-w5hq-g745-h8pq, CVE affects uuid <11.1.1). aio-lib-ims-oauth already declares this same peer range ("^7 || ^8"), and this plugin only receives an ims instance as a parameter, so there is no direct API surface tying it to a specific aio-lib-ims major version.
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
Member
|
@obarcelonap To be clear, This PR is aimed to fix the uuid vulnerability coming from |
Member
Author
|
@yeshwanthkai yes that's correct |
yeshwanthkai
approved these changes
Aug 4, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Widens the
@adobe/aio-lib-imspeer dependency range from^7to^7 || ^8, matching the range@adobe/aio-lib-ims-oauthalready declares.Related Issue
N/A — no existing issue tracked this; opening directly since it's a minimal, low-risk peer-range fix backed by a public advisory (linked below). Happy to file one first if preferred.
Motivation and Context
Because the current peer range only accepts
aio-lib-imsv7, npm cannot resolve this plugin against an already-installedaio-lib-imsv8 and instead nests a legacyaio-lib-imsv7 copy alongside it. That legacy copy depends onaio-lib-state@3.x, which depends on@azure/cosmos@3.x, which depends onuuid@8.3.2— vulnerable to GHSA-w5hq-g745-h8pq ("Missing buffer bounds check in v3/v5/v6 when buf is provided", CVSS 7.5).Widening the peer range lets consumers already on
aio-lib-imsv8 resolve this plugin against that version directly, avoiding the nested legacy chain and the vulnerableuuidversion entirely.How Has This Been Tested?
Ran the existing test suite (
npm test, lint + unit tests) — all pass with 100% coverage.To confirm this widening isn't breaking, I compared the actual interface contract between
aio-lib-imsv7.0.2 and v8.1.2 (installed side by side as a transitive/nested pair, so a direct diff was possible):src/token-helper.js) is byte-for-byte identical between v7.0.2 and v8.1.2 — samerequire('@adobe/aio-lib-ims-jwt'), samecanSupport/supports/imsLogin(ims, config)calling convention this plugin relies on.@adobe/aio-lib-imsitself — it only receives animsinstance as a parameter and calls two methods on it:ims.getApiUrl(api)(increateJwt) andims.exchangeJwtToken(clientId, clientSecret, signedJwtToken)(inimsLogin). Both methods have identical signatures and behavior insrc/ims.jsacross v7.0.2 and v8.1.2.ims.jsin full between the two versions shows the only changes are unrelated to this plugin's usage: JWT payload decoding switched to base64url-safe padding, HTTP error messages now include the response body, and a minor reordering of token validation logic. None of it touchesgetApiUrlorexchangeJwtToken.Types of changes
Checklist