Changeset f06c148 in mod_gnutls


Ignore:
Timestamp:
Nov 2, 2018, 1:30:33 PM (2 months ago)
Author:
Fiona Klute <fiona.klute@…>
Branches:
master
Children:
4e388b0
Parents:
6d8c00c
Message:

Simplify wildcard match for virtual host aliases

Files:
2 edited

Legend:

Unmodified
Added
Removed
  • include/mod_gnutls.h.in

    r6d8c00c rf06c148  
    2828#include "apr_tables.h"
    2929#include "ap_release.h"
    30 #include "apr_fnmatch.h"
    3130/* GnuTLS Library Headers */
    3231#include <gnutls/gnutls.h>
  • src/gnutls_hooks.c

    r6d8c00c rf06c148  
    897897            }
    898898        }
    899         /* Wild any ServerAlias Directives */
     899        /* ServerAlias directives may contain wildcards, check those last. */
    900900    } else if(s->wild_names->nelts) {
    901901        names = s->wild_names;
    902         name = (char **)names->elts;
     902        name = (char **) names->elts;
    903903        for (int i = 0; i < names->nelts; ++i)
    904904        {
    905             if (!name[i]) { continue; }
    906             if(apr_fnmatch(name[i], x->sni_name ,
    907                            APR_FNM_CASE_BLIND|
    908                            APR_FNM_PERIOD|
    909                            APR_FNM_PATHNAME|
    910                            APR_FNM_NOESCAPE) == APR_SUCCESS) {
     905            if (!name[i])
     906                continue;
     907            if (ap_strcasecmp_match(x->sni_name, name[i]) == 0)
     908            {
    911909                x->sc = tsc;
    912910                rv = 1;
Note: See TracChangeset for help on using the changeset viewer.