Skip to content

Commit 3f744bc

Browse files
committed
build: enable minimumReleaseAge to mitigate dependency chain attacks
This change configures pnpm's `minimumReleaseAge` setting to 1 day (1440 minutes). This is a security measure to mitigate dependency chain attacks, where malicious actors publish a new version of a dependency with malicious code and then trick users into updating to it before it can be discovered and reported. By delaying the adoption of new releases, we reduce the window of opportunity for such attacks. The list of excluded packages contains trusted and frequently updated dependencies from the Angular team, which are considered safe to use without this delay.
1 parent 6b511cf commit 3f744bc

File tree

2 files changed

+10
-0
lines changed

2 files changed

+10
-0
lines changed

package.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,12 @@
2727
"license": "MIT",
2828
"description": "Web Codegen Scorer is a tool for evaluating the quality of web code generated by Large Language Models (LLMs).",
2929
"type": "module",
30+
"packageManager": "[email protected]",
31+
"engines": {
32+
"npm": "Please use pnpm instead of NPM to install dependencies",
33+
"yarn": "Please use pnpm instead of Yarn to install dependencies",
34+
"pnpm": "10.16.1"
35+
},
3036
"bugs": {
3137
"url": "https://github.com/angular/web-codegen-scorer/issues"
3238
},

pnpm-workspace.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
11
packages:
22
- .
33
- report-app
4+
5+
# The minimum age of a release to be considered for dependency installation.
6+
# The value is in minutes (1440 minutes = 1 day).
7+
minimumReleaseAge: 1440

0 commit comments

Comments
 (0)