crypto: provide full cert details to checkServerIdentity

PR-URL: https://github.com/nodejs/node/pull/17690
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
This commit is contained in:
Hannes Magnusson
2017-12-14 15:45:44 -08:00
committed by Ruben Bridgewater
parent 5a6beb7741
commit 853f0bdf19

View File

@@ -1055,7 +1055,7 @@ function onConnectSecure() {
options.host ||
(options.socket && options.socket._host) ||
'localhost';
const cert = this.getPeerCertificate();
const cert = this.getPeerCertificate(true);
verifyError = options.checkServerIdentity(hostname, cert);
}