Skip to content

chore: set yarn npmMinimalAgeGate#2022

Merged
kodiakhq[bot] merged 4 commits into
mainfrom
brandon/set-yarn-min-version
Mar 31, 2026
Merged

chore: set yarn npmMinimalAgeGate#2022
kodiakhq[bot] merged 4 commits into
mainfrom
brandon/set-yarn-min-version

Conversation

@brandon-pereira
Copy link
Copy Markdown
Member

Summary

In response to the recent axios supply chain attack, we are tightening package management controls to reduce our exposure to malicious or compromised npm packages.

Changes:

  • Updated yarnPath in .yarnrc.yml to point to Yarn 4.13.0
  • Updated packageManager in package.json to reflect Yarn 4.13.0
  • Removed old Yarn releases (4.5.1 and 1.22.18) from the releases/ directory
  • Added Yarn 4.13.0 to the releases/ directory
  • Set npmMinimalAgeGate: 7 in .yarnrc.yml — Yarn will now block installation of any package version published less than 7 days ago, providing a buffer against freshly-injected malicious releases

How to test locally or on Vercel

  1. Pull this branch and run yarn --version — confirm it outputs 4.13.0.
  2. Run yarn install and verify it completes without errors.
  3. Attempt to add a package version published within the last 7 days (e.g. a freshly released patch) and confirm Yarn rejects it with an age gate error.
  4. Add a package version older than 7 days and confirm it installs successfully.
  5. Confirm the old Yarn release files (4.5.1, 1.22.18) are no longer present in releases/.

References

- Updated yarnPath in .yarnrc.yml to point to the new Yarn version 4.13.0.
- Changed packageManager in package.json to reflect the updated Yarn version.
- Removed old Yarn versions (4.5.1 and 1.22.18) from the releases directory.
- Added new Yarn version (4.13.0) to the releases directory.
- Set npmMinimalAgeGate to 3 days in .yarnrc.yml for package management optimization.
@changeset-bot
Copy link
Copy Markdown

changeset-bot Bot commented Mar 31, 2026

⚠️ No Changeset found

Latest commit: 0acb381

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@vercel
Copy link
Copy Markdown

vercel Bot commented Mar 31, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
hyperdx-oss Ready Ready Preview, Comment Mar 31, 2026 6:33pm

Request Review

@brandon-pereira brandon-pereira changed the title Brandon/set yarn min version Set Yarn npmMinimalAgeGate Mar 31, 2026
@brandon-pereira brandon-pereira changed the title Set Yarn npmMinimalAgeGate chor: set yarn npmMinimalAgeGate Mar 31, 2026
@brandon-pereira brandon-pereira changed the title chor: set yarn npmMinimalAgeGate chore: set yarn npmMinimalAgeGate Mar 31, 2026
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Mar 31, 2026

Knip - Unused Code Analysis

⚪ No changes detected (1 issues on both main and PR)

What is this?

Knip finds unused files, dependencies, and exports in your codebase.
This comment compares the PR branch against main to detect regressions.

Run yarn knip locally to see full details.

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Mar 31, 2026

PR Review

This is a clean, focused security PR. Changes are minimal and well-scoped.

  • ⚠️ npmMinimalAgeGate: 7d in .yarnrc.yml uses duration string format, but Yarn's docs specify this should be an integer (days), not a duration string → Verify 7d is valid; the Yarn changelog for this feature may expect 7 (integer). If 7d is silently ignored, the security control won't apply.
  • ✅ Yarn 1.22.18 classic release file correctly removed (was an unused legacy artifact)
  • packageManager field in package.json and yarnPath in .yarnrc.yml are consistent at yarn@4.13.0

Main concern: Validate the npmMinimalAgeGate value format is actually enforced — if the format is wrong, the entire security benefit of this PR is nullified with no warning.

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Mar 31, 2026

E2E Test Results

All tests passed • 116 passed • 3 skipped • 1064s

Status Count
✅ Passed 116
❌ Failed 0
⚠️ Flaky 2
⏭️ Skipped 3

Tests ran across 4 shards in parallel.

View full report →

@kodiakhq kodiakhq Bot merged commit c4dcfd7 into main Mar 31, 2026
16 checks passed
@kodiakhq kodiakhq Bot deleted the brandon/set-yarn-min-version branch March 31, 2026 18:37
knudtty pushed a commit that referenced this pull request Apr 16, 2026
## Summary

In response to the recent [axios supply chain attack](https://www.stepsecurity.io/blog/axios-compromised-on-npm-malicious-versions-drop-remote-access-trojan), we are tightening package management controls to reduce our exposure to malicious or compromised npm packages.

**Changes:**
- Updated `yarnPath` in `.yarnrc.yml` to point to Yarn 4.13.0
- Updated `packageManager` in `package.json` to reflect Yarn 4.13.0
- Removed old Yarn releases (4.5.1 and 1.22.18) from the `releases/` directory
- Added Yarn 4.13.0 to the `releases/` directory
- Set `npmMinimalAgeGate: 7` in `.yarnrc.yml` — Yarn will now block installation of any package version published less than 7 days ago, providing a buffer against freshly-injected malicious releases

### How to test locally or on Vercel

1. Pull this branch and run `yarn --version` — confirm it outputs `4.13.0`.
2. Run `yarn install` and verify it completes without errors.
3. Attempt to add a package version published within the last 7 days (e.g. a freshly released patch) and confirm Yarn rejects it with an age gate error.
4. Add a package version older than 7 days and confirm it installs successfully.
5. Confirm the old Yarn release files (`4.5.1`, `1.22.18`) are no longer present in `releases/`.

### References

- Blog post: [axios compromised on npm — malicious versions drop remote access trojan](https://www.stepsecurity.io/blog/axios-compromised-on-npm-malicious-versions-drop-remote-access-trojan)
Copilot AI pushed a commit that referenced this pull request Apr 20, 2026
## Summary

In response to the recent [axios supply chain attack](https://www.stepsecurity.io/blog/axios-compromised-on-npm-malicious-versions-drop-remote-access-trojan), we are tightening package management controls to reduce our exposure to malicious or compromised npm packages.

**Changes:**
- Updated `yarnPath` in `.yarnrc.yml` to point to Yarn 4.13.0
- Updated `packageManager` in `package.json` to reflect Yarn 4.13.0
- Removed old Yarn releases (4.5.1 and 1.22.18) from the `releases/` directory
- Added Yarn 4.13.0 to the `releases/` directory
- Set `npmMinimalAgeGate: 7` in `.yarnrc.yml` — Yarn will now block installation of any package version published less than 7 days ago, providing a buffer against freshly-injected malicious releases

### How to test locally or on Vercel

1. Pull this branch and run `yarn --version` — confirm it outputs `4.13.0`.
2. Run `yarn install` and verify it completes without errors.
3. Attempt to add a package version published within the last 7 days (e.g. a freshly released patch) and confirm Yarn rejects it with an age gate error.
4. Add a package version older than 7 days and confirm it installs successfully.
5. Confirm the old Yarn release files (`4.5.1`, `1.22.18`) are no longer present in `releases/`.

### References

- Blog post: [axios compromised on npm — malicious versions drop remote access trojan](https://www.stepsecurity.io/blog/axios-compromised-on-npm-malicious-versions-drop-remote-access-trojan)
Co-authored-by: peter-leonov-ch <209667683+peter-leonov-ch@users.noreply.github.com>
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.

2 participants