aboutsummaryrefslogtreecommitdiffstats
path: root/lib/public_key/doc/src/public_key.xml
diff options
context:
space:
mode:
Diffstat (limited to 'lib/public_key/doc/src/public_key.xml')
-rw-r--r--lib/public_key/doc/src/public_key.xml21
1 files changed, 14 insertions, 7 deletions
diff --git a/lib/public_key/doc/src/public_key.xml b/lib/public_key/doc/src/public_key.xml
index c72719fac4..91e058f74e 100644
--- a/lib/public_key/doc/src/public_key.xml
+++ b/lib/public_key/doc/src/public_key.xml
@@ -64,8 +64,8 @@
<p><c>decrypt_der() = binary() </c></p>
- <p><c>pki_asn1_type() = 'Certificate' | 'RSAPrivateKey'|
- 'DSAPrivateKey' | 'DHParameter'</c></p>
+ <p><c>pki_asn1_type() = 'Certificate' | 'RSAPrivateKey'| 'RSAPublicKey'
+ 'DSAPrivateKey' | 'DSAPublicKey' | 'DHParameter' | 'SubjectPublicKeyInfo'</c></p>
<p><c>pem_entry () = {pki_asn1_type(), der_encoded() | decrypt_der(), not_encrypted |
{"DES-CBC" | "DES-EDE3-CBC", crypto:rand_bytes(8)}}.</c></p>
@@ -207,17 +207,24 @@
<v> Password = string() </v>
</type>
<desc>
- <p>Decodes a pem entry. pem_decode/1 returns a list of
- pem entries.</p>
+ <p>Decodes a pem entry. pem_decode/1 returns a list of pem
+ entries. Note that if the pem entry is of type
+ 'SubjectPublickeyInfo' it will be further decoded to an
+ rsa_public_key() or dsa_public_key().</p>
</desc>
</func>
<func>
<name>pem_entry_encode(Asn1Type, Entity [,{CipherInfo, Password}]) -> pem_entry()</name>
- <fsummary> Creates a pem entry that can be feed to pem_encode/1.</fsummary>
+ <fsummary> Creates a pem entry that can be fed to pem_encode/1.</fsummary>
<type>
- <v>Asn1Type = atom()</v>
- <v>Entity = term()</v>
+ <v>Asn1Type = pki_asn1_type()</v>
+ <v>Entity = term() - The Erlang representation of
+ <c>Asn1Type</c>. If <c>Asn1Type</c> is 'SubjectPublicKeyInfo'
+ then <c>Entity</c> must be either an rsa_public_key() or a
+ dsa_public_key() and this function will create the appropriate
+ 'SubjectPublicKeyInfo' entry.
+ </v>
<v>CipherInfo = {"DES-CBC" | "DES-EDE3-CBC", crypto:rand_bytes(8)}</v>
<v>Password = string()</v>
</type>