hn.today

Bernstein's Factorization Method Helped Factor RSA-240 in 2020

leetarxiv.substack.com3 points0 comments
Screenshot of Bernstein's Factorization Method Helped Factor RSA-240 in 2020

Bernstein's 2002 batch factorization algorithm is presented along with a practical Python skeleton and contextualized by its role in speeding the 2020 RSA-240 factorization by about 25%. The write-up situates the method inside number-field-sieve workflows - particularly batch or delayed-target discrete logarithm computations - and notes its use in CADO-NFS-style implementations. It highlights that the algorithm finds all small prime factors below a bound B for a list of integers, making the smoothness-detection stage far more efficient when many targets share the same candidate small primes. Code examples are provided on Colab for readers who want to experiment.

Substantively, the method multiplies all targets, builds a product tree of candidate primes (Algorithm 6.1), and uses a recursive routine (Algorithm 6.3) that applies two-adic division and inverse routines (Algorithm 5.1) to identify which primes divide the combined product, then splits results back to per-integer factors (Algorithm 7.1). The exposition reproduces algorithmic pseudocode and Python implementations for ConstructProductTree, FindDividingPrimes (with TwoAdicDivision/Inverse), and the recursive BernsteinFactorization, and demonstrates expected outputs on a small example.

Read on leetarxiv.substack.com0 comments on Hacker News

Summary generated by AI from the linked article. hn.today is not affiliated with Hacker News or Y Combinator.

More in Security

The daily digest

Today's best Hacker News stories, summarized and screenshotted, one email a day.