dnsNames = dnsNames.concat(uriNames);
// And only after check if hostname matches CN
+ // (because CN is deprecated, but should be used for compatiblity anyway)
var commonNames = cert.subject.CN;
if (Array.isArray(commonNames)) {
for (var i = 0, k = commonNames.length; i < k; ++i) {
- dnsNames.push(regexpify(commonNames[i], true));
+ dnsNames.push(regexpify(commonNames[i], false));
}
} else {
- dnsNames.push(regexpify(commonNames, true));
+ dnsNames.push(regexpify(commonNames, false));
}
valid = dnsNames.some(function(re) {