Salsa Fresca: Angular Embeddings and Pre-Training for ML Attacks on Learning With Errors
Samuel Stevens, Emily Wenger, Cathy Li, Niklas Nolte, Eshika Saxena, François Charton, Kristin Lauter
TL;DR
This work tackles ML-based attacks on Learning with Errors (LWE) by focusing on sparse binary/ternary secrets at cryptographically relevant dimensions. It introduces Salsa Fresca, combining angular embeddings with an encoder-only transformer and a pre-training regime to drastically reduce preprocessing and data requirements, enabling secret recovery up to $n=1024$ for the first time. The key innovations are faster preprocessing via Flatter with BKZ interleaving, a modular angular embedding that preserves problem structure, and the first application of pre-training to improve sample efficiency in LWE attacks, yielding up to $10\times$ fewer training samples and enabling scalable attacks. These advances significantly push the practical boundaries of ML-based cryptanalysis and have implications for PQC parameter choices, while acknowledging ethical considerations and outlining future improvements across modular arithmetic learning and data generation.
Abstract
Learning with Errors (LWE) is a hard math problem underlying recently standardized post-quantum cryptography (PQC) systems for key exchange and digital signatures. Prior work proposed new machine learning (ML)-based attacks on LWE problems with small, sparse secrets, but these attacks require millions of LWE samples to train on and take days to recover secrets. We propose three key methods -- better preprocessing, angular embeddings and model pre-training -- to improve these attacks, speeding up preprocessing by $25\times$ and improving model sample efficiency by $10\times$. We demonstrate for the first time that pre-training improves and reduces the cost of ML attacks on LWE. Our architecture improvements enable scaling to larger-dimension LWE problems: this work is the first instance of ML attacks recovering sparse binary secrets in dimension $n=1024$, the smallest dimension used in practice for homomorphic encryption applications of LWE where sparse binary secrets are proposed.
