diff --git a/lib/goldilocks.js b/lib/goldilocks.js index 84efc70..7a0d377 100644 --- a/lib/goldilocks.js +++ b/lib/goldilocks.js @@ -359,8 +359,10 @@ module.exports.create = function (deps, config) { try { reader._remoteAddress = wrapOpts.remoteAddress; reader._remotePort = wrapOpts.remotePort; + reader._remoteFamily = wrapOpts.remoteFamily; reader._localAddress = wrapOpts.localAddress; reader._localPort = wrapOpts.localPort; + reader._localFamily = wrapOpts.localFamily; } catch(e) { } @@ -440,8 +442,9 @@ module.exports.create = function (deps, config) { servername: tlsSocket.servername , encrypted: true // remoteAddress... ugh... https://github.com/nodejs/node/issues/8854 - , remoteAddress: tlsSocket.remoteAddress || tlsSocket._handle._parent.owner.stream.remoteAddress - , remotePort: tlsSocket.remotePort || tlsSocket._handle._parent.owner.stream.remotePort + , remoteAddress: tlsSocket.remoteAddress || tlsSocket._remoteAddress || tlsSocket._handle._parent.owner.stream.remoteAddress + , remotePort: tlsSocket.remotePort || tlsSocket._remotePort || tlsSocket._handle._parent.owner.stream.remotePort + , remoteFamily: tlsSocket.remoteFamily || tlsSocket._remoteFamily || tlsSocket._handle._parent.owner.stream.remoteFamily }); });