diff options
| author | Linus Nordberg <linus@nordu.net> | 2016-08-31 15:58:57 +0200 | 
|---|---|---|
| committer | Linus Nordberg <linus@nordu.net> | 2016-09-21 13:15:11 +0200 | 
| commit | c206fc83904a441fa016bfe653fc20afd4cd6b8f (patch) | |
| tree | b7db7cde085785a971418a997610d77c142520c3 | |
| parent | 00a6c67786a0716749e0cbb1600dd1dbc54d693f (diff) | |
ASN1_STRING_data() -> ASN1_STRING_get0_data().
ASN1_STRING_data was deprecated in openssl-1.1, see
https://www.openssl.org/docs/manmaster/crypto/ASN1_STRING_data.html
| -rw-r--r-- | tlscommon.c | 6 | 
1 files changed, 3 insertions, 3 deletions
| diff --git a/tlscommon.c b/tlscommon.c index 157296b..843ae44 100644 --- a/tlscommon.c +++ b/tlscommon.c @@ -375,7 +375,7 @@ static int subjectaltnameaddr(X509 *cert, int family, struct in6_addr *addr) {  	if (gn->type != GEN_IPADD)  	    continue;  	r = -1; -	v = (char *)ASN1_STRING_data(gn->d.ia5); +	v = (char *)ASN1_STRING_get0_data(gn->d.ia5);  	l = ASN1_STRING_length(gn->d.ia5);  	if (((family == AF_INET && l == sizeof(struct in_addr)) || (family == AF_INET6 && l == sizeof(struct in6_addr)))  	    && !memcmp(v, &addr, l)) { @@ -411,7 +411,7 @@ static int subjectaltnameregexp(X509 *cert, int type, char *exact,  regex_t *reg  	if (gn->type != type)  	    continue;  	r = -1; -	v = (char *)ASN1_STRING_data(gn->d.ia5); +	v = (char *)ASN1_STRING_get0_data(gn->d.ia5);  	l = ASN1_STRING_length(gn->d.ia5);  	if (l <= 0)  	    continue; @@ -455,7 +455,7 @@ static int cnregexp(X509 *cert, char *exact, regex_t *regex) {  	    break;  	e = X509_NAME_get_entry(nm, loc);  	t = X509_NAME_ENTRY_get_data(e); -	v = (char *) ASN1_STRING_data(t); +	v = (char *) ASN1_STRING_get0_data(t);  	l = ASN1_STRING_length(t);  	if (l < 0)  	    continue; | 
