diff options
author | Jon Spillett <jon.spillett@oracle.com> | 2019-09-02 14:51:05 +1000 |
---|---|---|
committer | Tomas Mraz <tmraz@fedoraproject.org> | 2019-11-12 18:14:31 +0100 |
commit | eb389a75c0e893a3a9951ddc804459713dbf5d3d (patch) | |
tree | 3423e1385caf1b8712622abc0872f42b59c2d069 /doc | |
parent | 40fa9d9ef7c05ea355067865c655653c663f03c8 (diff) |
Add missing docs for some PKCS12 functions
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Tomas Mraz <tmraz@fedoraproject.org>
(Merged from https://github.com/openssl/openssl/pull/9752)
Diffstat (limited to 'doc')
-rw-r--r-- | doc/man3/PKCS12_SAFEBAG_get0_attrs.pod | 50 | ||||
-rw-r--r-- | doc/man3/PKCS12_add_CSPName_asc.pod | 36 | ||||
-rw-r--r-- | doc/man3/PKCS12_add_friendlyname_asc.pod | 52 | ||||
-rw-r--r-- | doc/man3/PKCS12_add_localkeyid.pod | 38 | ||||
-rw-r--r-- | doc/man3/PKCS12_get_friendlyname.pod | 39 |
5 files changed, 215 insertions, 0 deletions
diff --git a/doc/man3/PKCS12_SAFEBAG_get0_attrs.pod b/doc/man3/PKCS12_SAFEBAG_get0_attrs.pod new file mode 100644 index 0000000000..9fd3b78699 --- /dev/null +++ b/doc/man3/PKCS12_SAFEBAG_get0_attrs.pod @@ -0,0 +1,50 @@ +=pod + +=head1 NAME + +PKCS12_SAFEBAG_get0_attrs, PKCS12_get_attr_gen - Retrieve attributes from a PKCS#12 safeBag + +=head1 SYNOPSIS + + #include <openssl/pkcs12.h> + + const STACK_OF(X509_ATTRIBUTE) *PKCS12_SAFEBAG_get0_attrs(const PKCS12_SAFEBAG *bag); + + ASN1_TYPE *PKCS12_get_attr_gen(const STACK_OF(X509_ATTRIBUTE) *attrs, + int attr_nid) + +=head1 DESCRIPTION + +PKCS12_SAFEBAG_get0_attrs() retrieves the stack of B<X509_ATTRIBUTE>s from a +PKCS#12 safeBag. I<bag> is the B<PKCS12_SAFEBAG> to retrieve the attributes from. + +PKCS12_get_attr_gen() retrieves an attribute by NID from a stack of +B<X509_ATTRIBUTE>s. I<attr_nid> is the NID of the attribute to retrieve. + +=head1 RETURN VALUES + +PKCS12_SAFEBAG_get0_attrs() returns the stack of B<X509_ATTRIBUTE>s from a +PKCS#12 safeBag, which could be empty. + +PKCS12_get_attr_gen() returns an B<ASN1_TYPE> object containing the attribute, +or NULL if the attribute was either not present or an error occurred. + +PKCS12_get_attr_gen() does not allocate a new attribute. The returned attribute +is still owned by the B<PKCS12_SAFEBAG> in which it resides. + +=head1 SEE ALSO + +L<PKCS12_get_friendlyname(3)>, +L<PKCS12_get_localkeyid(3)>, +L<PKCS12_add_friendlyname_asc(3)> + +=head1 COPYRIGHT + +Copyright 2019 The OpenSSL Project Authors. All Rights Reserved. + +Licensed under the Apache License 2.0 (the "License"). You may not use +this file except in compliance with the License. You can obtain a copy +in the file LICENSE in the source distribution or at +L<https://www.openssl.org/source/license.html>. + +=cut diff --git a/doc/man3/PKCS12_add_CSPName_asc.pod b/doc/man3/PKCS12_add_CSPName_asc.pod new file mode 100644 index 0000000000..87d9e71302 --- /dev/null +++ b/doc/man3/PKCS12_add_CSPName_asc.pod @@ -0,0 +1,36 @@ +=pod + +=head1 NAME + +PKCS12_add_CSPName_asc - Add a Microsoft CSP Name attribute to a PKCS#12 safeBag + +=head1 SYNOPSIS + + #include <openssl/pkcs12.h> + + int PKCS12_add_CSPName_asc(PKCS12_SAFEBAG *bag, const char *name, int namelen); + +=head1 DESCRIPTION + +PKCS12_add_CSPName_asc() adds an ASCII string representation of the Microsoft CSP Name attribute to a PKCS#12 safeBag. + +I<bag> is the B<PKCS12_SAFEBAG> to add the attribute to. + +=head1 RETURN VALUES + +Returns 1 for success or 0 for failure. + +=head1 SEE ALSO + +L<PKCS12_add_friendlyname_asc(3)> + +=head1 COPYRIGHT + +Copyright 2019 The OpenSSL Project Authors. All Rights Reserved. + +Licensed under the Apache License 2.0 (the "License"). You may not use +this file except in compliance with the License. You can obtain a copy +in the file LICENSE in the source distribution or at +L<https://www.openssl.org/source/license.html>. + +=cut diff --git a/doc/man3/PKCS12_add_friendlyname_asc.pod b/doc/man3/PKCS12_add_friendlyname_asc.pod new file mode 100644 index 0000000000..3920b5daa0 --- /dev/null +++ b/doc/man3/PKCS12_add_friendlyname_asc.pod @@ -0,0 +1,52 @@ +=pod + +=head1 NAME + +PKCS12_add_friendlyname_asc, PKCS12_add_friendlyname_utf8, +PKCS12_add_friendlyname_uni - Functions to add the friendlyname attribute to a +PKCS#12 safeBag + +=head1 SYNOPSIS + + #include <openssl/pkcs12.h> + + int PKCS12_add_friendlyname_asc(PKCS12_SAFEBAG *bag, const char *name, + int namelen); + + int PKCS12_add_friendlyname_utf8(PKCS12_SAFEBAG *bag, const char *name, + int namelen); + + int PKCS12_add_friendlyname_uni(PKCS12_SAFEBAG *bag, + const unsigned char *name, int namelen); + +=head1 DESCRIPTION + +PKCS12_add_friendlyname_asc() adds an ASCII string representation of the PKCS#9 +friendlyName attribute to a PKCS#12 safeBag. + +PKCS12_add_friendlyname_utf8() adds a UTF-8 string representation of the PKCS#9 +friendlyName attribute to a PKCS#12 safeBag. + +PKCS12_add_friendlyname_uni() adds a Unicode string representation of the PKCS#9 +friendlyName attribute to a PKCS#12 safeBag. + +I<bag> is the B<PKCS12_SAFEBAG> to add the attribute to. + +=head1 RETURN VALUES + +Returns 1 for success or 0 for failure. + +=head1 SEE ALSO + +L<PKCS12_get_friendlyname(3)> + +=head1 COPYRIGHT + +Copyright 2019 The OpenSSL Project Authors. All Rights Reserved. + +Licensed under the Apache License 2.0 (the "License"). You may not use +this file except in compliance with the License. You can obtain a copy +in the file LICENSE in the source distribution or at +L<https://www.openssl.org/source/license.html>. + +=cut diff --git a/doc/man3/PKCS12_add_localkeyid.pod b/doc/man3/PKCS12_add_localkeyid.pod new file mode 100644 index 0000000000..6d9ff9883e --- /dev/null +++ b/doc/man3/PKCS12_add_localkeyid.pod @@ -0,0 +1,38 @@ +=pod + +=head1 NAME + +PKCS12_add_localkeyid - Add the localKeyId attribute to a PKCS#12 safeBag + +=head1 SYNOPSIS + + #include <openssl/pkcs12.h> + + int PKCS12_add_localkeyid(PKCS12_SAFEBAG *bag, const char *name, + int namelen); + +=head1 DESCRIPTION + +PKCS12_add_localkeyid() adds an octet string representation of the PKCS#9 +localKeyId attribute to a PKCS#12 safeBag. + +I<bag> is the B<PKCS12_SAFEBAG> to add the attribute to. + +=head1 RETURN VALUES + +Returns 1 for success or 0 for failure. + +=head1 SEE ALSO + +L<PKCS12_add_friendlyname_asc(3)> + +=head1 COPYRIGHT + +Copyright 2019 The OpenSSL Project Authors. All Rights Reserved. + +Licensed under the Apache License 2.0 (the "License"). You may not use +this file except in compliance with the License. You can obtain a copy +in the file LICENSE in the source distribution or at +L<https://www.openssl.org/source/license.html>. + +=cut diff --git a/doc/man3/PKCS12_get_friendlyname.pod b/doc/man3/PKCS12_get_friendlyname.pod new file mode 100644 index 0000000000..e96f7a255a --- /dev/null +++ b/doc/man3/PKCS12_get_friendlyname.pod @@ -0,0 +1,39 @@ +=pod + +=head1 NAME + +PKCS12_get_friendlyname - Retrieve the friendlyname attribute from a PKCS#12 safeBag + +=head1 SYNOPSIS + + #include <openssl/pkcs12.h> + + char *PKCS12_get_friendlyname(PKCS12_SAFEBAG *bag); + +=head1 DESCRIPTION + +PKCS12_get_friendlyname() retrieves a UTF-8 string representation of the PKCS#9 +friendlyName attribute for a PKCS#12 safeBag item. + +I<bag> is the B<PKCS12_SAFEBAG> to retrieve the attribute from. + +=head1 RETURN VALUES + +A UTF-8 string, or NULL if the attribute was either not present or an error occurred. + +The returned string is allocated by OpenSSL and should be freed by the user. + +=head1 SEE ALSO + +L<PKCS12_add_friendlyname_asc(3)> + +=head1 COPYRIGHT + +Copyright 2019 The OpenSSL Project Authors. All Rights Reserved. + +Licensed under the Apache License 2.0 (the "License"). You may not use +this file except in compliance with the License. You can obtain a copy +in the file LICENSE in the source distribution or at +L<https://www.openssl.org/source/license.html>. + +=cut |