krb5 commit: Use case insensitive DNS SAN matching in PKINIT

Greg Hudson ghudson at MIT.EDU
Mon May 19 13:46:04 EDT 2014


https://github.com/krb5/krb5/commit/6a77d5e7c8602458e482278195c31cb7a2261232
commit 6a77d5e7c8602458e482278195c31cb7a2261232
Author: Tomas Kuthan <tkuthan at gmail.com>
Date:   Mon May 19 11:37:07 2014 +0200

    Use case insensitive DNS SAN matching in PKINIT
    
    Matching Subject Alternative Name from certificate with
    pkinit_kdc_hostname value from krb5.conf should disregard case.
    
    ticket: 7913 (new)

 src/plugins/preauth/pkinit/pkinit_clnt.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/src/plugins/preauth/pkinit/pkinit_clnt.c b/src/plugins/preauth/pkinit/pkinit_clnt.c
index 2a00370..55b3881 100644
--- a/src/plugins/preauth/pkinit/pkinit_clnt.c
+++ b/src/plugins/preauth/pkinit/pkinit_clnt.c
@@ -570,7 +570,7 @@ verify_kdc_san(krb5_context context,
         for (j = 0; cfghosts != NULL && cfghosts[j] != NULL; j++) {
             pkiDebug("%s: comparing cert name '%s' with config name '%s'\n",
                      __FUNCTION__, certhosts[i], cfghosts[j]);
-            if (strcmp(certhosts[i], cfghosts[j]) == 0) {
+            if (strcasecmp(certhosts[i], cfghosts[j]) == 0) {
                 TRACE_PKINIT_CLIENT_SAN_MATCH_DNSNAME(context, certhosts[i]);
                 pkiDebug("%s: we have a dnsName match\n", __FUNCTION__);
                 *valid_san = 1;


More information about the cvs-krb5 mailing list