|
1 | | -# Audit Tooling: |
| 1 | +# Audit Tooling |
2 | 2 |
|
3 | | -## Offline audit |
| 3 | +Independent verification tools for Catalyst voting results. These tools allow anyone to audit and verify the integrity of voting outcomes without needing to trust centralized authorities. |
4 | 4 |
|
5 | | -### Download Fund State |
6 | | -Download historical fund state from [*here*](https://github.com/input-output-hk/catalyst-core) in order to replay and audit the voting event. |
| 5 | +## Quick Start |
7 | 6 |
|
8 | | -The official published results can be found in this file in the form of **activevoteplans.json**. |
| 7 | +### 1. Download Fund State |
9 | 8 |
|
10 | | -**activevoteplans.json** = FINAL RESULTS. |
| 9 | +Download historical fund state from [here](https://github.com/input-output-hk/catalyst-core) to replay and audit the voting event. |
11 | 10 |
|
12 | | -If you would like to re-generate **activevoteplans.json** yourself, via a live node and historical fragments - [*see here for instructions*](./balance/README.md) |
| 11 | +The official published results are found in **activevoteplans.json**. |
13 | 12 |
|
14 | | -If not, you can begin the audit with the following steps. |
| 13 | +**activevoteplans.json** = FINAL RESULTS. |
15 | 14 |
|
16 | | -*Example usage:* |
| 15 | +### 2. Build the Audit Tool |
17 | 16 |
|
18 | | -``` |
| 17 | +```bash |
19 | 18 | cargo build --release -p audit |
20 | | -``` |
| 19 | +``` |
21 | 20 |
|
22 | | -*Cross reference offline tallies with published catalyst tallies.* |
| 21 | +### 3. Run Offline Audit |
23 | 22 |
|
24 | | -```bash |
| 23 | +#### Option A: Cross-reference with Official Results |
| 24 | + |
| 25 | +Compare your audit results with published Catalyst tallies: |
25 | 26 |
|
| 27 | +```bash |
26 | 28 | OFFICIAL_RESULTS=/tmp/activevoteplans.json |
27 | 29 | BLOCK0=/tmp/fund9-leader-1/artifacts/block0.bin |
28 | 30 | FRAGMENTS_STORAGE=/tmp/fund9-leader-1/persist/leader-1 |
29 | 31 |
|
30 | 32 | ./target/release/offline --fragments $FRAGMENTS_STORAGE --block0 $BLOCK0 --official-results $OFFICIAL_RESULTS |
31 | | - |
32 | 33 | ``` |
33 | 34 |
|
34 | | - |
35 | | -*Generate encrypted tally with gamma scaling* |
36 | | - |
| 35 | +#### Option B: Generate Encrypted Tally with Gamma Scaling |
37 | 36 |
|
38 | 37 | ```bash |
39 | | - |
40 | 38 | BLOCK0=/tmp/fund9-leader-1/artifacts/block0.bin |
41 | 39 | FRAGMENTS_STORAGE=/tmp/fund9-leader-1/persist/leader-1 |
42 | 40 | GAMMA=0.5 |
43 | | -PRECISION=100 |
44 | | - |
| 41 | +PRECISION=5 |
45 | 42 |
|
46 | | -./target/release/offline --fragments $FRAGMENTS_STORAGE --block0 $BLOCK0 --gamma $GAMMA --precision $PRECISION |
| 43 | +./target/release/offline --fragments $FRAGMENTS_STORAGE --block0 $BLOCK0 --gamma $GAMMA --precision $PRECISION |
47 | 44 | ``` |
48 | 45 |
|
49 | | -This will create three files: |
50 | | -- *ledger_after_tally.json* **(decrypted ledger state after tally)** *should match official results!* |
51 | | -- *ledger_before_tally.json* **(encrypted ledger state before tally)** |
52 | | -- *decryption_shares.json* **(decryption shares for each proposal)** |
| 46 | +### 4. Generated Files |
| 47 | + |
| 48 | +The offline audit creates three critical files: |
53 | 49 |
|
54 | | -[*See here for next steps of audit process*](src/tally/README.md) |
| 50 | +- **ledger_after_tally.json** - Decrypted ledger state after tally *(should match official results!)* |
| 51 | +- **ledger_before_tally.json** - Encrypted ledger state before tally |
| 52 | +- **decryption_shares.json** - Decryption shares for each proposal |
55 | 53 |
|
56 | | -### Find my vote |
57 | | -[*See here for instructions on how to find your voting history*](src/find/README.md) |
| 54 | +--- |
| 55 | + |
| 56 | +## ➡️ **NEXT STEP: Verify Individual Proposals** |
| 57 | + |
| 58 | +**🔍 [Complete the audit process - Verify specific proposal results →](src/tally/README.md)** |
| 59 | + |
| 60 | +After generating the audit files above, the next crucial step is to **independently verify individual proposal results** using cryptographic proof. This step: |
| 61 | + |
| 62 | +- ✅ **Validates each proposal's decryption** was performed correctly |
| 63 | +- ✅ **Provides mathematical proof** of result integrity |
| 64 | +- ✅ **Requires no trust** in election officials or committee members |
| 65 | +- ✅ **Can be run by anyone** using publicly available data |
| 66 | + |
| 67 | +**Why this step is essential:** |
| 68 | +- The offline audit gives you the raw encrypted data |
| 69 | +- The tally verification proves the decryption was legitimate |
| 70 | +- Together, they provide complete end-to-end verification |
| 71 | + |
| 72 | +--- |
| 73 | + |
| 74 | +## Additional Tools |
| 75 | + |
| 76 | +### Find Your Vote |
| 77 | +[See instructions on how to find your voting history →](src/find/README.md) |
| 78 | + |
| 79 | +### Regenerate Results from Live Node |
| 80 | +If you want to regenerate **activevoteplans.json** yourself via a live node and historical fragments: |
| 81 | +[See instructions here →](./balance/README.md) |
| 82 | + |
| 83 | +## Overview |
| 84 | + |
| 85 | +This audit tooling provides: |
| 86 | + |
| 87 | +1. **Offline Verification** - Replay voting events from blockchain data |
| 88 | +2. **Cryptographic Proof** - Mathematically verify decryption integrity |
| 89 | +3. **Individual Vote Tracking** - Find and verify your specific votes |
| 90 | +4. **Complete Transparency** - No black boxes or trusted components |
| 91 | + |
| 92 | +The audit process is designed to be completely independent and reproducible, ensuring that anyone can verify Catalyst voting results without needing to trust any centralized authority. |
| 93 | +``` |
0 commit comments