Handbook
Glossary
Safe prime numbers
The
math
.
primes
.
safe
vocabulary implements words to calculate safe prime numbers. Safe primes are of the form
p = 2q + 1
, where
p
,
q
are prime. Safe primes have desirable qualities for cryptographic applications.
Testing if a number is a safe prime:
safe-prime?
( q -- ? )
Generating safe prime numbers:
next-safe-prime
( n -- q )
random-safe-prime
( numbits -- p )