Home | History | Annotate | Line # | Download | only in man3
      1 =pod
      2 
      3 =head1 NAME
      4 
      5 RSA_new, RSA_free - allocate and free RSA objects
      6 
      7 =head1 SYNOPSIS
      8 
      9  #include <openssl/rsa.h>
     10 
     11 The following functions have been deprecated since OpenSSL 3.0, and can be
     12 hidden entirely by defining B<OPENSSL_API_COMPAT> with a suitable version value,
     13 see L<openssl_user_macros(7)>:
     14 
     15  RSA *RSA_new(void);
     16 
     17  void RSA_free(RSA *rsa);
     18 
     19 =head1 DESCRIPTION
     20 
     21 RSA_new() allocates and initializes an B<RSA> structure. It is equivalent to
     22 calling RSA_new_method(NULL).
     23 
     24 RSA_free() frees the B<RSA> structure and its components. The key is
     25 erased before the memory is returned to the system.
     26 If B<rsa> is NULL nothing is done.
     27 
     28 =head1 RETURN VALUES
     29 
     30 If the allocation fails, RSA_new() returns B<NULL> and sets an error
     31 code that can be obtained by L<ERR_get_error(3)>. Otherwise it returns
     32 a pointer to the newly allocated structure.
     33 
     34 RSA_free() returns no value.
     35 
     36 =head1 SEE ALSO
     37 
     38 L<ERR_get_error(3)>,
     39 L<RSA_generate_key(3)>,
     40 L<RSA_new_method(3)>
     41 
     42 =head1 HISTORY
     43 
     44 All functions described here were deprecated in OpenSSL 3.0.
     45 For replacement see EVP_PKEY-RSA(7).
     46 
     47 =head1 COPYRIGHT
     48 
     49 Copyright 2000-2021 The OpenSSL Project Authors. All Rights Reserved.
     50 
     51 Licensed under the Apache License 2.0 (the "License").  You may not use
     52 this file except in compliance with the License.  You can obtain a copy
     53 in the file LICENSE in the source distribution or at
     54 L<https://www.openssl.org/source/license.html>.
     55 
     56 =cut
     57