Time-Memory Trade-Offs for Saber+ on Memory-Constrained RISC-V Platform
- 14 January 2022
- journal article
- research article
- Published by Institute of Electrical and Electronics Engineers (IEEE) in IEEE Transactions on Computers
- Vol. 71 (11) , 2996-3007
Abstract
Saber is a module-lattice-based key encapsulation scheme that has been selected as a finalist in the NIST Post-Quantum Cryptography standardization project. As Saber computes on considerably large matrices and vectors of polynomials, its efficient implementation on memory-constrained IoT devices is very challenging. In this paper, we present an implementation of Saber with a minor tweak to the original Saber protocol for achieving reduced memory consumption and better performance. We call this tweaked implementation ‘Saber+’, and the difference compared to Saber is that we use different generation methods of public matrix $\boldsymbol{A}$ and secret vector $\boldsymbol{s}$ for memory optimization. Our highly optimized software implementation of Saber+ on a memory-constrained RISC-V platform achieves 48% performance improvement compared with the best state-of-the-art memory-optimized implementation of original Saber. Specifically, we present various memory and performance optimizations for Saber+ on a memory-constrained RISC-V microcontroller, with merely 16KB of memory available. We utilize the Number Theoretic Transform (NTT) to speed up the polynomial multiplication in Saber+. For optimizing cycle counts and memory consumption during NTT, we carefully compare the efficiency of the complete and incomplete-NTTs, with platform-specific optimization. We implement 4-layers merging in the complete-NTT and 3-layers merging in the 6-layer incomplete-NTT. An improved on-the-fly generation strategy of the public matrix and secret vector in Saber+ results in low memory footprint. Furthermore, by combining different optimization strategies, various time-memory trade-offs are explored. Our software implementation for Saber+ on selected RISC-V core takes just 3,809K, 3,594K, and 3,193K clock cycles for key generation, encapsulation, and decapsulation, respectively, while consuming only 4.8KB of stack at most.
Keywords
Funding Information
- National Key R&D Program of China (2020AAA0107703)
- National Natural Science Foundation of China (62132008)
- CCF-Tencent Open Fund
- 2021 Tencent Rhino-Bird Research Elite Training Program
This publication has 17 references indexed in Scilit:
- VPQC: A Domain-Specific Vector Processor for Post-Quantum Cryptography Based on RISC-V ArchitectureIEEE Transactions on Circuits and Systems I: Regular Papers, 2020
- Saber: Module-LWR Based Key Exchange, CPA-Secure Encryption and CCA-Secure KEM2018
- CRYSTALS - Kyber: A CCA-Secure Module-Lattice-Based KEM2018
- A Modular Analysis of the Fujisaki-Okamoto Transformation2017
- SHA-3 standard :2015
- Worst-case to average-case reductions for module latticesDesigns, Codes and Cryptography, 2014
- Pseudorandom Functions and Lattices2012
- On Ideal Lattices and Learning with Errors over Rings2010
- Wireless sensor network surveyComputer Networks, 2008
- On lattices, learning with errors, random linear codes, and cryptography2005