Skip to content

Commit 51dbaae

Browse files
committed
add npmrc
1 parent 0922af8 commit 51dbaae

File tree

1 file changed

+32
-0
lines changed

1 file changed

+32
-0
lines changed

.npmrc

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
# Security settings for pnpm/npm
2+
# Enforces supply chain security best practices
3+
4+
# Enforce official registry (prevent typosquatting via alternate registries)
5+
registry=https://registry.npmjs.org/
6+
7+
# Require lock file to be up-to-date (fail if package.json doesn't match lock)
8+
prefer-frozen-lockfile=true
9+
10+
# Strict SSL validation
11+
strict-ssl=true
12+
13+
# Fail on missing or invalid peer dependencies
14+
strict-peer-dependencies=true
15+
16+
# Pin exact versions when adding new dependencies
17+
save-exact=true
18+
19+
# Audit level - fail on high/critical vulnerabilities
20+
audit-level=high
21+
22+
# Disable lifecycle scripts (preinstall, postinstall, etc.) to prevent arbitrary code execution
23+
ignore-scripts=true
24+
25+
# Verify integrity of packages in the store before linking to node_modules
26+
verify-store-integrity=true
27+
28+
# Validate that the correct package manager is being used
29+
package-manager-strict=true
30+
31+
# Delay installation of packages published less than 7 days ago
32+
minimum-release-age=10080

0 commit comments

Comments
 (0)