summaryrefslogtreecommitdiffstats
path: root/doc
diff options
context:
space:
mode:
authorBernd Edlinger <bernd.edlinger@hotmail.de>2019-07-10 21:33:48 +0200
committerBernd Edlinger <bernd.edlinger@hotmail.de>2020-03-19 03:18:14 +0100
commit186b50d24e6603460b987a15b4c15782b836a9a8 (patch)
tree4aa6a07b9a16b2b99feff67b5b5d1bb3e4cd439a /doc
parent0032bfea12054da94be04ac26fd0ebcb955dbe67 (diff)
Update documentation of BN_generate_prime_ex
Reviewed-by: Tomas Mraz <tmraz@fedoraproject.org> (Merged from https://github.com/openssl/openssl/pull/9387)
Diffstat (limited to 'doc')
-rw-r--r--doc/man3/BN_generate_prime.pod8
1 files changed, 6 insertions, 2 deletions
diff --git a/doc/man3/BN_generate_prime.pod b/doc/man3/BN_generate_prime.pod
index 31fbc1ffa1..d26e0a99c8 100644
--- a/doc/man3/BN_generate_prime.pod
+++ b/doc/man3/BN_generate_prime.pod
@@ -52,7 +52,9 @@ Deprecated:
BN_generate_prime_ex() generates a pseudo-random prime number of
at least bit length B<bits>. The returned number is probably prime
-with a negligible error.
+with a negligible error. If B<add> is B<NULL> the returned prime
+number will have exact bit length B<bits> with the top most two
+bits set.
If B<ret> is not B<NULL>, it will be used to store the number.
@@ -89,7 +91,9 @@ If B<add> is not B<NULL>, the prime will fulfill the condition p % B<add>
generator.
If B<safe> is true, it will be a safe prime (i.e. a prime p so
-that (p-1)/2 is also prime).
+that (p-1)/2 is also prime). If B<safe> is true, and B<rem> == B<NULL>
+the condition will be p % B<add> == 3.
+It is recommended that B<add> is a multiple of 4.
The random generator must be seeded prior to calling BN_generate_prime_ex().
If the automatic seeding or reseeding of the OpenSSL CSPRNG fails due to