Add X509_NAME_hash_ex() to be able to check if it failed due to unsupported SHA1
[openssl.git] / doc / man3 / RAND_set_rand_method.pod
index 0966b091bbcfb94cdda0913d0a06f6337a51cf85..a989c1c9b471c6be5260d1ba6e7fefeec8cc7d3c 100644 (file)
@@ -23,7 +23,8 @@ RAND_OpenSSL() returns the default B<RAND_METHOD> implementation by OpenSSL.
 This implementation ensures that the PRNG state is unique for each thread.
 
 If an B<ENGINE> is loaded that provides the RAND API, however, it will
-be used instead of the method returned by RAND_OpenSSL().
+be used instead of the method returned by RAND_OpenSSL().  This is deprecated
+in OpenSSL 3.0.
 
 RAND_set_rand_method() makes B<meth> the method for PRNG use.  If an
 ENGINE was providing the method, it will be released first.
@@ -33,10 +34,10 @@ RAND_get_rand_method() returns a pointer to the current B<RAND_METHOD>.
 =head1 THE RAND_METHOD STRUCTURE
 
  typedef struct rand_meth_st {
-     void (*seed)(const void *buf, int num);
+     int (*seed)(const void *buf, int num);
      int (*bytes)(unsigned char *buf, int num);
      void (*cleanup)(void);
-     void (*add)(const void *buf, int num, int randomness);
+     int (*add)(const void *buf, int num, double entropy);
      int (*pseudorand)(unsigned char *buf, int num);
      int (*status)(void);
  } RAND_METHOD;
@@ -58,9 +59,14 @@ L<RAND_bytes(3)>,
 L<ENGINE_by_id(3)>,
 L<RAND(7)>
 
+=head1 HISTORY
+
+The ability for an B<ENGINE> to replace the RAND API was deprecated in
+OpenSSL 3.0.
+
 =head1 COPYRIGHT
 
-Copyright 2000-2018 The OpenSSL Project Authors. All Rights Reserved.
+Copyright 2000-2020 The OpenSSL Project Authors. All Rights Reserved.
 
 Licensed under the Apache License 2.0 (the "License").  You may not use
 this file except in compliance with the License.  You can obtain a copy