X-Git-Url: https://git.openssl.org/gitweb/?a=blobdiff_plain;f=crypto%2Fpkcs7%2Fpkcs7.h;h=f3f85f57afb3c89beb182b812578654ffaa6dac1;hb=7f0606016cbbec917b1fe094b84b062e87abe7da;hp=19f66c6e1e387348ada806f6f32e7b69eb166bd1;hpb=fc6be0fa561f17d237ab1b8801d476a011c14a28;p=openssl.git diff --git a/crypto/pkcs7/pkcs7.h b/crypto/pkcs7/pkcs7.h index 19f66c6e1e..f3f85f57af 100644 --- a/crypto/pkcs7/pkcs7.h +++ b/crypto/pkcs7/pkcs7.h @@ -59,10 +59,6 @@ #ifndef HEADER_PKCS7_H #define HEADER_PKCS7_H -#ifdef __cplusplus -extern "C" { -#endif - #include #include @@ -70,6 +66,10 @@ extern "C" { #include #endif +#ifdef __cplusplus +extern "C" { +#endif + #ifdef WIN32 /* Under Win32 thes are defined in wincrypt.h */ #undef PKCS7_ISSUER_AND_SERIAL @@ -213,6 +213,10 @@ typedef struct pkcs7_st } d; } PKCS7; +DECLARE_STACK_OF(PKCS7) +DECLARE_ASN1_SET_OF(PKCS7) +DECLARE_PKCS12_STACK_OF(PKCS7) + #define PKCS7_OP_SET_DETACHED_SIGNATURE 1 #define PKCS7_OP_GET_DETACHED_SIGNATURE 2 @@ -250,7 +254,7 @@ typedef struct pkcs7_st #define PKCS7_BINARY 0x80 #define PKCS7_NOATTR 0x100 -/* Flags: for compatability with older code */ +/* Flags: for compatibility with older code */ #define SMIME_TEXT PKCS7_TEXT #define SMIME_NOCERTS PKCS7_NOCERTS @@ -397,14 +401,15 @@ PKCS7 *PKCS7_sign(X509 *signcert, EVP_PKEY *pkey, STACK_OF(X509) *certs, BIO *data, int flags); int PKCS7_verify(PKCS7 *p7, STACK_OF(X509) *certs, X509_STORE *store, BIO *indata, BIO *out, int flags); -STACK_OF(X509) *PKCS7_iget_signers(PKCS7 *p7, STACK_OF(X509) *certs, int flags); +STACK_OF(X509) *PKCS7_get0_signers(PKCS7 *p7, STACK_OF(X509) *certs, int flags); PKCS7 *PKCS7_encrypt(STACK_OF(X509) *certs, BIO *in, EVP_CIPHER *cipher, int flags); int PKCS7_decrypt(PKCS7 *p7, EVP_PKEY *pkey, X509 *cert, BIO *data, int flags); -int PKCS7_add_attrib_smimecap(PKCS7_SIGNER_INFO *si, STACK *cap); -STACK *PKCS7_get_smimecap(PKCS7_SIGNER_INFO *si); -int PKCS7_simple_smimecap(STACK *sk, int nid, int arg); +int PKCS7_add_attrib_smimecap(PKCS7_SIGNER_INFO *si, + STACK_OF(X509_ALGOR) *cap); +STACK_OF(X509_ALGOR) *PKCS7_get_smimecap(PKCS7_SIGNER_INFO *si); +int PKCS7_simple_smimecap(STACK_OF(X509_ALGOR) *sk, int nid, int arg); int SMIME_write_PKCS7(BIO *bio, PKCS7 *p7, BIO *data, int flags); PKCS7 *SMIME_read_PKCS7(BIO *bio, BIO **bcont); @@ -433,7 +438,7 @@ int SMIME_text(BIO *in, BIO *out); #define PKCS7_F_PKCS7_DATAVERIFY 107 #define PKCS7_F_PKCS7_DECRYPT 114 #define PKCS7_F_PKCS7_ENCRYPT 115 -#define PKCS7_F_PKCS7_IGET_SIGNERS 124 +#define PKCS7_F_PKCS7_GET0_SIGNERS 124 #define PKCS7_F_PKCS7_SET_CIPHER 108 #define PKCS7_F_PKCS7_SET_CONTENT 109 #define PKCS7_F_PKCS7_SET_TYPE 110