summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorFedor Indutny <fedor.indutny@gmail.com>2012-07-20 21:43:12 +0400
committerFedor Indutny <fedor.indutny@gmail.com>2012-07-20 21:43:12 +0400
commit50122fed8ae29c982fa4c806136c4b24dd2de382 (patch)
tree9f4a5408f5d72eb9ccda41be58fd80690fc47beb /lib
parent5950db197c5ee73922beb67e3b8c060b5fcbc7f7 (diff)
downloadandroid-node-v8-50122fed8ae29c982fa4c806136c4b24dd2de382.tar.gz
android-node-v8-50122fed8ae29c982fa4c806136c4b24dd2de382.tar.bz2
android-node-v8-50122fed8ae29c982fa4c806136c4b24dd2de382.zip
tls: fix 'hostless' tls connection verification
And fix last failing tests
Diffstat (limited to 'lib')
-rw-r--r--lib/tls.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/tls.js b/lib/tls.js
index 584ee0a5b9..089ad9bab9 100644
--- a/lib/tls.js
+++ b/lib/tls.js
@@ -1208,7 +1208,7 @@ exports.connect = function(/* [port, host], options, cb */) {
var sslcontext = crypto.createCredentials(options);
convertNPNProtocols(options.NPNProtocols, this);
- var hostname = options.servername || options.host,
+ var hostname = options.servername || options.host || 'localhost',
pair = new SecurePair(sslcontext, false, true,
options.rejectUnauthorized === true ? true : false,
{