mirror of
https://github.com/apache/httpd.git
synced 2025-08-08 15:02:10 +03:00
mod_ssl: Rename static convert_asn1_to_utf8 function to asn1_string_to_utf8.
Suggested by: kbrand git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1677339 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
@@ -191,7 +191,7 @@ BOOL modssl_X509_getBC(X509 *cert, int *ca, int *pathlen)
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* convert an ASN.1 string to a UTF-8 string (escaping control characters) */
|
/* convert an ASN.1 string to a UTF-8 string (escaping control characters) */
|
||||||
static char *convert_asn1_to_utf8(apr_pool_t *p, ASN1_STRING *asn1str)
|
static char *asn1_string_to_utf8(apr_pool_t *p, ASN1_STRING *asn1str)
|
||||||
{
|
{
|
||||||
char *result = NULL;
|
char *result = NULL;
|
||||||
BIO *bio;
|
BIO *bio;
|
||||||
@@ -215,7 +215,7 @@ static char *convert_asn1_to_utf8(apr_pool_t *p, ASN1_STRING *asn1str)
|
|||||||
/* convert a NAME_ENTRY to UTF8 string */
|
/* convert a NAME_ENTRY to UTF8 string */
|
||||||
char *modssl_X509_NAME_ENTRY_to_string(apr_pool_t *p, X509_NAME_ENTRY *xsne)
|
char *modssl_X509_NAME_ENTRY_to_string(apr_pool_t *p, X509_NAME_ENTRY *xsne)
|
||||||
{
|
{
|
||||||
char *result = convert_asn1_to_utf8(p, X509_NAME_ENTRY_get_data(xsne));
|
char *result = asn1_string_to_utf8(p, X509_NAME_ENTRY_get_data(xsne));
|
||||||
ap_xlate_proto_from_ascii(result, len);
|
ap_xlate_proto_from_ascii(result, len);
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
@@ -282,7 +282,7 @@ BOOL modssl_X509_getSAN(apr_pool_t *p, X509 *x509, int type, int idx,
|
|||||||
switch (type) {
|
switch (type) {
|
||||||
case GEN_EMAIL:
|
case GEN_EMAIL:
|
||||||
case GEN_DNS:
|
case GEN_DNS:
|
||||||
utf8str = convert_asn1_to_utf8(p, name->d.ia5);
|
utf8str = asn1_string_to_utf8(p, name->d.ia5);
|
||||||
if (utf8str) {
|
if (utf8str) {
|
||||||
APR_ARRAY_PUSH(*entries, const char *) = utf8str;
|
APR_ARRAY_PUSH(*entries, const char *) = utf8str;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user