packj is a free, open source erp & operations project written in Python and released under AGPL-3.0. It has 693 GitHub stars, 38 forks and 14 open issues, and was last pushed 18 hours ago. On this registry it ranks #19 of 25 tracked projects in ERP & Operations, with 5 head-to-head comparisons available. It gained 1 stars over the last 3 tracked days.

What is packj?

Packj is an open-source software supply-chain security tool that flags malicious, vulnerable, abandoned, and typo-squatting dependencies before they reach production, built for developers and DevOps and DevSecOps teams who vet npm, PyPI, RubyGems, Cargo, Packagist, and NuGet packages.

What it is

Packj is a Python tool, licensed AGPL-3.0, that analyses open-source dependencies for risk. It detects malicious, vulnerable, abandoned, typo-squatting, and other "risky" packages from popular open-source package registries, including NPM, RubyGems, and PyPI. It works through deep static and dynamic code analysis and sandboxing, and it can be customized to minimize noise by turning alerts off according to a chosen threat model. The project began as a PhD research project and is currently developed under various government grants, with a lead team of cybersecurity researchers from academia and industry.

The concrete problem it solves is behavioral blind spots in dependency scanning. As the README states, existing CVE scanners assume code is benign and do not analyze its behavior, so a package that runs malicious install scripts or exfiltrates data can pass a vulnerability scan untouched. Packj replaces that assumption with dynamic analysis and sandboxed execution, and its authors report over 70 malicious PyPI and RubyGems packages found. It lives in the Python ecosystem and ships as a command-line tool, a Docker image, and a GitHub Action.

Key capabilities

  • Flags malicious, vulnerable, abandoned, and typo-squatting packages across NPM, PyPI, Cargo, Rubygems, and Packagist registries, with Rust and PHP support marked work in progress.
  • Performs deep static and dynamic code analysis and sandboxing of packages, reflected in the dynamic-analysis, sandboxing, and malware-analysis topics.
  • Runs as a pull-request audit with ossillate-inc/[email protected], taking DEPENDENCY_FILES: pypi:requirements.txt,npm:package.json,rubygems:Gemfile and a REPO_TOKEN.
  • Ships as the Docker image ossillate/packj:latest, runnable as docker run -v /tmp:/tmp/packj -it ossillate/packj:latest --help, with Podman supported for containerized, isolated runs.
  • Vets local, unpublished NPM and PyPI packages in addition to packages published to a registry.
  • Allows customization to turn off alerts per threat model, reducing false-positive noise.
  • Exposes a command-line entry point from a source checkout via python3 main.py --help.

Who uses it and how

  • Development teams that audit dependency changes inside pull requests, wiring the GitHub Action into their CI so every manifest change is checked against the configured DEPENDENCY_FILES.
  • DevSecOps and security engineers triaging supply-chain risk across several language ecosystems at once, using one tool instead of separate per-registry checks.
  • Python, JavaScript, and Ruby teams whose dependency files are requirements.txt, package.json, and Gemfile.
  • Researchers and practitioners following the project's presentations from PyCon, the Open Source Summit, and BlackHAT.
  • Individual developers evaluating it quickly through the Docker image before committing to a CI integration.

Getting started

The README calls the Docker image the recommended and quickest way to try Packj: docker run -v /tmp:/tmp/packj -it ossillate/packj:latest --help. Alternatives are the GitHub Action ossillate-inc/[email protected], or cloning the repository and running bundle install && pip3 install -r requirements.txt followed by python3 main.py --help.

How it compares

The README positions Packj against existing CVE scanners, which it says assume code is benign and do not analyze its behavior; Packj instead applies static and dynamic analysis and sandboxing to catch malicious packages that a vulnerability database would miss. No other comparable tool is named in the facts supplied for this registry, so on this page it stands alone. There is no list of paid products it replaces, and no licence, self-hosting, data-ownership, or cost comparison against commercial offerings is supported by the facts.

When to use it — and when not to

A self-hoster must operate either the Docker or Podman container or a source checkout with Ruby Bundler and Python dependencies installed, and must accept the obligations of the AGPL-3.0 licence. The project is marked beta, its self-hosted webserver and several integrations were still listed as coming, Docker registry scanning is not supported, and Rust and PHP support is work in progress. Teams that want a turnkey hosted service, or that need Docker image vetting or stable non-beta interfaces, should not pick it yet.

project readme (upstream, from github) — read inline

  Packj flags malicious/risky open-source packages

Packj (pronounced package) is a tool to help to mitigate software supply chain attacks. It can detect malicious, vulnerable, abandoned, typo-squatting, and other "risky" packages from popular open-source package registries, such as NPM, RubyGems, and PyPI. It can be easily customized to minimize noise. Packj started as a PhD research project and is currently being developed under various govt grants.

GitHub Stars Prs Welcome Github Commit Activity Discord License: AGPL v3 Docker

Note Self-hosted Packj webserver and several integrations coming later this month :punch: Watch this repo to stay up to date.

demo video

Contents

  • Get started - available as Docker image, GitHub Action, and packages
  • Functionality - deep static/dynamic code analysis and sandboxing
  • Supported ecosystems - NPM, PyPI, Rubygems, PHP, Rust
  • Our story - started as a PhD research project and is backed by govt grants
  • Why Packj - existing CVE scanners ASSUME code is BENIGN and not analyze its behavior
  • Customization - turn off alerts as per your threat model to reduce noise
  • Malware found - reported over 70 malicious PyPI and RubyGems packages
  • Talks and videos - presentations from PyCon, OpenSourceSummit, BlackHAT
  • Project roadmap - view or suggest new features; join our discord channel
  • Team and collaboration - lead by Cybersecurity researchers from academia/industry
  • FAQ - supported package managers, commonly asked questions on techniques, and more

Get started

We support multiple deployment models:

1. GitHub runner

Use Packj to audit dependencies in pull requests.

- name: Packj Security Audit
  uses: ossillate-inc/[email protected]
  with:
    # TODO: replace with your dependency files in the repo
    DEPENDENCY_FILES: pypi:requirements.txt,npm:package.json,rubygems:Gemfile
    REPO_TOKEN: ${{ secrets.GITHUB_TOKEN }}

View on GitHub marketplace. Example PR run.

2. Docker image (recommended)

The quickest way to try/test Packj is using Docker. Podman is also supported for containerized (isolated) runs.

docker run -v /tmp:/tmp/packj -it ossillate/packj:latest --help

3. Source repo

Clone this repo,

git clone https://github.com/ossillate-inc/packj.git && cd packj

Install dependencies

bundle install && pip3 install -r requirements.txt

Start with help:

python3 main.py --help 

Supported ecosystems

Packj can vet pubished packages from NPM, PyPI, Rust, PHP, and Rubygems package registries. Rust and PHP support is WIP. We're actively adding support for registries. It also supports vetting local (unpublished) NPM and PyPI packages.

Registry Ecosystem Supported
NPM JavaScript :white_check_mark:
PyPI Python :white_check_mark:
Cargo Rust :white_check_mark:
Rubygems Ruby :white_check_mark:
Packagist PHP :white_check_mark:
Docker Docker :x:
Nuget .NET :white_check_mark:
Maven Java :white_check_mark:
Cocoapods Swift :x:

Functionality

Packj offers the following tools:

  • Audit - to vet a package for "risky" attributes.
  • Sandbox - for safe installation of a package.

Auditing a package

Packj audits open-source software packages for "risky" attributes that make them vulnerable to supply chain attacks. For instance, packages with expired email domains (lacking 2FA), large release time gap, sensitive APIs or access permissions, etc. are flagged as risky.

Auditing the following is supported:

  • multiple packages: python3 main.py audit -p pypi:requests rubygems:overcommit
  • dependency files: python3 main.py audit -f npm:package.json pypi:requirements.txt

By default, audit only performs static code analysis to detect risky code. You can paas -t or --trace flag to perform dynamic code analysis as well, which will install all requested packages under strace and monitor install-time behavior of packages. Please see the example output below.

Show example run/output

$ docker run -v /tmp:/tmp/packj -it ossillate/packj:latest audit --trace -p npm:browserify

[+] Fetching 'browserify' from npm..........PASS [ver 17.0.0]
[+]    Checking package description.........PASS [browser-side require() the node way]
[+]    Checking release history.............PASS [484 version(s)]
[+] Checking version........................RISK [702 days old]
[+]    Checking release time gap............PASS [68 days since last release]
[+] Checking author.........................PASS [[email protected]]
[+]    Checking email/domain validity.......RISK [expired author email domain]
[+] Checking readme.........................PASS [26838 bytes]
[+] Checking homepage.......................PASS [https://github.com/browserify/browserify#readme]
[+] Checking downloads......................PASS [2M weekly]
[+] Checking repo URL.......................PASS [https://github.com/browserify/browserify]
[+]    Checking repo data...................PASS [stars: 14189, forks: 1244]
[+]    Checking if repo is a forked copy....PASS [original, not forked]
[+]    Checking repo description............PASS [browser-side require() the node.js way]
[+]    Checking repo activity...............PASS [commits: 2290, contributors: 207, tags: 413]
[+] Checking for CVEs.......................PASS [none found]
[+] Checking dependencies...................RISK [48 found]
[+] Downloading package from npm............PASS [163.83 KB]
[+] Analyzing code..........................RISK [needs 3 perm(s): decode,codegen,file]
[+] Checking files/funcs....................PASS [429 files (383 .js), 744 funcs, LoC: 9.7K]
[+] Installing package and tracing code.....PASS [found 5 process,1130 files,22 network syscalls]
=============================================
[+] 5 risk(s) found, package is undesirable!
=> Complete report: /tmp/packj_54rbjhgm/report_npm-browserify-17.0.0_hlr1rhcz.json
{
    "undesirable": [
        "old package: 702 days old",
        "invalid or no author email: expired author email domain",
        "generates new code at runtime",
        "reads files and dirs",
        "forks or exits OS processes",
    ]
}

WARNING: since packages could execute malicious code during installation, it is recommended to ONLY use -t or --trace when running inside a Docker container or a Virtual Machine.

Audit can also be performed in Docker/Podman containers. Please find details on risky attributes and how to use at Audit README.

Sandboxed package installation

Packj offers a lightweight sandboxing for safe installation of a package. Specifically, it prevents malicious packages from exfiltrating sensitive data, accessing sensitive files (e.g., SSH keys), and persisting malware.

It sandboxes install-time scripts, including any native compliation. It uses strace (i.e., NO VM/Container required).

Please find details on the sandboxing mechanism and how to use at Sandbox README.

Show example run/output

$ python3 main.py sandbox gem install overcommit

Fetching: overcommit-0.59.1.gem (100%)
Install hooks by running `overcommit

readme truncated — read the full docs on github

Frequently asked questions

Is packj free to use?

packj is open source under the AGPL-3.0 licence. There is no licence fee and no seat count — you can self-host it or, where the project offers one, pay a vendor for a managed version instead.

What does packj do?

Packj stops :zap: Solarwinds-, ESLint-, and PyTorch-like attacks by flagging malicious/vulnerable open-source dependencies ("weak links") in your software suppl

What is packj written in?

packj is primarily written in Python. Its source is publicly available at https://github.com/ossillate-inc/packj, and it has 693 GitHub stars.