diff options
| author | schwarze <> | 2018-12-22 23:19:53 +0000 |
|---|---|---|
| committer | schwarze <> | 2018-12-22 23:19:53 +0000 |
| commit | f676763e6ddc9cd0f82788e915d5f17476e863df (patch) | |
| tree | 243438e001f6a4b032aedf99bc0a2257268c6315 /src | |
| parent | ba7a4b64b02969dd552716cac5dc545595758c1f (diff) | |
| download | openbsd-f676763e6ddc9cd0f82788e915d5f17476e863df.tar.gz openbsd-f676763e6ddc9cd0f82788e915d5f17476e863df.tar.bz2 openbsd-f676763e6ddc9cd0f82788e915d5f17476e863df.zip | |
Document EVP_PKEY_new_mac_key(3);
from Matt Caswell <matt at openssl dot org>
via OpenSSL commit d45a97f4 Mar 5 17:41:49 2018 +0000.
Diffstat (limited to '')
| -rw-r--r-- | src/lib/libcrypto/man/EVP_PKEY_new.3 | 58 |
1 files changed, 50 insertions, 8 deletions
diff --git a/src/lib/libcrypto/man/EVP_PKEY_new.3 b/src/lib/libcrypto/man/EVP_PKEY_new.3 index fade3d5cd2..777c108d83 100644 --- a/src/lib/libcrypto/man/EVP_PKEY_new.3 +++ b/src/lib/libcrypto/man/EVP_PKEY_new.3 | |||
| @@ -1,8 +1,10 @@ | |||
| 1 | .\" $OpenBSD: EVP_PKEY_new.3,v 1.8 2018/03/27 17:35:50 schwarze Exp $ | 1 | .\" $OpenBSD: EVP_PKEY_new.3,v 1.9 2018/12/22 23:19:53 schwarze Exp $ |
| 2 | .\" full merge up to: OpenSSL 99d63d42 Oct 26 13:56:48 2016 -0400 | 2 | .\" full merge up to: OpenSSL 99d63d46 Oct 26 13:56:48 2016 -0400 |
| 3 | .\" selective merge up to: OpenSSL df75c2bf Dec 9 01:02:36 2018 +0100 | ||
| 3 | .\" | 4 | .\" |
| 4 | .\" This file was written by Dr. Stephen Henson <steve@openssl.org>. | 5 | .\" This file was written by Dr. Stephen Henson <steve@openssl.org> |
| 5 | .\" Copyright (c) 2002 The OpenSSL Project. All rights reserved. | 6 | .\" and Matt Caswell <matt@openssl.org>. |
| 7 | .\" Copyright (c) 2002, 2018 The OpenSSL Project. All rights reserved. | ||
| 6 | .\" | 8 | .\" |
| 7 | .\" Redistribution and use in source and binary forms, with or without | 9 | .\" Redistribution and use in source and binary forms, with or without |
| 8 | .\" modification, are permitted provided that the following conditions | 10 | .\" modification, are permitted provided that the following conditions |
| @@ -48,13 +50,14 @@ | |||
| 48 | .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED | 50 | .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED |
| 49 | .\" OF THE POSSIBILITY OF SUCH DAMAGE. | 51 | .\" OF THE POSSIBILITY OF SUCH DAMAGE. |
| 50 | .\" | 52 | .\" |
| 51 | .Dd $Mdocdate: March 27 2018 $ | 53 | .Dd $Mdocdate: December 22 2018 $ |
| 52 | .Dt EVP_PKEY_NEW 3 | 54 | .Dt EVP_PKEY_NEW 3 |
| 53 | .Os | 55 | .Os |
| 54 | .Sh NAME | 56 | .Sh NAME |
| 55 | .Nm EVP_PKEY_new , | 57 | .Nm EVP_PKEY_new , |
| 56 | .Nm EVP_PKEY_up_ref , | 58 | .Nm EVP_PKEY_up_ref , |
| 57 | .Nm EVP_PKEY_free | 59 | .Nm EVP_PKEY_free , |
| 60 | .Nm EVP_PKEY_new_mac_key | ||
| 58 | .Nd private key allocation functions | 61 | .Nd private key allocation functions |
| 59 | .Sh SYNOPSIS | 62 | .Sh SYNOPSIS |
| 60 | .In openssl/evp.h | 63 | .In openssl/evp.h |
| @@ -68,6 +71,13 @@ | |||
| 68 | .Fo EVP_PKEY_free | 71 | .Fo EVP_PKEY_free |
| 69 | .Fa "EVP_PKEY *key" | 72 | .Fa "EVP_PKEY *key" |
| 70 | .Fc | 73 | .Fc |
| 74 | .Ft EVP_PKEY * | ||
| 75 | .Fo EVP_PKEY_new_mac_key | ||
| 76 | .Fa "int type" | ||
| 77 | .Fa "ENGINE *e" | ||
| 78 | .Fa "const unsigned char *key" | ||
| 79 | .Fa "int keylen" | ||
| 80 | .Fc | ||
| 71 | .Sh DESCRIPTION | 81 | .Sh DESCRIPTION |
| 72 | The | 82 | The |
| 73 | .Vt EVP_PKEY | 83 | .Vt EVP_PKEY |
| @@ -80,7 +90,7 @@ function allocates an empty | |||
| 80 | .Vt EVP_PKEY | 90 | .Vt EVP_PKEY |
| 81 | structure. | 91 | structure. |
| 82 | The reference count is set to 1. | 92 | The reference count is set to 1. |
| 83 | To add a private key to it, use the functions described in | 93 | To add a private or public key to it, use the functions described in |
| 84 | .Xr EVP_PKEY_set1_RSA 3 . | 94 | .Xr EVP_PKEY_set1_RSA 3 . |
| 85 | .Pp | 95 | .Pp |
| 86 | .Fn EVP_PKEY_up_ref | 96 | .Fn EVP_PKEY_up_ref |
| @@ -97,9 +107,37 @@ If | |||
| 97 | is a | 107 | is a |
| 98 | .Dv NULL | 108 | .Dv NULL |
| 99 | pointer, no action occurs. | 109 | pointer, no action occurs. |
| 110 | .Pp | ||
| 111 | .Fn EVP_PKEY_new_mac_key | ||
| 112 | allocates a new | ||
| 113 | .Vt EVP_PKEY . | ||
| 114 | If | ||
| 115 | .Fa e | ||
| 116 | is | ||
| 117 | .Pf non- Dv NULL , | ||
| 118 | then the new | ||
| 119 | .Vt EVP_PKEY | ||
| 120 | structure is associated with the engine | ||
| 121 | .Fa e . | ||
| 122 | The | ||
| 123 | .Fa type | ||
| 124 | argument indicates what kind of key this is. | ||
| 125 | The value should be a NID for a public key algorithm that supports | ||
| 126 | raw private keys, for example | ||
| 127 | .Dv EVP_PKEY_HMAC . | ||
| 128 | .Fa key | ||
| 129 | points to the raw private key data for this | ||
| 130 | .Vt EVP_PKEY | ||
| 131 | which should be of length | ||
| 132 | .Fa keylen . | ||
| 133 | The length should be appropriate for the type of the key. | ||
| 134 | The public key data will be automatically derived from the given | ||
| 135 | private key data (if appropriate for the algorithm type). | ||
| 100 | .Sh RETURN VALUES | 136 | .Sh RETURN VALUES |
| 101 | .Fn EVP_PKEY_new | 137 | .Fn EVP_PKEY_new |
| 102 | returns either the newly allocated | 138 | and |
| 139 | .Fn EVP_PKEY_new_mac_key | ||
| 140 | return either the newly allocated | ||
| 103 | .Vt EVP_PKEY | 141 | .Vt EVP_PKEY |
| 104 | structure or | 142 | structure or |
| 105 | .Dv NULL | 143 | .Dv NULL |
| @@ -117,6 +155,10 @@ and | |||
| 117 | first appeared in SSLeay 0.6.0 and have been available since | 155 | first appeared in SSLeay 0.6.0 and have been available since |
| 118 | .Ox 2.4 . | 156 | .Ox 2.4 . |
| 119 | .Pp | 157 | .Pp |
| 158 | .Fn EVP_PKEY_new_mac_key | ||
| 159 | first appeared in OpenSSL 1.0.0 and has been available since | ||
| 160 | .Ox 4.9 . | ||
| 161 | .Pp | ||
| 120 | .Fn EVP_PKEY_up_ref | 162 | .Fn EVP_PKEY_up_ref |
| 121 | first appeared in OpenSSL 1.1.0 and has been available since | 163 | first appeared in OpenSSL 1.1.0 and has been available since |
| 122 | .Ox 6.3 . | 164 | .Ox 6.3 . |
