Merge pull request #1214 from aria2/fix-gnutls-empty-cn-bug

gnutls: Fix bug that commonName is always empty
pull/1236/head
Tatsuhiro Tsujikawa 2018-06-05 22:14:49 +09:00 committed by GitHub
commit eb30bb1a52
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 0 deletions

View File

@ -341,6 +341,9 @@ int GnuTLSSession::tlsConnect(const std::string& hostname, TLSVersion& version,
commonName.assign(altName, altNameLen);
}
}
else {
commonName.assign(altName, altNameLen);
}
}
}
if (!net::verifyHostname(hostname, dnsNames, ipAddrs, commonName)) {