Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
18 commits
Select commit Hold shift + click to select a range
1b849a5
test(adversarial): add P3Adversarial.t.sol — task_240926_17 Part 2
robertocarlous Oct 5, 2026
1b34776
test(adversarial): address PR #218 review fixes 1-5
robertocarlous Oct 7, 2026
de89a5d
Merge branch 'develop' into feat/issue-154-adversarial-tests
robertocarlous Oct 7, 2026
beeecbe
refactor(task-auditor): DINTaskAuditor size review (#201 Part A item 4)
umermjd11 Oct 6, 2026
329a585
fix(task-auditor): one address can't hold both roles in a GI (#180)
umermjd11 Oct 6, 2026
3e214a8
fix(task-auditor): restore _burnAndForward NatSpec, refresh refs (PR …
umermjd11 Oct 7, 2026
b9cd879
test: prepare isolated integration harness for CI smoke
Santiagocetran Oct 2, 2026
cd778b2
test: preserve validated public demo accounts during isolated bootstrap
Santiagocetran Oct 2, 2026
e18f907
fix(dincli): reject manifest paths that escape their base directory (…
Abidoyesimze Oct 6, 2026
c261b6f
fix(dincli): require role-scoped base_dir in ensure_file_exists/load_…
umeradl Oct 8, 2026
80fdf15
docs(tasks): tick task_061026_22 deliverables (Discussion No. 233 clo…
umeradl Oct 8, 2026
aa76ce1
test: flip dual-role test after cross-role guard
robertocarlous Oct 11, 2026
f4ca70e
Merge branch 'develop' into feat/issue-154-adversarial-tests
robertocarlous Oct 21, 2026
7b92334
Merge branch 'develop' into feat/issue-154-adversarial-tests
robertocarlous Oct 24, 2026
8ec2604
test(adversarial): fix Row 2 vacuous assertion and Row 9b even-count …
robertocarlous Oct 24, 2026
821d0fd
Merge branch 'develop' into feat/issue-154-adversarial-tests
Abidoyesimze Oct 24, 2026
94763ac
Merge branch 'develop' into feat/issue-154-adversarial-tests
robertocarlous Oct 26, 2026
5385fb5
Merge branch 'develop' into feat/issue-154-adversarial-tests
robertocarlous Oct 31, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Developer/design/adversarial-threat-model.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ entry in `foundry/test/P3Adversarial.t.sol`.
| **Attacker** | Sybil operator: k identities, each staking MIN_STAKE, targeting k-of-n seats in one batch |
| **Capability** | k × MIN_STAKE total stake; no control of randomness — batch assignment is `_shuffleAddressArray(valPool, keccak256(seed, "AGG_ADDR"))` (`DINTaskCoordinator.sol:582`) and auditor seat assignment is `_shuffleAddressArray(auditorPool, keccak256(seed, "AUD_ADDR"))` (`DINTaskAuditor.sol:871`), where `seed` is the per-GI `aggSeed`/`auditSeed`: anchored to a future block (`block.number + disputeSeedDelay`) at the preceding GI-state transition and locked permissionlessly via `lockAggSeed`/`lockAuditSeed` (issue #156 H-2, PR #191). `autoCreateTier1AndTier2` and `createAuditorsBatches` are still `onlyOwner`, but revert unless the seed is locked, so the block the owner calls in no longer changes the shuffle. |
| **Protocol response today** | No Sybil-specific defence beyond the per-identity stake requirement. Owner block-picking of the seat shuffle is closed by the H-2 fix: the seed is fixed at a block not yet mined when it is anchored, and batch creation reads the stored seed (`test_createAuditorsBatches_timingIndependent` / `test_autoCreateTier1AndTier2_timingIndependent` in `SecurityFindings.t.sol`). Residuals remain (BL-26): the owner can decline to lock a seed they dislike and let it re-anchor after the ~256-block `blockhash` window (a repeatable re-roll while nobody else locks — aggregator/auditor dincli now locks the seed from the validator side to narrow this), and a validator can unstake between lock and batch creation to reshape the active pool. The seed also trusts the sequencer not to grind `blockhash` (TA-4). None of this changes the Sybil-cost framing below — k identities still win seats at the hypergeometric rate. |
| **Expected test outcome** | **COST-BOUNDED** — the test sets up n registered identities, k of which are Sybil. P(Sybil controls ≥ majority of a 3-seat batch) is hypergeometric: ≈ 3p² − 2p³ where p = k/n (not k/n). The test asserts the fraction of batches where Sybil controls majority and the total stake cost is k × MIN_STAKE. |
| **Expected test outcome** | **COST-BOUNDED** — the test sets up n registered identities (n = 6), k of which are Sybil (k = 3). It asserts: (a) each Sybil identity is active with no identity-level barrier; (b) total Sybil stake locked = k × MIN_STAKE (the sole entry cost). Seat distribution is hypergeometric — P(Sybil controls ≥ 2-of-3 seats) ≈ 3p² − 2p³ where p = k/n; a single deterministic draw cannot assert this probabilistic bound, so the test logs the seat count from the on-chain draw for observability only. |
| **Trust assumption** | n (total registered validators) large enough that k × MIN_STAKE to control majority is economically prohibitive relative to poisoned-model gain (TA-3); seat-shuffle seed not ground by the sequencer (TA-4). |

---
Expand Down
Loading
Loading