diff options
author | Ingela Anderton Andin <[email protected]> | 2012-11-16 10:25:55 +0100 |
---|---|---|
committer | Ingela Anderton Andin <[email protected]> | 2012-11-16 10:25:55 +0100 |
commit | 9aa4de3c97b98974f32c2b8e07c971343faf3f13 (patch) | |
tree | 19e1b2574a6d27f32c59a343049abfa1ebd41809 /lib/public_key/src/pubkey_pem.erl | |
parent | 7a637b67d2c97ed682fb338f66ec9aabbf8d47c9 (diff) | |
parent | 1180643da5bedf3b3b50ef9c25c361c1c2be7316 (diff) | |
download | otp-9aa4de3c97b98974f32c2b8e07c971343faf3f13.tar.gz otp-9aa4de3c97b98974f32c2b8e07c971343faf3f13.tar.bz2 otp-9aa4de3c97b98974f32c2b8e07c971343faf3f13.zip |
Merge branch 'ia/public_key/Additional-PKCS-support/OTP-10509' into maint
* ia/public_key/Additional-PKCS-support/OTP-10509:
Prepare for release
public_key: Add PKCS-10 documentation and PKCS-7 test case
public_key: Simplified PKCS-7 and PKCS-10 specs.
public_key: Added PKCS-10
public_key: Modified PKCS-7.asn1, removing unnecessary IMPORTS.
public_key: Add PKCS-7
Diffstat (limited to 'lib/public_key/src/pubkey_pem.erl')
-rw-r--r-- | lib/public_key/src/pubkey_pem.erl | 19 |
1 files changed, 16 insertions, 3 deletions
diff --git a/lib/public_key/src/pubkey_pem.erl b/lib/public_key/src/pubkey_pem.erl index 910473d629..4012825f20 100644 --- a/lib/public_key/src/pubkey_pem.erl +++ b/lib/public_key/src/pubkey_pem.erl @@ -1,7 +1,7 @@ %% %% %CopyrightBegin% %% -%% Copyright Ericsson AB 2008-2011. All Rights Reserved. +%% Copyright Ericsson AB 2008-2012. All Rights Reserved. %% %% The contents of this file are subject to the Erlang Public License, %% Version 1.1, (the "License"); you may not use this file except in @@ -194,7 +194,12 @@ pem_start('SubjectPublicKeyInfo') -> pem_start('DSAPrivateKey') -> <<"-----BEGIN DSA PRIVATE KEY-----">>; pem_start('DHParameter') -> - <<"-----BEGIN DH PARAMETERS-----">>. + <<"-----BEGIN DH PARAMETERS-----">>; +pem_start('CertificationRequest') -> + <<"-----BEGIN CERTIFICATE REQUEST-----">>; +pem_start('ContentInfo') -> + <<"-----BEGIN PKCS7-----">>. + pem_end(<<"-----BEGIN CERTIFICATE-----">>) -> <<"-----END CERTIFICATE-----">>; pem_end(<<"-----BEGIN RSA PRIVATE KEY-----">>) -> @@ -211,6 +216,10 @@ pem_end(<<"-----BEGIN PRIVATE KEY-----">>) -> <<"-----END PRIVATE KEY-----">>; pem_end(<<"-----BEGIN ENCRYPTED PRIVATE KEY-----">>) -> <<"-----END ENCRYPTED PRIVATE KEY-----">>; +pem_end(<<"-----BEGIN CERTIFICATE REQUEST-----">>) -> + <<"-----END CERTIFICATE REQUEST-----">>; +pem_end(<<"-----BEGIN PKCS7-----">>) -> + <<"-----END PKCS7-----">>; pem_end(_) -> undefined. @@ -229,7 +238,11 @@ asn1_type(<<"-----BEGIN DH PARAMETERS-----">>) -> asn1_type(<<"-----BEGIN PRIVATE KEY-----">>) -> 'PrivateKeyInfo'; asn1_type(<<"-----BEGIN ENCRYPTED PRIVATE KEY-----">>) -> - 'EncryptedPrivateKeyInfo'. + 'EncryptedPrivateKeyInfo'; +asn1_type(<<"-----BEGIN CERTIFICATE REQUEST-----">>) -> + 'CertificationRequest'; +asn1_type(<<"-----BEGIN PKCS7-----">>) -> + 'ContentInfo'. pem_decrypt() -> <<"Proc-Type: 4,ENCRYPTED">>. |