PostHog / PostHog/warlock

New rule: detect global pip installs (and other non-JS package managers)

Open
#23 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement
Dominant language
TypeScript
Stars
0
Forks
1
PR merge metrics
No merged PRs in 30d

Description

Context

From Vincent's review on PR #13 — the current supply_chain_npm_install_global rule covers JS package managers (npm, pnpm, yarn, bun, deno, cnpm). Vincent asks: should we also cover pip install and other ecosystems?

What to catch

  • pip install outside a virtual environment (effectively a global install)
  • pip install --user (user-level install, broader than project-scoped)
  • gem install (Ruby)
  • cargo install (Rust)
  • go install (Go)

Considerations

  • Python's pip doesn't have a -g flag — it installs to the active environment by default. Detection would need a different pattern (checking for venv activation, --target, etc.).
  • Each ecosystem has different conventions. May need separate rules per ecosystem.
  • Start with pip since it's the most commonly used after JS package managers.

Origin

PR #13 review comment by @gewenyu99

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reading the existing supply_chain_npm_install_global rule referenced in the issue and PR #13. Confirm the scope for pip first, including installs outside a virtual environment and pip install --user; define what done means before deciding whether gem, cargo, and go need separate rules.

Written by the indexing model from the issue text.

Assessment

Tech stack
go, javascript, python, ruby, rust
Domain
security
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
52/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.