mpc-auditor ยท diff
git:20260402.293dccc to git:20261112.cb0111b
68 added, 33 removed. Audit A to A.
What this update changes in the checks
No check changed: every fixed check gives the same answer before and after this update.
A tripped check is a label, not a verdict: read the matched text and the lines below. This week's updates that newly trip a check.
---
name: mpc-auditor
description: >
- Audit MPC implementations for garbled-circuit integrity, oblivious transfer
- misuse, share validation, Beaver triple authenticity, and transcript/session
- binding issues.
- allowed-tools:
- - Read
- - Grep
- - Glob
- - Bash
+ Audit multi-party computation implementations: garbled circuits (free-XOR,
+ half-gates, selective failure), oblivious transfer and OT extension,
+ SPDZ-style MAC checks, Beaver triple authenticity, share validation,
+ malicious vs semi-honest claims, abort and fairness handling, and
+ transcript/session binding. Use when reviewing 2PC/MPC protocol code,
+ preprocessing pipelines, or multi-round secure-computation handlers.
+ allowed-tools: Read Grep Glob Bash
---
# mpc-auditor
- Domain auditor for multi-party computation protocols and transcript integrity.
+ Domain auditor for multi-party computation protocols and transcript
+ integrity: garbled circuits, oblivious transfer, and secret-sharing protocols.
+ **Core principle:** an MPC protocol is secure only in the adversary model it
+ was proven in. Pin the claimed model, then look for each check it requires.
+
## When to Use
- Auditing garbled-circuit protocol implementations
- - Reviewing oblivious transfer role and consistency checks
+ - Reviewing oblivious transfer role and consistency checks and OT extension
- Checking share validation before reconstruction
- Reviewing Beaver triple generation and authenticity guarantees
- - Verifying transcript/session binding across rounds
+ - Verifying transcript/session binding across rounds, retries, and sessions
+ - Testing a malicious-security claim, abort handling, fairness, or broadcast
## When NOT to Use
- - Single-party cryptographic primitive audits without MPC coordination
- - Pure circuit-constraint analysis without multi-party communication/state
- - Confirming suspected findings without verification gates
+ - Threshold ECDSA (Paillier, MtA, GG18/CGGMP21) -> `threshold-ecdsa-auditor`
+ - DKG, VSS ceremonies, FROST, MuSig2, threshold BLS -> `dkg-threshold-auditor`
+ - Single-party signature review, no MPC -> `signature-scheme-auditor`
+ - Single-party encryption review, no MPC -> `encryption-scheme-auditor`
+ - Circuit constraints with no multi-party state -> `zk-circuit-auditor`
+ - Homomorphic-encryption parameters in preprocessing -> `fhe-auditor`
+ - Seed, CSPRNG, and nonce lifecycle -> `randomness-auditor`
+ - Confirming a suspected finding -> `crypto-fp-check`
+ ## Rationalizations to Reject
+
+ | Rationalization | Why it is wrong |
+ |---|---|
+ | "It is a semi-honest protocol, so missing checks are by design" | Semi-honest security says nothing once a party deviates: privacy fails along with correctness. If the deployed parties are separate organisations or client software, the model mismatch is the finding |
+ | "A cheating party can only make the output wrong, and that gets noticed" | Selective failure: a garbler that corrupts one row or one OT message makes the evaluator abort only for some inputs, so the abort itself leaks an input bit |
+ | "OT extension is just a faster base OT" | Without the extension's consistency check a malicious receiver sends inconsistent choice vectors and learns bits of the sender's correlation secret, which opens both messages of every transfer |
+ | "The MAC check runs at the end, so every share is verified" | It protects only what happens after it passes. Outputs, comparisons, or branches revealed earlier were computed on unauthenticated openings |
+ | "Triples come from our own preprocessing service" | A source the online parties cannot check is a trusted dealer. A wrong triple shifts the product by an error the attacker knows; a reused one reveals the difference of two secret inputs |
+ | "The channel is TLS, so messages are bound to the session" | TLS authenticates an endpoint, not a protocol instance, round, or role. A corrupted party is a legitimate endpoint and can replay messages from another session or round |
+
## Core Review Areas
- 1. Participant authentication and role binding
- 2. Transcript/session separation across rounds and retries
- 3. OT input consistency and sender/receiver role correctness
- 4. Share MAC/commitment checks before reconstruction
- 5. Offline/online phase separation and Beaver triple authenticity
+ 1. Claimed adversary model and output guarantee versus the checks present
+ 2. Participant authentication and role binding
+ 3. Transcript/session separation across rounds and retries
+ 4. OT input consistency, sender/receiver role correctness, extension checks
+ 5. Garbled circuits: label freshness, gate-hash assumptions, selective failure
+ 6. Share MAC/commitment checks before reconstruction; canonical field values
+ 7. Offline/online phase separation and Beaver triple authenticity
+ 8. Abort, fairness, and broadcast consistency
## Workflow
### Phase 1: Protocol phase mapping
- - Read `references/mpc-checklist.md`
- - Execute `workflows/share-validation-review.md`
+ - Read `references/mpc-checklist.md` and `references/spec-sources.md`; pin
+ the governing paper and the claimed adversary model
- Enumerate setup, offline, and online phases for each participant role
- ### Phase 2: Share and transcript review
+ ### Phase 2: Share, transcript, and OT review
- - Verify share validation occurs before any reconstruction logic
- - Confirm transcript identifiers are session-specific and replay-resistant
- - Validate participant role binding in all message handlers
+ - Execute `workflows/share-validation-review.md`: share validation before
+ any reconstruction, session-specific and replay-resistant transcript
+ identifiers, participant role binding in every message handler
+ - Execute `workflows/garbling-and-ot-review.md` when the target garbles
+ circuits or uses OT, including OT-based preprocessing
### Phase 3: Pattern hunt
- Read `references/finding-patterns.md`
- - Prioritize unchecked share use, OT role confusion, and unauthenticated triples
+ - Prioritize unchecked share use, OT role confusion, unauthenticated
+ triples, selective failure, and output released before verification
### Phase 4: Handoff
- - Send surviving findings to `crypto-fp-check`
- - Use `zkbugs-index` only after the finding survives verification
+ - Send every surviving candidate to `crypto-fp-check`; severity is assigned
+ there, not here
+ - Cross-route threshold ECDSA to `threshold-ecdsa-auditor`, DKG and
+ threshold Schnorr/BLS to `dkg-threshold-auditor`, randomness lifecycle
+ to `randomness-auditor`, protocol-paper deltas to `spec-delta-checker`
## Output Contract
- Produce an MPC-specific handoff that includes:
+ Produce an MPC handoff listing each candidate with:
- - The protocol phase and participant role involved
- - The transcript/session binding or share-validation invariant at risk
- - Whether the issue is OT, share, triple, garbled-circuit, or reconstruction related
- - The next verification or reporting route
+ - `protocol_phase_and_role` (setup, offline, or online; participant role)
+ - `component` (OT, share, triple, garbled-circuit, reconstruction, session)
+ - `security_model_claimed`
+ - `invariant_at_risk` (the session-binding or share-validation rule)
+ - `evidence` (file:line references, test or tool output)
+ - `disposition` (one of `verified`, `false_positive`, `unverified`,
+ `observation`, `residual_risk`)
+ - `next_route`
## Reference Index
- [references/mpc-checklist.md](references/mpc-checklist.md)
- [references/finding-patterns.md](references/finding-patterns.md)
+ - [references/spec-sources.md](references/spec-sources.md)
- [workflows/share-validation-review.md](workflows/share-validation-review.md)
+ - [workflows/garbling-and-ot-review.md](workflows/garbling-and-ot-review.md)