Abstract
Learning With Errors (LWE) serves as the foundational security assumption for modern lattice-based cryptography and Homomorphic Encryption (HE). While theoretical heuristics are commonly used to estimate the security of LWE instances, these models are often based on uniform secret distributions. This paper investigates the concrete security of LWE when small secrets (binary, ternary, or discrete Gaussian) are employed. By executing practical lattice reduction attacks using the BKZ 2.0 algorithm, we demonstrate a significant gap between theoretical security estimates and actual performance, revealing that small-secret LWE instances are more vulnerable than previously assumed.
Introduction
The Learning With Errors (LWE) problem is central to the development of post-quantum cryptographic standards and advanced protocols like Homomorphic Encryption. In practical HE implementations, developers frequently opt for "small secrets"—vectors where entries are restricted to small integers such as {0, 1} or {-1, 0, 1}. This choice is driven by the need for computational efficiency and reduced noise growth during homomorphic operations.
However, the security of these parameters is typically evaluated using the "LWE Estimator," a tool that relies on theoretical heuristics derived from the behavior of algorithms on random, uniform lattices. There is a critical need to validate whether these safety margins hold when the secret distribution is non-uniform and small. This study bridges the gap between theory and practice by launching concrete attacks against LWE instances to determine if current security recommendations are truly conservative.
Methodology
To evaluate the concrete security of LWE, the authors employ a reduction to the unique Shortest Vector Problem (uSVP). The attack pipeline consists of several key stages:
- Kannan’s Embedding: LWE instances are transformed into uSVP instances using Kannan’s technique, which embeds the LWE samples into a higher-dimensional lattice where the secret and error vectors form a short vector.
- Scaling and Balancing: To optimize the attack, the authors apply scaling techniques to balance the relative lengths of the secret and error vectors within the lattice structure.
- Lattice Reduction: The core of the attack utilizes the BKZ 2.0 algorithm, implemented via the
fpllllibrary. BKZ 2.0 is the industry standard for lattice reduction, and its performance is measured by the blocksize ($\beta$) required to find the shortest vector. - Comparative Analysis: Experimental results are benchmarked against two primary theoretical models: the 2008 estimates by Gama and Nguyen and the 2016 estimates by Alkim et al.
Experimental Setup and Datasets
The study utilizes two distinct data sources to test the limits of LWE security:
- Synthetic LWE Instances: The authors generated random LWE problems across three specific secret distributions: Binary ({0, 1}), Ternary ({0, ±1}), and Discrete Gaussian. These allow for controlled testing across varying dimensions ($n$) and moduli ($q$).
- TU Darmstadt LWE Challenges: As a standard benchmark in the field, these challenges typically use uniform secrets. The authors created synthetic variants of these challenges using binary and ternary secrets to provide a direct comparison between small-secret and uniform-secret security levels.
Key Findings
The Heuristic Gap
The most striking result is that BKZ 2.0 consistently outperforms theoretical predictions on small-secret lattices. For instance, in an LWE setting with $n=200$ and $\log(q)=19$, the attack succeeded with a blocksize of $\beta=30$. Standard estimators, however, predicted that a blocksize of at least $\beta=40$ would be necessary to break the instance. This suggests that the "safety margin" provided by current estimators is thinner than practitioners assume.
Impact of Secret Distribution
The research highlights that the specific distribution of the small secret significantly affects security. Among the distributions tested:
- Binary secrets proved to be the most vulnerable, requiring the lowest blocksizes to break.
- Ternary secrets offered slightly more resistance than binary ones.
- Discrete Gaussian secrets provided the highest level of security among the small distributions, though still potentially less than uniform secrets of the same dimension.
The "Brittleness" of uSVP Lattices
The authors observed that the root Hermite factor ($\delta$)—a metric for lattice reduction quality—decreases as the lattice dimension increases for successful attacks. This trend contradicts the static or increasing trends predicted by standard heuristics for random lattices. The structure of the uSVP lattice created by a small-secret LWE instance appears to be "brittle," allowing reduction algorithms to find the target vector more efficiently than they would in a generic, random lattice.
Quantitative Results
The discrepancy between theory and practice is most evident in specific parameter sets. In one experiment ($n=110, \log(q)=11$), a binary secret instance was successfully attacked with a blocksize of $\beta=35$. Previous literature, focusing on uniform secrets, suggested that a blocksize of $\beta=78$ would be required for the same parameters. Furthermore, many of these attacks were completed in minutes or hours on standard server hardware, demonstrating that these vulnerabilities are practically exploitable at these scales.
Conclusion and Future Work
This research demonstrates that the concrete security of LWE with small secrets is lower than what is currently predicted by standard theoretical models. The findings suggest that the cryptographic community needs to refine its security heuristics, particularly for applications like Homomorphic Encryption that rely heavily on non-uniform secret distributions.
While this study was limited to relatively small blocksizes ($\beta \leq 45$) and dimensions ($n \leq 200$) due to computational constraints, the observed trends are concerning. Future work should investigate whether this gap between theory and practice widens as parameters scale toward production-grade levels (where $\beta > 100$). Additionally, applying this concrete attack framework to uniform secrets could help determine if the LWE Estimator is more accurate in that regime or if lattice reduction algorithms are generally more efficient than modeled.
Summary updated