From f606520095236e8dabb85564d3e91361e0b57b6e Mon Sep 17 00:00:00 2001 From: Ingela Anderton Andin Date: Fri, 31 Mar 2017 15:38:53 +0200 Subject: public_key: Public RSA key is present in private key Change the return value from {#'RSAPublicKey'{}, #'RSAPrivateKey'{}} to #'RSAPrivateKey'{} This conforms to the #'ECPrivateKey'{} return value. Note that DH key will be returned as {Public::integer(), Private::integer()} as there is no key structure (record) only two integers. Maybe we would like to add extraction functions for the public key from the private ones later. --- lib/public_key/doc/src/public_key.xml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'lib/public_key/doc') diff --git a/lib/public_key/doc/src/public_key.xml b/lib/public_key/doc/src/public_key.xml index 2300ce3937..940585575c 100644 --- a/lib/public_key/doc/src/public_key.xml +++ b/lib/public_key/doc/src/public_key.xml @@ -331,14 +331,15 @@ - generate_key(Params) -> {Public::binary(), Private::binary()} | #'ECPrivateKey'{} | {#'RSAPublicKey'{}, #'RSAPrivateKey'{}} + generate_key(Params) -> {Public::binary(), Private::binary()} | #'ECPrivateKey'{} | #'RSAPrivateKey'{} Generates a new keypair. Params = #'DHParameter'{} | {namedCurve, oid()} | #'ECParameters'{} | {rsa, Size::integer(), PubExp::integer} -

Generates a new keypair. See also +

Generates a new keypair. Note that except for Diffie-Hellman + the public key is included in the private key structure. See also crypto:generate_key/2

-- cgit v1.2.3