]>
Commit | Line | Data |
---|---|---|
2186cd8e UM |
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 | ||
e9b77246 | 11 | RSA *RSA_new(void); |
2186cd8e UM |
12 | |
13 | void RSA_free(RSA *rsa); | |
14 | ||
15 | =head1 DESCRIPTION | |
16 | ||
ac120e20 GT |
17 | RSA_new() allocates and initializes an B<RSA> structure. It is equivalent to |
18 | calling RSA_new_method(NULL). | |
2186cd8e UM |
19 | |
20 | RSA_free() frees the B<RSA> structure and its components. The key is | |
60b52453 | 21 | erased before the memory is returned to the system. |
d6407083 | 22 | If B<rsa> is NULL nothing is done. |
2186cd8e UM |
23 | |
24 | =head1 RETURN VALUES | |
25 | ||
26 | If the allocation fails, RSA_new() returns B<NULL> and sets an error | |
9b86974e | 27 | code that can be obtained by L<ERR_get_error(3)>. Otherwise it returns |
2186cd8e UM |
28 | a pointer to the newly allocated structure. |
29 | ||
30 | RSA_free() returns no value. | |
31 | ||
32 | =head1 SEE ALSO | |
33 | ||
53934822 | 34 | L<ERR_get_error(3)>, |
9b86974e RS |
35 | L<RSA_generate_key(3)>, |
36 | L<RSA_new_method(3)> | |
2186cd8e | 37 | |
e2f92610 RS |
38 | =head1 COPYRIGHT |
39 | ||
40 | Copyright 2000-2016 The OpenSSL Project Authors. All Rights Reserved. | |
41 | ||
42 | Licensed under the OpenSSL license (the "License"). You may not use | |
43 | this file except in compliance with the License. You can obtain a copy | |
44 | in the file LICENSE in the source distribution or at | |
45 | L<https://www.openssl.org/source/license.html>. | |
46 | ||
47 | =cut |