summaryrefslogtreecommitdiffstats
path: root/crypto
diff options
context:
space:
mode:
authornectar <nectar@FreeBSD.org>2004-04-05 19:01:57 +0000
committernectar <nectar@FreeBSD.org>2004-04-05 19:01:57 +0000
commite0710a2e7152b5c0bf1f7bcec11e951eebca301c (patch)
treea5150f9ddb2a1d1ae056548d321d29a7a7369f0f /crypto
parent4bcffa477abc105d171b44d8ff449a0b4640b5b7 (diff)
parent4f072b64b04de8c02478d60870f51a58946761e3 (diff)
downloadFreeBSD-src-e0710a2e7152b5c0bf1f7bcec11e951eebca301c.zip
FreeBSD-src-e0710a2e7152b5c0bf1f7bcec11e951eebca301c.tar.gz
This commit was generated by cvs2svn to compensate for changes in r127904,
which included commits to RCS files with non-trunk default branches.
Diffstat (limited to 'crypto')
-rw-r--r--crypto/openssl/crypto/pkcs7/pk7_doit.c13
1 files changed, 9 insertions, 4 deletions
diff --git a/crypto/openssl/crypto/pkcs7/pk7_doit.c b/crypto/openssl/crypto/pkcs7/pk7_doit.c
index 35c7dcd..b78e228 100644
--- a/crypto/openssl/crypto/pkcs7/pk7_doit.c
+++ b/crypto/openssl/crypto/pkcs7/pk7_doit.c
@@ -257,10 +257,15 @@ BIO *PKCS7_dataInit(PKCS7 *p7, BIO *bio)
bio=BIO_new(BIO_s_null());
else
{
- ASN1_OCTET_STRING *os;
- os = PKCS7_get_octet_string(p7->d.sign->contents);
- if (os && os->length > 0)
- bio = BIO_new_mem_buf(os->data, os->length);
+ if (PKCS7_type_is_signed(p7))
+ {
+ ASN1_OCTET_STRING *os;
+ os = PKCS7_get_octet_string(
+ p7->d.sign->contents);
+ if (os && os->length > 0)
+ bio = BIO_new_mem_buf(os->data,
+ os->length);
+ }
if(bio == NULL)
{
bio=BIO_new(BIO_s_mem());
OpenPOWER on IntegriCloud