Skip to main content
Precaution CLI Build and Test Latest Version Python Versions PyPI - Downloads

Precli is the core of the Precaution App and Precaution Action. It also serves as a command line interface to demonstate its functionality. It is designed to do static code analysis of source code with a number of rules covering the standard library for the corresponding programming language.

If your needs go beyond the analysis of just the standard library, consider upgrading to Precaution Professional to get access to finding and fixing security vulnerabilities in third-party libraries. See https://www.securesauce.dev/ for more details.

Quick Start

To install:

pip install precli

Run precli on a single test example:

precli tests/unit/rules/python/stdlib/hmac/examples/hmac_timing_attack.py

Example code:

# level: ERROR
# start_line: 18
# end_line: 18
# start_column: 13
# end_column: 15
import hmac


received_digest = (
    b"\xe2\x93\x08\x19T8\xdc\x80\xef\x87\x90m\x1f\x9d\xf7\xf2"
    b"\xf5\x10>\xdbf\xa2\xaf\xf7x\xcdX\xdf"
)

key = b"my-super-duper-secret-key-string"
password = b"pass"
digest = hmac.digest(key, password, digest="sha224")

print(digest == received_digest)

Example result:

Example output

Metadata

Release files for precli 0.8.6

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for precli 0.8.6
File Size Uploaded Provenance Actions
precli-0.8.6.tar.gz 431.3 kB With provenance Details for precli-0.8.6.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for precli 0.8.6
File Interpreter ABI Platform Actions
precli-0.8.6-py3-none-any.whl Python 3 none any Details for precli-0.8.6-py3-none-any.whl

Total release size: 678.9 kB

Release files / precli-0.8.6.tar.gz

Download URL precli-0.8.6.tar.gz
Size 431.3 kB
Tags Source
SHA-256 checksum
How to use checksums
17f62ba6c13216c5d7de91c731322b8780c1e71392eb81f27cea6ecce42f3fc0
BLAKE2b-256 checksum
How to use checksums
87de565734cde2a180d670fde825f08bede4153cca5e20d88704a3ef53dbb4b9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 17, 2026.

Transparency log

Release files / precli-0.8.6-py3-none-any.whl

Download URL precli-0.8.6-py3-none-any.whl
Size 247.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
55837aad1c32fb7ffe37c342fc5fc9e39b377e90d16dffb0baffa8771504e2c4
BLAKE2b-256 checksum
How to use checksums
380b3facecaa532d0be66425a45a3d4bb776c9c73e60dc969cbd50ab7dfbcf8b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 17, 2026.

Transparency log

Security for precli 0.8.6

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for precli-0.8.6.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 17, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.8.6 This release

2 release files Full provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page