Skip to main content

TrustSight

TrustSight

Audits AUR PKGBUILDs before you update: catches careless malice and structural risk, and tells you what it can't verify.

Python License DeepWiki Tests PyPI


The 30-second example

trustsight review
                        TrustSight Review
┏━━━━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━┳━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┓
┃ Package         ┃ Risk Score   ┃ Verdict                                   ┃
┃                 ┃              ┃                                           ┃
┡━━━━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━╇━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━┩
│ chez-scheme-bin │   0/100      │ Version bump. No structural changes.      │
├─────────────────┼──────────────┼───────────────────────────────────────────┤
│ sketchy-pkg     │  35/100      │ R004 HIGH  Checksum disabled (SKIP).      │
│                 │              │ C003 INFO  Source URL changed without     │
│                 │              │            version bump.                  │
│                 │              │ SOURCE_BUCKET MEDIUM  New domain:         │
│                 │              │   sketchy-cdn.invalid (unknown).          │
│                 │              │ NOVELTY HIGH  Source URL first seen       │
│                 │              │   globally.                               │
│                 │              │ PINNING INFO  Source pinning: unpinned.   │
│                 │              │ Verdict: Checksum disabled; sources       │
│                 │              │   replaced with content from an unknown,  │
│                 │              │   never-before-seen domain.               │
├─────────────────┼──────────────┼───────────────────────────────────────────┤
│ obsidian-beta   │  15/100      │ INCONCLUSIVE. Only 2 prior observations;  │
│                 │              │ no high-severity signals from a cold DB.  │
└─────────────────┴──────────────┴───────────────────────────────────────────┘

The tiered evidence display is the differentiator: every signal (rule, bucket, novelty, pinning, verification) is shown with its contribution and severity. You see why the score is what it is.


What it catches / what it can't

Detected by TrustSight Outside TrustSight's scope
Careless malice: curl | bash, base64 | sh, wget pipe sh (R001 recall ~100%). Obfuscated casing, embedded URLs in function bodies. Signed upstream payload: the PKGBUILD is not the binary. A benign build file can fetch a tampered release tarball.
Structural risk: checksums disabled (R004), checksums emptied (R005), URL typosquatting (githab.com), source URLs swapped without a version bump (C003). Deliberately-unremarkable PKGBUILDs: no added commands, no new URLs, no checksum changes; no signal. The update is invisible to diff analysis.
Anomaly-vs-history: first-seen URLs (global or per-package), first-seen maintainer, low-observation-count gating with INCONCLUSIVE verdict. Build-dependency attacks: a malicious makedepends or depends is outside PKGBUILD scope. TrustSight audits the recipe, not the supply chain's second-order dependencies.
Reviewer manipulation: Unicode bidi overrides (R013, 88% recall) that make displayed text differ from executed text. Prompt injection in comments/descriptions (R012, 17% recall; kept as tripwire; primary defense is verdict-integrity assertions). Unpinned sources result in INCONCLUSIVE. A source=($pkgname-$pkgver.tar.gz) with no checksum, tag, or commit pin is reported as structurally weak, not silently accepted.

Install

pipx install trustsight

On Arch Linux, pip install is blocked by the system Python's externally-managed-environment protection. Use pipx (above) or:

pip install --break-system-packages trustsight

AUR: trustsight (dogfood: TrustSight audits its own updates).

From source:

git clone https://github.com/emiliano-go/trustsight
cd trustsight
pip install -e .
# Or with pipx: pipx install .

Requires Python 3.12+.


Commands

Command What it does
trustsight review Scan all outdated AUR packages and produce a scored table with tiered evidence.
trustsight inspect <package> Deep-dive on a single package: full score breakdown, source URLs, resolved commands, novelty context.
trustsight history <package> Show past analysis results for a package, with optional --score-breakdown.
trustsight seed-db Import the bundled novelty seed (178,491 AUR source URLs) so a fresh install is not cold. Runs automatically on first use.
trustsight lint-rules Check rules.toml for unreachable, over-broad or malformed rules. Exits non-zero on errors, for use in CI.
trustsight config Show configuration, set LLM keys, and run sync-rules to receive newly shipped detection rules.

How scoring works

Scoring is deterministic: same input always produces the same score. A core of 13 detection rules (R001 to R013), an expanded set (R039 to R059) calibrated against a 3,322-diff benign corpus, and 7 code-structure rules (C001 to C007) produce signals across four evidence tiers: A (structural, rules on PKGBUILD lines), B (priors/context, URL classification and forge trust), C (history/novelty, first-seen URLs and maintainers gated by observation count), and D (verification, checksums, PGP keys, GPG verify, which subtract from the score). The LLM is entirely optional and never calculates; it translates the deterministic breakdown into English, and verdict-integrity assertions gate its output. See scoring-philosophy.md.


Security model

TrustSight is evidence-producing, not proof-of-safety. It audits and does not install. The tool never runs the PKGBUILD, never executes extracted commands, and never modifies your system. Every finding is traceable to a specific diff line, URL, or novelty record. The output is a structured risk assessment to inform your decision, not a gate. See trust-model.md.


License

MIT. Deliberately permissive to encourage adoption, auditing, and fork-investigation by the Arch Linux and security communities.


Documentation hub

Section Description
Getting Started One-tutorial path from install to first review
Full documentation Docs landing page
Contributing How to report bugs, contribute code, improve docs
Security Vulnerability disclosure policy
License MIT full text

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

trustsight-0.3.1.tar.gz (16.2 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

trustsight-0.3.1-py3-none-any.whl (13.1 MB view details)

Uploaded Python 3

File details

Details for the file trustsight-0.3.1.tar.gz.

File metadata

  • Download URL: trustsight-0.3.1.tar.gz
  • Upload date:
  • Size: 16.2 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.14

File hashes

Hashes for trustsight-0.3.1.tar.gz
Algorithm Hash digest
SHA256 871ea9c501fa9e50d577d5ef3bf6e6a6dccb8ea8654cb7fadbf595eeecc4248a
MD5 57c9cadc9251ce6f93b89971ae2df186
BLAKE2b-256 db23b5fc5350a531436b4624631bba7007a3b25a6e824e0a976a70f3fe88555b

See more details on using hashes here.

Provenance

The following attestation bundles were made for trustsight-0.3.1.tar.gz:

Publisher: publishing.yml on emiliano-go/trustsight

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file trustsight-0.3.1-py3-none-any.whl.

File metadata

  • Download URL: trustsight-0.3.1-py3-none-any.whl
  • Upload date:
  • Size: 13.1 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.14

File hashes

Hashes for trustsight-0.3.1-py3-none-any.whl
Algorithm Hash digest
SHA256 70d11fcf29f12eaeb457816a9dfdda5fac1fc5d7c5c104ede8fa872ae94a5497
MD5 1832ce6ec8b286da70e65ece509b2adf
BLAKE2b-256 33486b12f6ac5fc45f885020e594e21c2f90ba1742c383d72f1a1430614cf008

See more details on using hashes here.

Provenance

The following attestation bundles were made for trustsight-0.3.1-py3-none-any.whl:

Publisher: publishing.yml on emiliano-go/trustsight

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

0.15.7

2 files

0.15.6

2 files

0.15.5

2 files

0.15.4

2 files

0.15.3

2 files

0.15.2

2 files

0.15.1

2 files

0.13.1

2 files

0.13.0

2 files

0.12.1

2 files

0.12.0

2 files

0.11.0

2 files

0.10.1

2 files

0.10.0

2 files

0.9.0

2 files

0.8.0

2 files

0.7.2

2 files

0.7.1

2 files

0.7.0

2 files

0.6.1

2 files

0.6.0

2 files

0.5.1

2 files

0.5.0

2 files

0.4.1

2 files

0.4.0

2 files

This release

0.3.1 This release

2 files

0.3.0

2 files

0.2.0

2 files

0.1.0

2 files

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