Inspiration

What it does

How I built it

Inspiration

Most DAO stacks leak votes and interim tally in real time. That creates predictable failure modes:

  • vote buying while the live tally swings,
  • intimidation / herd behavior,
  • governance bribery correlated with timing.

PrivateDAO started as a governance primitive that keeps voting state non-public during the voting phase, while still preserving deterministic execution on Solana.

What it does

PrivateDAO is a Solana governance protocol that implements:

  • Commit–reveal voting with hidden tally during the voting window.
  • Multiple voting modes:
    • Token-weighted
    • Quadratic voting
    • Dual-chamber / threshold-style governance
  • Automated proposal execution with a timelock and treasury safety checks.

How we built it

  • Anchor program (programs/private-dao/src/lib.rs) for core governance logic.
  • End-to-end tests for the full lifecycle:
    • tests/demo.ts (full lifecycle demo)
    • tests/full-flow-test.ts (integration flow)
  • CI quality gates using GitHub Actions to enforce build + tests.
  • A lightweight GitHub Pages frontend (docs/index.html) that showcases the protocol and links to the demo.

Security posture (high-level)

  • Commitment binding: sha256(vote || salt || voter_pubkey) to prevent replay across voters.
  • Snapshot at commit time to prevent vote weight manipulation across phases.
  • Safe execution model: timelock + explicit checks before treasury actions.

Challenges

  • Designing privacy-preserving governance within Solana’s deterministic execution model.
  • Handling operational realities (devnet funding, compute constraints, end-to-end repeatable workflows).
  • Keeping the “demo experience” simple while the protocol logic stays rigorous.

What's next

  • Move from commit–reveal privacy to single-phase privacy using encrypted commitments + zk proof verification for tally correctness.
  • Modularize verifier components for broader composability across Solana programs.
  • Expand treasury policy controls and add configurable security guardrails.

Links

Accomplishments that I'm proud of

What I learned

What's next for PrivateDAO

Built With

  • anchor-(0.32.1)
  • github-actions-(ci)
  • github-pages-(frontend-docs/demo)
  • node.js
  • rust
  • sha-256-commitments
  • solana
  • solana-devnet
  • timelock
  • typescript
  • yarn
Share this project:

Updates