aboutsummaryrefslogtreecommitdiffstats
path: root/crypto/x509v3
diff options
context:
space:
mode:
authorDr. Stephen Henson <steve@openssl.org>2016-08-16 14:06:48 +0100
committerDr. Stephen Henson <steve@openssl.org>2016-08-16 16:05:35 +0100
commit17ebf85abda18c3875b1ba6670fe7b393bc1f297 (patch)
tree224f98559daf13f77b4526df0a24a3ab1675f685 /crypto/x509v3
parent1940aa6e6b51147df10a5bffcaaa2b9904209184 (diff)
downloadopenssl-17ebf85abda18c3875b1ba6670fe7b393bc1f297.tar.gz
Add ASN1_STRING_get0_data(), deprecate ASN1_STRING_data().
Deprecate the function ASN1_STRING_data() and replace with a new function ASN1_STRING_get0_data() which returns a constant pointer. Update library to use new function. Reviewed-by: Rich Salz <rsalz@openssl.org>
Diffstat (limited to 'crypto/x509v3')
-rw-r--r--crypto/x509v3/v3_lib.c2
-rw-r--r--crypto/x509v3/v3_prn.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/crypto/x509v3/v3_lib.c b/crypto/x509v3/v3_lib.c
index 25d019e684..a3ca720fe1 100644
--- a/crypto/x509v3/v3_lib.c
+++ b/crypto/x509v3/v3_lib.c
@@ -203,7 +203,7 @@ void *X509V3_EXT_d2i(X509_EXTENSION *ext)
if ((method = X509V3_EXT_get(ext)) == NULL)
return NULL;
extvalue = X509_EXTENSION_get_data(ext);
- p = ASN1_STRING_data(extvalue);
+ p = ASN1_STRING_get0_data(extvalue);
extlen = ASN1_STRING_length(extvalue);
if (method->it)
return ASN1_item_d2i(NULL, &p, extlen, ASN1_ITEM_ptr(method->it));
diff --git a/crypto/x509v3/v3_prn.c b/crypto/x509v3/v3_prn.c
index 3048b67588..4b1d0c3b5e 100644
--- a/crypto/x509v3/v3_prn.c
+++ b/crypto/x509v3/v3_prn.c
@@ -79,7 +79,7 @@ int X509V3_EXT_print(BIO *out, X509_EXTENSION *ext, unsigned long flag,
int ok = 1;
extoct = X509_EXTENSION_get_data(ext);
- p = ASN1_STRING_data(extoct);
+ p = ASN1_STRING_get0_data(extoct);
extlen = ASN1_STRING_length(extoct);
if ((method = X509V3_EXT_get(ext)) == NULL)