Skip to content

Commit 4d53b71

Browse files
authored
build: enable minimumReleaseAge to mitigate dependency chain attacks (angular#2222)
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 a95e3a2 commit 4d53b71

File tree

2 files changed

+41
-3
lines changed

2 files changed

+41
-3
lines changed

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,11 @@
1010
"Angular",
1111
"multi-root ready"
1212
],
13-
"packageManager": "pnpm@10.15.1",
13+
"packageManager": "pnpm@10.16.1",
1414
"engines": {
1515
"npm": "Please use pnpm instead of NPM to install dependencies",
1616
"yarn": "Please use pnpm instead of Yarn to install dependencies",
17-
"pnpm": "10.15.1",
17+
"pnpm": "10.16.1",
1818
"vscode": "^1.74.3"
1919
},
2020
"capabilities": {

pnpm-workspace.yaml

Lines changed: 39 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,4 +3,42 @@ packages:
33
- integration/pre_standalone_project
44
- integration/workspace
55
- integration/pre_apf_project
6-
- integration/project
6+
- integration/project
7+
8+
# The minimum age of a release to be considered for dependency installation.
9+
# The value is in minutes (1440 minutes = 1 day).
10+
minimumReleaseAge: 1440
11+
# List of packages to exclude from the minimum release age check.
12+
# Wildcards are not yet supported: https://github.com/pnpm/pnpm/issues/9983
13+
minimumReleaseAgeExclude:
14+
- '@angular-devkit/architect'
15+
- '@angular-devkit/build-angular'
16+
- '@angular-devkit/build-webpack'
17+
- '@angular-devkit/core'
18+
- '@angular-devkit/schematics-cli'
19+
- '@angular-devkit/schematics'
20+
- '@angular-devkit/architect-cli'
21+
- '@angular-devkit/architect'
22+
- '@angular/animations'
23+
- '@angular/benchpress'
24+
- '@angular/cdk'
25+
- '@angular/ng-dev'
26+
- '@angular/cli'
27+
- '@angular/ssr'
28+
- '@angular/common'
29+
- '@angular/compiler-cli'
30+
- '@angular/compiler'
31+
- '@angular/core'
32+
- '@angular/forms'
33+
- '@angular/language-service'
34+
- '@angular/localize'
35+
- '@angular/material'
36+
- '@angular/material-moment-adapter'
37+
- '@angular/platform-browser-dynamic'
38+
- '@angular/platform-browser'
39+
- '@angular/platform-server'
40+
- '@angular/router'
41+
- '@angular/service-worker'
42+
- '@ngtools/webpack'
43+
- '@schematics/angular'
44+
- 'ng-packagr'

0 commit comments

Comments
 (0)