Engineering Note · Reproducible Black-Box Model

Why single-vendor custody engines grade their own homework.

When an approval web screen, policy engine, and signing key live inside one vendor boundary, or when humans approve transactions they cannot decode at the byte level, one compromised UI or session can authorize a catastrophic transfer. Below are the four public black-box boundary invariants of Decern, paired with two standalone models your security team or reviewers can run in five seconds.

Scope & Prototype Honesty: The scripts on this page model and check Decern's public black-box boundary rules (zero keys in caller, raw-byte digest equivalence, 2-of-3 post-quantum quorum with single-use nonces, and standalone offline receipt tamper checks). They are an open engineering specification rather than an external cryptographic review of Decern's private Rust codebase (Bitcoin signet prototype, 258 workspace tests passing, external review being arranged; U.S. provisional patent 64/130,485 pending).

Architectural Gap

Three structural failure modes in institutional signing today.

Across corporate crypto treasuries, tokenized RWA minting contracts, and autonomous AI agent wallets, high-severity losses share one root cause: the caller and the policy check share a trust boundary.

1. Screen-to-Byte Divergence (The Bybit Failure Class): In February 2025, three hardware-wallet signers at Bybit approved what their browser displayed as a routine transfer while disguised raw parameters executed an ownership takeover costing roughly $1.5 billion. Hardware multisig thresholds worked as coded; the failure occurred because no independent machine boundary unpacked the raw unsigned bytes outside the compromised UI.

2. Single-Domain Policy & Audit Logs: Institutional MPC platforms protect private key shares well, yet their web console, API policy engine, and audit log reside inside one vendor trust domain. External financial statement reviewers, Proof-of-Reserve CPAs, and public-company Audit Committees are left trusting internal vendor exports rather than cross-domain separation of duties.

3. Caller-Side SDK Rules & Concurrent Races: As documented in the October 2026 V12 x402 review (25 flaws) and Cloud Security Alliance note, placing spend caps inside an agent's own SDK fails when prompts are hijacked or parallel sub-agents race the same allowance before state settles.

Four Public Boundary Invariants

What the reference model checks across all 864 states.

Every combination of three asset rails, four wire mutations, four approval quorum counts, three nonce/TTL freshness states, three intent-digest bindings, and direct-bypass attempts is evaluated deterministically.

Invariant Black-Box Boundary Rule Attack Classes Halted Model Result
INV-1
Zero Caller Keys
Calling UIs, treasury scripts, and AI agents hold zero vault keys and cannot emit a co-signature without passing the external Decern gate. Prompt injection, stolen API bearer tokens, compromised frontend servers. 864 / 864 PASS
INV-2
Raw-Byte Binding
Destination, integer amount, and contract operation flag reconstructed from raw unsigned bytes must equal the approved intent digest within policy caps. Bybit-style disguised delegatecall, recipient address swaps, 10x over-cap mint() calls. 0 False Allows
INV-3
Quorum & Nonce
Requires at least 2-of-3 valid NIST FIPS 204 ML-DSA-65 approvals bound to an unspent single-use nonce and active expiration window. Single-insider bypass (1-of-3), concurrent retry races, replayed spent approvals. $0.00 Overdraft
INV-4
Offline Receipt
Every allow or refusal seals canonical digests into a standalone receipt anchored to dual RFC 3161 Timestamp Authorities (freetsa.org, ts.ssl.com). Post-incident log editing (+1 unit mutation detected offline with zero calls to PriviNet). 864 / 864 Caught

Verify in 10 Seconds

Don't take a slide deck on faith. Run the model.

Requires only standard Python 3.9+ (zero third-party pip packages). For symbolic Dolev-Yao trace analysis, run the companion .pv file in INRIA ProVerif.

# 1. Download the standalone 864-state Python boundary checker & run it
curl -sLO https://privinet.net/verify_decern_boundary.py
python3 verify_decern_boundary.py

DECERN BLACK-BOX BOUNDARY MODEL CHECKER v1.0.0
Exhaustive Cartesian states evaluated : 864
Authorized states (valid 2-of-3/3-of-3): 6
Refused attack/mismatch/replay states : 858
Unauthorized co-signatures emitted    : 0
Offline +1 tamper mutations caught    : 864/864
RESULT: ALL 4 PUBLIC BLACK-BOX BOUNDARY INVARIANTS VERIFIED (EXIT 0).

# 2. Optional: verify symbolic Dolev-Yao injective agreement in ProVerif
curl -sLO https://privinet.net/decern_boundary.pv
proverif decern_boundary.pv

1. Exhaustive State Checker (.py)

Zero-dependency Python 3.9+ reference checker testing all 864 boundary combinations and offline receipt mutations.

SHA-256: a8523c3a0c313ce1bbb52d7b661b0c9abbb4a16bac5a067ef4e5bb415bb68860
Download verify_decern_boundary.py →

2. Symbolic Protocol Model (.pv)

INRIA ProVerif specification modeling an untrusted UI/agent on public channel c against 2-of-3 quorum signing.

SHA-256: 6fb725c1be43a3eb4ff34c5ad7f14733a2a50cf97bd5b129b4a5017f7e715a78
Download decern_boundary.pv →
Ready to test your own Safe, token mint, or custody flow on testnet?

Stage 0 is $0 (10-day guided setup on Ethereum Sepolia or Bitcoin signet, zero custody).

Start $0 Stage 0 Trial → View Pricing & Conditional LOI