v1.1.3
Changelog: v1.1.3
🔧 Core Changes
-
Enhanced Freivalds Verification for Epoch 260+ (Major Enhancement)
• Files: lib/bic/sol.ex, lib/bic/base.ex, lib/node/node_state.ex
• What Changed: Introduced new verification method Blake3.freivalds_e260() that uses VRF-based randomness instead of purely random values
• Technical Details:
• Solutions for epochs ≥260 now use Blake3.freivalds_e260(sol, vr_b3) where vr_b3 is Blake3 hash of the entry's VR (Verifiable Random value)
• Legacy solutions (epochs <260) continue using original Blake3.freivalds(sol) method
• Added epoch-aware verification logic with proper fallback handling
• Impact: This strengthens the cryptographic security of solution verification by using deterministic VRF-derived randomness instead of potentially predictable random values -
Consensus Environment Enhancement
• File: lib/consensus/consensus.ex
• What Changed: Added entry_vr_b3 field to consensus environment mapping
• Technical Details:
• New field: :entry_vr_b3 => Blake3.hash(next_entry.header_unpacked.vr)
• Provides pre-computed Blake3 hash of VR for efficient access during verification
• Impact: Optimizes performance by pre-computing VR hash rather than calculating it repeatedly during solution verification -
Helper Function Addition
• File: lib/consensus/consensus.ex
• What Changed: Added new chain_muts/1 helper function
• Technical Details:
elixir
• Impact: Provides direct access to mutation data by hash, complementing existing chain_muts_rev/1 function -
Blake3 Dependency Update
• File: mix.lock
• What Changed: Updated Blake3 library from commit 13b02ab to 396c613
• Technical Details: This update likely includes the new freivalds_e260/2 function implementation
• Impact: Enables the new epoch-260+ verification functionality -
Version Bump
• File: mix.exs
• What Changed: Version updated from "1.1.2" to "1.1.3"
🛡️ Security Improvements
• Enhanced Solution Verification: The new VRF-based approach in epoch 260+ prevents potential attacks where malicious actors might try to predict or manipulate the randomness used in Freivalds verification
• Backward Compatibility: Maintains full compatibility with existing solutions from earlier epochs while strengthening future ones
🔍 What This Fixes/Improves
- Cryptographic Security: Addresses potential vulnerabilities in solution verification by replacing pseudo-random values with cryptographically secure VRF-derived randomness
- Performance: Pre-computing VR hashes reduces computational overhead during verification
- Code Organization: The new helper function improves code maintainability and provides consistent database access patterns
• None - all changes are backward compatible and use epoch-based feature gating
📋 Migration Notes
• No action required for existing deployments
• Solutions submitted in epoch 260+ will automatically use the enhanced verification
• Legacy solutions continue to work unchanged
Summary: This release primarily focuses on enhancing the cryptographic security of solution verification for future epochs while maintaining full backward compatibility. The changes represent a significant security improvement in the consensus mechanism without disrupting existing functionality.