diff options
author | Dr. Stephen Henson <steve@openssl.org> | 2008-03-31 15:03:55 +0000 |
---|---|---|
committer | Dr. Stephen Henson <steve@openssl.org> | 2008-03-31 15:03:55 +0000 |
commit | 2e86f0d8d7185993d8cca5158af61d13224c3c26 (patch) | |
tree | 308131c49aba8045da575d2f25c184a21073f96b /crypto/asn1/asn_mime.c | |
parent | e2a29d49ca8548f95ec1b92f2f443f0f9f416a58 (diff) |
Use correct headers for signed receipts. Use consistent naming.
Update cms-test.pl to support OpenSSL 0.9.8.
Diffstat (limited to 'crypto/asn1/asn_mime.c')
-rw-r--r-- | crypto/asn1/asn_mime.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/crypto/asn1/asn_mime.c b/crypto/asn1/asn_mime.c index 9148817210..8fbdf21337 100644 --- a/crypto/asn1/asn_mime.c +++ b/crypto/asn1/asn_mime.c @@ -276,7 +276,7 @@ static int asn1_write_micalg(BIO *out, STACK_OF(X509_ALGOR) *mdalgs) /* SMIME sender */ int SMIME_write_ASN1(BIO *bio, ASN1_VALUE *val, BIO *data, int flags, - int ctype_nid, + int ctype_nid, int econt_nid, STACK_OF(X509_ALGOR) *mdalgs, const ASN1_ITEM *it) { @@ -340,7 +340,9 @@ int SMIME_write_ASN1(BIO *bio, ASN1_VALUE *val, BIO *data, int flags, msg_type = "enveloped-data"; else if (ctype_nid == NID_pkcs7_signed) { - if (sk_X509_ALGOR_num(mdalgs) >= 0) + if (econt_nid == NID_id_smime_ct_receipt) + msg_type = "signed-receipt"; + else if (sk_X509_ALGOR_num(mdalgs) >= 0) msg_type = "signed-data"; else msg_type = "certs-only"; @@ -423,7 +425,7 @@ static int asn1_output_data(BIO *out, BIO *data, ASN1_VALUE *val, int flags, * pointed to by "bcont". In opaque this is set to NULL */ -ASN1_VALUE *SMIME_read_asn1(BIO *bio, BIO **bcont, const ASN1_ITEM *it) +ASN1_VALUE *SMIME_read_ASN1(BIO *bio, BIO **bcont, const ASN1_ITEM *it) { BIO *asnin; STACK_OF(MIME_HEADER) *headers = NULL; |