Introduction
Zero-knowledge range proofs (ZKRPs) are a cornerstone of privacy-preserving technologies, enabling a prover to demonstrate that a hidden value falls within a specific range (e.g., $[0, 2^{64}-1]$) without revealing the value itself. These proofs are vital for confidential blockchain transactions, anonymous credentials, and secure data aggregation.
However, developers currently face a significant trade-off: protocols like Bulletproofs offer small, logarithmic proof sizes but are computationally expensive to verify, while protocols like Flashproof are fast but produce much larger proofs. This creates bottlenecks for resource-constrained devices and increases gas costs on blockchains like Ethereum. FlashSwift addresses this by bridging the gap, offering a "best of both worlds" scenario: the compact size of logarithmic protocols with the high computational speed of sub-linear ones.
Methodology: The Power of Fusion
FlashSwift achieves its efficiency by fusing two previously incompatible techniques: Flashproof’s Bit-Decomposition (which allows for fast verification via quadratic-term cancellation) and SwiftRange’s Compression (a recursive protocol that shrinks proof size logarithmically).
The technical challenge involved reconciling Flashproof’s three verification equations with SwiftRange’s single-equation compression requirement. The authors utilized a cryptographic trick to combine multiple equations into one using a random challenge, then mathematically transformed this integrated equation into a compression-friendly format.
Furthermore, FlashSwift is highly configurable. By adjusting a "batch-size" parameter ($K$), users can toggle between:
- Low-Gear (LG): Optimized for the smallest possible proof size.
- High-Gear (HG): Optimized for maximum proving speed.
Performance Evaluation
The protocol was implemented in Java and benchmarked against industry standards (Bulletproof, Bulletproof+, Flashproof, and SwiftRange) using the BN-128 elliptic curve on an Apple M1 Pro processor.
Key Results
FlashSwift sets new records for proof shortness in small ranges and maintains high efficiency in standard 64-bit ranges:
- Record-Breaking Size: It achieved the smallest known proof sizes for 8-bit (289 bytes) and 16-bit (417 bytes) ranges among bit-decomposition-based proofs without a trusted setup.
- Superior Speed: For a 64-bit range, FlashSwift is 2.3x faster at proving and 3.2x faster at verification than Bulletproofs, while maintaining an equivalent proof size.
- Blockchain Impact: In simulated Ethereum environments, FlashSwift can reduce gas costs by 15% to 31% compared to existing state-of-the-art protocols.
Conclusion and Future Work
FlashSwift demonstrates that sub-linear speed and logarithmic size are not mutually exclusive. Its configurability allows developers to tailor the proof to their specific hardware or bandwidth constraints. While Bulletproofs still maintains a slight edge in communication efficiency for very large ranges ($N > 64$), FlashSwift is the superior choice for the most common application ranges. Future research will focus on reducing the round complexity of the protocol and further optimizing aggregate proofs for the "Low-Gear" configuration.
Summary updated