ASF Bugzilla – Attachment 35204 Details for
Bug 60456
export SSL_CLIENT_SAN_IPaddr variable
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Proposed Patch for SAN IP
patch.txt (text/plain), 1.94 KB, created by
abbotttodd
on 2017-08-07 21:26:28 UTC
(
hide
)
Description:
Proposed Patch for SAN IP
Filename:
MIME Type:
Creator:
abbotttodd
Created:
2017-08-07 21:26:28 UTC
Size:
1.94 KB
patch
obsolete
>diff old\modules\ssl\ssl_engine_vars.c new\modules\ssl\ssl_engine_vars.c >641a642,645 >> else if (strcEQn(var, "IP_", 3)) { >> type = GEN_IPADD; >> var += 3; >> } >1015a1020,1022 >> if (modssl_X509_getSAN(p, xs, GEN_IPADD, NULL, -1, &entries)) { >> extract_san_array(t, "SSL_SERVER_SAN_IP", entries, p); >> } >1030a1038,1040 >> } >> if (modssl_X509_getSAN(p, xs, GEN_IPADD, NULL, -1, &entries)) { >> extract_san_array(t, "SSL_CLIENT_SAN_IP", entries, p); >diff old\modules\ssl\ssl_util_ssl.c new\modules\ssl\ssl_util_ssl.c >214a215,246 >> static char *asn1_ipadd_to_utf8(apr_pool_t *pool, ASN1_OCTET_STRING *ip) >> { >> char *result = NULL; >> int len; >> unsigned char *p; >> char oline[64], htmp[5]; >> int i; >> >> len = 0; >> p = ip->data; >> if (ip->length == 4) >> len += BIO_snprintf(oline, sizeof oline, "%d.%d.%d.%d", p[0], p[1], p[2], p[3]); >> else if (ip->length == 16) { >> oline[0] = 0; >> for (i = 0; i < 8; i++) { >> len += BIO_snprintf(htmp, sizeof htmp, "%x", p[0] << 8 | p[1]); >> p += 2; >> strcat(oline, htmp); >> if (i != 7) { >> strcat(oline, ":"); >> len++; >> } >> } >> } >> if (len > 0) { >> result = apr_palloc(pool, len + 1); >> strncpy(result, oline, len); >> result[len] = NUL; >> } >> return result; >> } >> >329a362,368 >> break; >> case GEN_IPADD: >> if (((idx == -1) || (n == idx)) && >> (utf8str = asn1_ipadd_to_utf8(p, name->d.iPAddress))) { >> APR_ARRAY_PUSH(*entries, const char *) = utf8str; >> } >> n++;
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 60456
: 35204