Created comprehensive openspec structure: openspec/specs/: - mvp.md: MVP feature overview - architecture.md: System architecture and data flows openspec/changes/add-pqc-voting-mvp/: - proposal.md: Project proposal with scope and rationale - tasks.md: Detailed implementation tasks (6 phases, 30+ tasks) - design.md: Complete design document - Cryptographic algorithms (Paillier, Kyber, Dilithium, ZKP) - Data structures (Block, Blockchain, Ballot) - API endpoint specifications - Security properties matrix - Threat model and mitigations Follows openspec three-stage workflow: 1. Creating changes (proposal-based) 2. Implementation (tracked via tasks) 3. Completion (with validation) Ready for implementation phase with clear requirements. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
2.7 KiB
2.7 KiB
Proposal: Add PQC-Based Secure Voting MVP
Summary
Implement Minimum Viable Product for secure electronic voting using Post-Quantum Cryptography (Paillier + Kyber + Dilithium) and Blockchain for vote recording.
Change ID
add-pqc-voting-mvp
Motivation
- Enable secure electronic voting with vote secrecy and integrity
- Implement homomorphic encryption for private vote counting
- Use post-quantum cryptography (Kyber, Dilithium) for quantum resistance
- Provide blockchain-based immutable vote records
- Support individual and universal verifiability
Scope
This proposal adds the complete voting system with:
- Cryptographic toolkit (Paillier, Kyber, Dilithium, ZKP)
- Blockchain module for vote recording
- Voting API endpoints for ballot submission
- Frontend voting interface with client-side encryption
- Blockchain visualization and verification
- Vote counting with homomorphic properties
- Results display and audit reporting
Affected Capabilities
New Capabilities
voting-encryption: Homomorphic vote encryptionblockchain-votes: Immutable vote recordingpqc-signatures: Post-quantum ballot and block signingvote-submission: Secure ballot submission workflowvote-counting: Homomorphic vote summationblockchain-verification: Chain integrity verification
Modified Capabilities
authentication: Extend with voter Dilithium key generationapi-structure: Add new voting endpoints
Key Design Decisions
- Vote Encryption: Paillier homomorphic encryption allows voting without decrypting individual votes
- Post-Quantum: Kyber protects Paillier key, Dilithium signs ballots and blocks
- Blockchain: SHA-256 hash chain ensures vote immutability
- Anonymity: Transaction IDs instead of voter IDs in blockchain
- Verifiability: ZKP proves ballot validity, chain verification proves counting accuracy
Implementation Phases
- Phase 1: Cryptographic foundations (crypto_tools.py + blockchain.py)
- Phase 2: Backend API endpoints
- Phase 3: Frontend voting interface
- Phase 4: Blockchain visualization
- Phase 5: Results and reporting
- Phase 6: Technical report and testing
Success Criteria
- All cryptographic operations implemented and tested
- Blockchain structure immutable and verifiable
- Voting API endpoints functional
- Frontend enables secure ballot encryption and submission
- Vote counting produces verifiable results
- Complete technical & scientific report
- Docker deployment successful
- Security properties validated
Related Issues/Discussions
- Course project: Cryptographie Industrielle Avancée (CIA)
- Requirement: Secure e-voting system with PQC and blockchain