Please sign in to comment.
Fix generate(Safe)Prime to guarantee prime size
Add check for size in generatePrime Add size test in generateSafePrime Require only that top bit is set, instead of top 2 This is the general standard, see e.g. OpenSSL Add an error for too few bits being supplied to prime generator, and add documentation Add some documentation and require highest two bits set Simplify return syntax in generatePrime and generateSafePrime Switch exponent to bit-shift for small performance boost
- Loading branch information...
Showing with 34 additions and 7 deletions.