- | Name: | | Meshcentral Mini-Router | | Version: | | 2.0.0.7 | | Publisher: | | Meshcentral.com | |
+ | Name: | | Meshcentral Mini-Router | | Version: | | 2.0.0.10 | | Publisher: | | Meshcentral.com | |
diff --git a/views/default.handlebars b/views/default.handlebars
index 7f438062..4da4c109 100644
--- a/views/default.handlebars
+++ b/views/default.handlebars
@@ -2416,8 +2416,13 @@
if (xxmap != null) x += 'Location ';
// RDP link, show this link only of the remote machine is Windows.
- if (((connectivity & 1) != 0) && (clickOnce == true) && (mesh.mtype == 2) && ((meshrights & 8) != 0) && (node.agent.id > 0) && (node.agent.id < 5)) { x += 'RDP '; }
-
+ if (((connectivity & 1) != 0) && (clickOnce == true) && (mesh.mtype == 2) && ((meshrights & 8) != 0)) {
+ if ((node.agent.id > 0) && (node.agent.id < 5)) { x += 'RDP '; }
+ if (node.agent.id > 4) {
+ x += 'Putty ';
+ x += 'WinSCP ';
+ }
+ }
x += ' '
QH('p10html3', x);
@@ -2626,8 +2631,8 @@
meshserver.Send({ action: 'removedevices', nodeids: [ nodeid ] });
}
- function p10clickOnce(nodeid, protocol) {
- meshserver.Send({ action: 'getcookie', nodeid: nodeid, tcpport: 3389, tag: 'clickonce', protocol: 'rdp' });
+ function p10clickOnce(nodeid, protocol, port) {
+ meshserver.Send({ action: 'getcookie', nodeid: nodeid, tcpport: port, tag: 'clickonce', protocol: protocol });
}
// Show current location
diff --git a/webserver.js b/webserver.js
index a2e8dac5..70721e6c 100644
--- a/webserver.js
+++ b/webserver.js
@@ -704,7 +704,7 @@ module.exports.CreateWebServer = function (parent, db, args, secret, certificate
Debug(1, 'Websocket relay connected from ' + user.name + ' for ' + req.query.host + '.');
ws.pause(); // Hold this socket until we are ready.
- ws._socket.setKeepAlive(true, 0); // Set TCP keep alive
+ ws._socket.setKeepAlive(true, 240000); // Set TCP keep alive
// Fetch information about the target
obj.db.Get(req.query.host, function (err, docs) {
@@ -940,7 +940,7 @@ module.exports.CreateWebServer = function (parent, db, args, secret, certificate
function handleEchoWebSocket(ws, req) {
var domain = checkUserIpAddress(ws, req);
if (domain == null) return;
- ws._socket.setKeepAlive(true, 0); // Set TCP keep alive
+ ws._socket.setKeepAlive(true, 240000); // Set TCP keep alive
// When data is received from the web socket, echo it back
ws.on('message', function (data) {
@@ -1419,7 +1419,7 @@ module.exports.CreateWebServer = function (parent, db, args, secret, certificate
if ((o.time == null) || (o.time == null) || (typeof o.time != 'number')) { return null; }
o.time = o.time * 1000; // Decode the cookie creation time
o.dtime = Date.now() - o.time; // Decode how long ago the cookie was created (in milliseconds)
- if ((o.dtime > 120000) || (o.dtime < 30000)) return null; // The cookie is only valid 120 seconds, or 30 seconds back in time (in case other server's clock is not quite right)
+ if ((o.dtime > 120000) || (o.dtime < -30000)) return null; // The cookie is only valid 120 seconds, or 30 seconds back in time (in case other server's clock is not quite right)
return o;
} catch (e) { return null; }
}
|
|