New function to initialize a PKCS7 structure of type other.
authorDr. Stephen Henson <steve@openssl.org>
Fri, 10 Oct 2003 23:40:47 +0000 (23:40 +0000)
committerDr. Stephen Henson <steve@openssl.org>
Fri, 10 Oct 2003 23:40:47 +0000 (23:40 +0000)
CHANGES
crypto/pkcs7/pk7_lib.c
crypto/pkcs7/pkcs7.h

diff --git a/CHANGES b/CHANGES
index da17895eb43bbbe63ea035cdb7033d4c59bb4104..51bfd320d2811fc3d480686c27ccb46f9f103836 100644 (file)
--- a/CHANGES
+++ b/CHANGES
@@ -4,6 +4,13 @@
 
  Changes between 0.9.7c and 0.9.8  [xx XXX xxxx]
 
+  *) New function PKCS7_set0_type_other() this initializes a PKCS7 
+     structure of type "other".
+     [Steve Henson]
+
+  *) Correctly initialize digested data content type in PKCS7_set_type().
+     [Steve Henson]
+
   *) Fix prime generation loop in crypto/bn/bn_prime.pl by making
      sure the loop does correctly stop and breaking ("division by zero")
      modulus operations are not performed. The (pre-generated) prime
index 3812710618c69905087449bc98d503e374cee0bf..f71be082ed018f519136caeeb1f1ad9316753c10 100644 (file)
@@ -211,6 +211,13 @@ err:
        return(0);
        }
 
+int PKCS7_set0_type_other(PKCS7 *p7, int type, ASN1_TYPE *other)
+       {
+       p7->type = OBJ_nid2obj(type);
+       p7->d.other = other;
+       return 1;
+       }
+
 int PKCS7_add_signer(PKCS7 *p7, PKCS7_SIGNER_INFO *psi)
        {
        int i,j,nid;
index ab04d352abf702bde6daba52241732e76ebe3d69..d9b3c189cc3c9a3f34ca779c02f7af5a84c4aca1 100644 (file)
@@ -308,6 +308,7 @@ DECLARE_ASN1_NDEF_FUNCTION(PKCS7)
 long PKCS7_ctrl(PKCS7 *p7, int cmd, long larg, char *parg);
 
 int PKCS7_set_type(PKCS7 *p7, int type);
+int PKCS7_set0_type_other(PKCS7 *p7, int type, ASN1_TYPE *other);
 int PKCS7_set_content(PKCS7 *p7, PKCS7 *p7_data);
 int PKCS7_SIGNER_INFO_set(PKCS7_SIGNER_INFO *p7i, X509 *x509, EVP_PKEY *pkey,
        const EVP_MD *dgst);