From 281bfbc2aa563c0f1b4601148e934a73d76fa527 Mon Sep 17 00:00:00 2001 From: Bryan Ashby Date: Sun, 4 Mar 2018 20:47:25 -0700 Subject: [PATCH] Implement isLocal() for 'LC' ACS --- core/client.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/client.js b/core/client.js index 24c8b1d1..a6c6b78a 100644 --- a/core/client.js +++ b/core/client.js @@ -475,8 +475,8 @@ Client.prototype.waitForKeyPress = function(cb) { }; Client.prototype.isLocal = function() { - // :TODO: return rather client is a local connection or not - return false; + // :TODO: Handle ipv6 better + return [ '127.0.0.1', '::ffff:127.0.0.1' ].includes(this.remoteAddress); }; ///////////////////////////////////////////////////////////////////////////////