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

git clone https://github.com/emiliano-go/trustsight.git
cd trustsight/packaging/aur
makepkg -si

Not published to the AUR yet. Build from the PKGBUILD in this repository, as above.

The PKGBUILD runs the full test suite during build and installs the dependencies (pygit2, tldextract, rich, openai, typer) as pacman-tracked system packages.

Requires Python 3.10+.


Commands

Command What it does
trustsight review Scan outdated AUR packages and produce a scored table with tiered evidence. Supports --repo, --foreign, --all-repos flags and config-driven multi-repo discovery.
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


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.6.0.tar.gz (24.1 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.6.0-py3-none-any.whl (20.9 MB view details)

Uploaded Python 3

File details

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

File metadata

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

File hashes

Hashes for trustsight-0.6.0.tar.gz
Algorithm Hash digest
SHA256 13d5883b0bdcc533c9c75cc986c6fc712c5ccacc418bf24533225f718174e13d
MD5 9e90da0ea5695015a93f530c98c4618a
BLAKE2b-256 5053c3b40a74119e3a54e726d0ab0153d3e5070ae9322dd97adaf019ee553e44

See more details on using hashes here.

Provenance

The following attestation bundles were made for trustsight-0.6.0.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.6.0-py3-none-any.whl.

File metadata

  • Download URL: trustsight-0.6.0-py3-none-any.whl
  • Upload date:
  • Size: 20.9 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.6.0-py3-none-any.whl
Algorithm Hash digest
SHA256 82955eba09b72a3437802e3e05ce50598a9be93f399bdfd569be74b9665721c6
MD5 40815c00643da57ef2cf817ffa79a991
BLAKE2b-256 d005c870c3f47be9d63c876801e2d89e2617066f235d0044f3c6999ca023bd55

See more details on using hashes here.

Provenance

The following attestation bundles were made for trustsight-0.6.0-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

This release

0.6.0 This release

2 files

0.5.1

2 files

0.5.0

2 files

0.4.1

2 files

0.4.0

2 files

0.3.1

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