Skip to content

Add in rules for package managers for cooldown (and a few other rules for pnpm)#1

Open
gbennett-squarespace wants to merge 12 commits into
developfrom
package-manager-cooldown
Open

Add in rules for package managers for cooldown (and a few other rules for pnpm)#1
gbennett-squarespace wants to merge 12 commits into
developfrom
package-manager-cooldown

Conversation

@gbennett-squarespace
Copy link
Copy Markdown
Owner

Link to an issue, if relevant

Inspired by recent events and this PR:
semgrep#3791

Rules added:

Cooldown/Minimum Age for:
NPM: vun, pnpm, renovate, yarn
Python: uv

For pnpm also add rules for block exotic subdependencies and trust policy, both related settings to help avoid installing malicious packages.

Rules have been tested in our environment with good success.

One semi-false positive is because pyproject.toml can be used by other package managers (Poetry for example), it'll flag it as missing the setting. Also, if the repo is on too old a version of a package manager, it still flags it. Neither of these are easily solved in the context of the rule running.

In both cases I think there's still a strong argument for raising the finding, as it highlights a security gap in the environment.

gbennett-squarespace and others added 12 commits April 6, 2026 15:45
Clarified the message regarding the cooldown period for Dependabot updates.
Consolidate warning message for missing minimum release age.
Clarify the message for the pnpm-block-exotic-sub-dependencies rule.
Added a warning about missing minimum release age in pnpm configuration.
Updated trust policy message to include guidance on setting 'trustPolicy: no-downgrade' for security.
Document the minimum release age for package updates.
Updated message to simplify instructions for setting a dependency cooldown in uv.
Removed example for npmMinimalAgeGate in the YAML configuration.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant