Skip to main content

RangeSpec

RangeSpec is an offline-first manifest format and command-line tool for declaring what an authorized security range may do before a test begins.

It records targets, permitted actions, time limits, rate limits, safe state, stop conditions, recovery evidence, approvals, and evidence-handling rules in a versioned JSON document. The CLI validates those declarations, produces stable fingerprints, redacts sensitive fields, and compares revisions.

RangeSpec is an early Tropiro open-source project. It does not authorize work by itself, execute tests, scan networks, exploit targets, or replace contracts and human approval.

GitHub Action

A repository can make RangeSpec validation a required check before a lab or security-testing workflow runs:

- name: Validate declared scope
  id: rangespec
  uses: tropiro/rangespec@v0.2.1
  with:
    manifest: range/authorized-test.json
    execution-ready: "true"

The action returns the canonical manifest fingerprint as steps.rangespec.outputs.fingerprint. The manifest path must stay inside the checked-out repository. Validation is local and deterministic: the action does not execute tests against a target, contact Claude, or read an API key.

For time-window checks that must be reproducible, pass an explicit timestamp:

with:
  manifest: range/authorized-test.json
  execution-ready: "true"
  at: "2026-10-08T20:00:00Z"

See the complete example workflow.

Demonstrated workflow

From this directory:

uv sync --all-extras --dev
uv run rangespec validate examples/gateway-valid.json \
  --execution-ready \
  --at 2026-10-08T20:00:00Z
uv run rangespec fingerprint examples/gateway-valid.json
uv run rangespec review examples/gateway-valid.json --provider local
./scripts/check.sh

The valid example describes only documentation-range addresses and a simulated gateway. The --at value makes the demonstration reproducible rather than depending on the current clock.

Commands

  • validate: run schema and semantic checks; optionally require an execution-ready approved manifest.
  • normalize: write stable, human-readable JSON through an atomic verified replacement.
  • fingerprint: calculate a SHA-256 digest over canonical JSON.
  • redact: create a wrapped export with declared JSON Pointer paths and sensitive key names replaced.
  • diff: compare two manifests after redaction.
  • review: run an advisory completeness review. The default provider is local and deterministic.
  • schema: print the authoritative bundled JSON Schema.

Every failure is returned with a stable code and JSON Pointer path. CLI exit codes are documented by rangespec --help.

Optional Claude review

The optional Anthropic provider sends only the redacted manifest and requests a structured completeness review. It cannot change the manifest or authorize a test.

export ANTHROPIC_API_KEY="..."
export ANTHROPIC_MODEL="claude-sonnet-5-5"
uv run --extra anthropic rangespec review examples/gateway-valid.json \
  --provider anthropic

No model is selected silently: pass --model or set ANTHROPIC_MODEL. Never put an API key in a manifest, command argument, repository file, or captured output.

Safety boundary

RangeSpec intentionally has no network-execution feature. A later runner may consume a validated manifest, but it must independently enforce the same target and action allowlists. Ownership of a manifest is not proof of authorization.

Read THREAT_MODEL.md before building an integration.

Development

./scripts/check.sh installs the locked development environment and runs lock verification, formatting checks, lint, strict type checking, tests, a package build, and the deterministic example workflow.

The gate also exercises the GitHub Action entrypoint with the documented execution-ready example and verifies that its output fingerprint is stable.

See CONTRIBUTING.md and SECURITY.md.

Metadata

Release files for tropiro-rangespec 0.2.1

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

Source distribution (sdist)

Source distribution for tropiro-rangespec 0.2.1
File Size Uploaded Provenance
tropiro_rangespec-0.2.1.tar.gz 119.6 kB With provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for tropiro-rangespec 0.2.1
File Interpreter ABI Platform
tropiro_rangespec-0.2.1-py3-none-any.whl Python 3 none any Details

Total release size: 152.2 kB

Release files / tropiro_rangespec-0.2.1.tar.gz

Download URL tropiro_rangespec-0.2.1.tar.gz
Size 119.6 kB
Tags Source
SHA-256 checksum
How to use checksums
c2b72adf0087b79a59671519eda4102a3369b3126227904d94173294947c988e
BLAKE2b-256 checksum
How to use checksums
fad0efbfdb167ba200b73ef52667bfb8e3b67f4c586df08b0502a41899258d42
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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 20, 2026.

Transparency log

Release files / tropiro_rangespec-0.2.1-py3-none-any.whl

Download URL tropiro_rangespec-0.2.1-py3-none-any.whl
Size 32.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
b2d7cdd21d29f6782fa4f692ea645a95286a9b8d4ca74d95959426f68f7fe6da
BLAKE2b-256 checksum
How to use checksums
0ab9003e863a670210a131164915dcad6606783080dda6da0b432cbabebe0ab4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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 20, 2026.

Transparency log

Security for tropiro-rangespec 0.2.1

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

All 2 files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for tropiro_rangespec-0.2.1.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 20, 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.2.1 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