Package trust and provenance verification for PyPI consumers.
Project description
trustcheck
trustcheck is a Python package and CLI for evaluating the trust posture of PyPI releases before they are installed, promoted, or approved.
It combines PyPI metadata, vulnerability records, provenance availability, cryptographic attestation verification, Trusted Publisher identity hints, and repository matching into a single operator-friendly report.
Packages that publish no provenance are treated as needing review rather than as automatic high-risk findings, while invalid provenance, partial coverage, repository mismatches, and known vulnerabilities remain stronger negative signals.
What it checks
For a selected package version, trustcheck can:
- fetch project and release metadata from PyPI
- verify published provenance against artifact digests
- surface Trusted Publisher repository and workflow identity hints
- compare expected repository input against declared and attested signals
- flag publisher drift, missing verification, and known vulnerabilities
- emit concise text output or structured JSON for automation
Installation
pip install trustcheck
Requirements:
- Python
>=3.10 - Network access to PyPI
Quick start
Inspect the latest release:
trustcheck inspect requests
Inspect a specific version:
trustcheck inspect sampleproject --version 4.0.0
Show only known vulnerabilities for a release:
trustcheck inspect sampleproject --version 4.0.0 --cve
Inspect a package and its direct dependencies:
trustcheck inspect sampleproject --version 4.0.0 --with-deps
Inspect the full transitive dependency tree:
trustcheck inspect sampleproject --version 4.0.0 --with-transitive-deps
Inspect every package listed in a requirements-style file:
trustcheck scan requirements.txt
Inspect dependencies declared in a TOML project file:
trustcheck scan pyproject.toml
Require a release to match an expected repository:
trustcheck inspect sampleproject \
--version 4.0.0 \
--expected-repo https://github.com/pypa/sampleproject
Emit JSON for another tool:
trustcheck inspect sampleproject --version 4.0.0 --format json
Emit combined JSON for a requirements-style or TOML file scan:
trustcheck scan requirements.txt --format json
Emit only vulnerability records as JSON:
trustcheck inspect sampleproject --version 4.0.0 --cve --format json
Fail CI when full verification is missing:
trustcheck inspect sampleproject --version 4.0.0 --strict
Use it from Python:
from trustcheck import inspect_package
report = inspect_package("sampleproject", version="4.0.0", include_dependencies=True)
print(report.recommendation)
Documentation
Full documentation: https://halfblood-prince.github.io/trustcheck/
- Getting started: Installation and Quickstart
- CLI usage: CLI overview, Policies, and Config and offline mode
- Integrations: JSON contract, Python API, and Compatibility
- Trust model: Verification model and repository matching
- Automation: CI integration
- Project details: Development and release process and Changelog
License
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file trustcheck-1.8.0.tar.gz.
File metadata
- Download URL: trustcheck-1.8.0.tar.gz
- Upload date:
- Size: 639.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ec0a2a8eb90e2daab0deccf4200199e19c589a14bbaf6c64993238ade95e0ac4
|
|
| MD5 |
f19c140bd819268cf68e49d430e4745d
|
|
| BLAKE2b-256 |
75fa9f60ac0d86b33ba72036dc75c9a068e912ce9119b85473eb450ac3cd44a9
|
Provenance
The following attestation bundles were made for trustcheck-1.8.0.tar.gz:
Publisher:
publish.yml on Halfblood-Prince/trustcheck
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
trustcheck-1.8.0.tar.gz -
Subject digest:
ec0a2a8eb90e2daab0deccf4200199e19c589a14bbaf6c64993238ade95e0ac4 - Sigstore transparency entry: 1318822426
- Sigstore integration time:
-
Permalink:
Halfblood-Prince/trustcheck@a553aae98f45bbb4ec1aa200a6781212ef3cbc66 -
Branch / Tag:
refs/tags/v1.8.0 - Owner: https://github.com/Halfblood-Prince
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@a553aae98f45bbb4ec1aa200a6781212ef3cbc66 -
Trigger Event:
push
-
Statement type:
File details
Details for the file trustcheck-1.8.0-py3-none-any.whl.
File metadata
- Download URL: trustcheck-1.8.0-py3-none-any.whl
- Upload date:
- Size: 36.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
763f49d55874e0f8231cc9ea54d528ada7e369cf138bd282f51f7be4601f2251
|
|
| MD5 |
f2abbb28f9f1548299b9123a2773040c
|
|
| BLAKE2b-256 |
d5914ef08f0f477f0d2c5f28996c9ae1cb61443887c325633ba20245d082a773
|
Provenance
The following attestation bundles were made for trustcheck-1.8.0-py3-none-any.whl:
Publisher:
publish.yml on Halfblood-Prince/trustcheck
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
trustcheck-1.8.0-py3-none-any.whl -
Subject digest:
763f49d55874e0f8231cc9ea54d528ada7e369cf138bd282f51f7be4601f2251 - Sigstore transparency entry: 1318822561
- Sigstore integration time:
-
Permalink:
Halfblood-Prince/trustcheck@a553aae98f45bbb4ec1aa200a6781212ef3cbc66 -
Branch / Tag:
refs/tags/v1.8.0 - Owner: https://github.com/Halfblood-Prince
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@a553aae98f45bbb4ec1aa200a6781212ef3cbc66 -
Trigger Event:
push
-
Statement type: