More ClickOnce fixes.
Ylian Saint-Hilaire committed
Oct 25, 2017 at 09:58 UTC
951e6236f9537593f2edaeb2877677acbe02ae3d
24 files changed
+224
-69
agents/MeshService.exe
Binary files a/agents/MeshService.exe and b/agents/MeshService.exe differ
agents/MeshService64.exe
Binary files a/agents/MeshService64.exe and b/agents/MeshService64.exe differ
agents/meshagent_arm
Binary files a/agents/meshagent_arm and b/agents/meshagent_arm differ
agents/meshagent_pi
Binary files a/agents/meshagent_pi and b/agents/meshagent_pi differ
agents/meshagent_pogo
Binary files a/agents/meshagent_pogo and b/agents/meshagent_pogo differ
agents/meshagent_poky
Binary files a/agents/meshagent_poky and b/agents/meshagent_poky differ
agents/meshagent_poky64
Binary files a/agents/meshagent_poky64 and b/agents/meshagent_poky64 differ
agents/meshagent_x86
Binary files a/agents/meshagent_x86 and b/agents/meshagent_x86 differ
agents/meshagent_x86-64
Binary files a/agents/meshagent_x86-64 and b/agents/meshagent_x86-64 differ
agents/meshagent_x86-64_nokvm
Binary files a/agents/meshagent_x86-64_nokvm and b/agents/meshagent_x86-64_nokvm differ
agents/meshagent_x86_nokvm
Binary files a/agents/meshagent_x86_nokvm and b/agents/meshagent_x86_nokvm differ
meshagent.js
+4
-4
@@ -29,7 +29,7 @@ module.exports.CreateMeshAgent = function (parent, db, ws, req, args, domain) {
29
obj.remoteaddr = obj.ws._socket.remoteAddress;
30
obj.useSHA386 = false;
31
if (obj.remoteaddr.startsWith('::ffff:')) { obj.remoteaddr = obj.remoteaddr.substring(7); }
32
- ws._socket.setKeepAlive(true, 0); // Set TCP keep alive
32
+ ws._socket.setKeepAlive(true, 240000); // Set TCP keep alive, 4 minutes
33
34
// Send a message to the mesh agent
35
obj.send = function (data) { try { if (typeof data == 'string') { obj.ws.send(new Buffer(data, 'binary')); } else { obj.ws.send(data); } } catch (e) { } }
@@ -127,12 +127,12 @@ module.exports.CreateMeshAgent = function (parent, db, ws, req, args, domain) {
127
} else {
128
// Send the next block to the agent
129
obj.agentUpdate.ptr += len;
130
- //console.log("Agent update send next block: " + len);
130
+ //console.log("Agent update send next block", obj.agentUpdate.ptr, len);
131
if (len == agentUpdateBlockSize) { obj.ws.send(obj.agentUpdate.buf); } else { obj.ws.send(obj.agentUpdate.buf.slice(0, len + 4)); } // Command 14, mesh agent next data block
132
133
if (len < agentUpdateBlockSize) {
134
- //console.log("Agent update sent");
135
- obj.send(obj.common.ShortToStr(13) + obj.common.ShortToStr(0) + obj.common.hex2rstr(obj.agentInfo.hash)); // Command 13, end mesh agent download, send agent SHA384 hash
134
+ console.log("Agent update sent");
135
+ obj.send(obj.common.ShortToStr(13) + obj.common.ShortToStr(0) + obj.common.hex2rstr(obj.agentExeInfo.hash)); // Command 13, end mesh agent download, send agent SHA384 hash
136
obj.fs.close(obj.agentUpdate.fd);
137
obj.agentUpdate = null;
138
}
meshcentral.js
+56
-51
@@ -296,55 +296,56 @@ function CreateMeshCentralServer() {
296
297
// Load the list of mesh agents and install scripts
298
if (obj.args.noagentupdate == 1) { for (var i in meshAgentsArchitectureNumbers) { meshAgentsArchitectureNumbers[i].update = false; } }
299
- obj.updateMeshAgentsTable();
300
- obj.updateMeshAgentInstallScripts();
301
-
302
- // Setup and start the web server
303
- require('crypto').randomBytes(48, function (err, buf) {
304
- // Setup Mesh Multi-Server if needed
305
- obj.multiServer = require('./multiserver.js').CreateMultiServer(obj, obj.args);
306
- if (obj.multiServer != null) {
307
- obj.serverId = obj.multiServer.serverid;
308
- for (var serverid in obj.config.peers.servers) { obj.peerConnectivityByNode[serverid] = {}; }
309
- }
310
-
311
- // If the server is set to "nousers", allow only loopback unless IP filter is set
312
- if ((obj.args.nousers == true) && (obj.args.userallowedip == null)) { obj.args.userallowedip = "::1,127.0.0.1"; }
313
-
314
- if (obj.args.secret) {
315
- // This secret is used to encrypt HTTP session information, if specified, user it.
316
- obj.webserver = require('./webserver.js').CreateWebServer(obj, obj.db, obj.args, obj.args.secret, obj.certificates);
317
- } else {
318
- // If the secret is not specified, generate a random number.
319
- obj.webserver = require('./webserver.js').CreateWebServer(obj, obj.db, obj.args, buf.toString('hex').toUpperCase(), obj.certificates);
320
- }
321
-
322
- // Setup and start the redirection server if needed
323
- if ((obj.args.redirport != null) && (typeof obj.args.redirport == 'number') && (obj.args.redirport != 0)) {
324
- obj.redirserver = require('./redirserver.js').CreateRedirServer(obj, obj.db, obj.args, obj.certificates);
325
- }
326
-
327
- // Setup the Intel AMT event handler
328
- obj.amtEventHandler = require('./amtevents.js').CreateAmtEventsHandler(obj);
329
-
330
- // Setup the Intel AMT local network scanner
331
- if (obj.args.wanonly != true) {
332
- obj.amtScanner = require('./amtscanner.js').CreateAmtScanner(obj).start();
333
- obj.meshScanner = require('./meshscanner.js').CreateMeshScanner(obj).start();
334
- }
335
-
336
- // Setup and start the MPS server
337
- if (obj.args.lanonly != true) {
338
- obj.mpsserver = require('./mpsserver.js').CreateMpsServer(obj, obj.db, obj.args, obj.certificates);
339
- }
340
-
341
- // Start periodic maintenance
342
- obj.maintenanceTimer = setInterval(obj.maintenanceActions, 1000 * 60 * 60); // Run this every hour
343
-
344
- // Dispatch an event that the server is now running
345
- obj.DispatchEvent(['*'], obj, { etype: 'server', action: 'started', msg: 'Server started' })
346
-
347
- obj.debug(1, 'Server started');
299
+ obj.updateMeshAgentsTable(function () {
300
+ obj.updateMeshAgentInstallScripts();
301
+
302
+ // Setup and start the web server
303
+ require('crypto').randomBytes(48, function (err, buf) {
304
+ // Setup Mesh Multi-Server if needed
305
+ obj.multiServer = require('./multiserver.js').CreateMultiServer(obj, obj.args);
306
+ if (obj.multiServer != null) {
307
+ obj.serverId = obj.multiServer.serverid;
308
+ for (var serverid in obj.config.peers.servers) { obj.peerConnectivityByNode[serverid] = {}; }
309
+ }
310
+
311
+ // If the server is set to "nousers", allow only loopback unless IP filter is set
312
+ if ((obj.args.nousers == true) && (obj.args.userallowedip == null)) { obj.args.userallowedip = "::1,127.0.0.1"; }
313
+
314
+ if (obj.args.secret) {
315
+ // This secret is used to encrypt HTTP session information, if specified, user it.
316
+ obj.webserver = require('./webserver.js').CreateWebServer(obj, obj.db, obj.args, obj.args.secret, obj.certificates);
317
+ } else {
318
+ // If the secret is not specified, generate a random number.
319
+ obj.webserver = require('./webserver.js').CreateWebServer(obj, obj.db, obj.args, buf.toString('hex').toUpperCase(), obj.certificates);
320
+ }
321
+
322
+ // Setup and start the redirection server if needed
323
+ if ((obj.args.redirport != null) && (typeof obj.args.redirport == 'number') && (obj.args.redirport != 0)) {
324
+ obj.redirserver = require('./redirserver.js').CreateRedirServer(obj, obj.db, obj.args, obj.certificates);
325
+ }
326
+
327
+ // Setup the Intel AMT event handler
328
+ obj.amtEventHandler = require('./amtevents.js').CreateAmtEventsHandler(obj);
329
+
330
+ // Setup the Intel AMT local network scanner
331
+ if (obj.args.wanonly != true) {
332
+ obj.amtScanner = require('./amtscanner.js').CreateAmtScanner(obj).start();
333
+ obj.meshScanner = require('./meshscanner.js').CreateMeshScanner(obj).start();
334
+ }
335
+
336
+ // Setup and start the MPS server
337
+ if (obj.args.lanonly != true) {
338
+ obj.mpsserver = require('./mpsserver.js').CreateMpsServer(obj, obj.db, obj.args, obj.certificates);
339
+ }
340
+
341
+ // Start periodic maintenance
342
+ obj.maintenanceTimer = setInterval(obj.maintenanceActions, 1000 * 60 * 60); // Run this every hour
343
+
344
+ // Dispatch an event that the server is now running
345
+ obj.DispatchEvent(['*'], obj, { etype: 'server', action: 'started', msg: 'Server started' })
346
+
347
+ obj.debug(1, 'Server started');
348
+ });
349
});
350
});
351
});
@@ -728,7 +729,9 @@ function CreateMeshCentralServer() {
729
};
730
731
// Update the list of available mesh agents
731
- obj.updateMeshAgentsTable = function () {
732
+ obj.updateMeshAgentsTable = function (func) {
733
+ var archcount = 0;
734
+ for (var archid in meshAgentsArchitectureNumbers) { archcount++; }
735
for (var archid in meshAgentsArchitectureNumbers) {
736
var agentpath = obj.path.join(__dirname, 'agents', meshAgentsArchitectureNumbers[archid].localname);
737
var stream = null;
@@ -738,6 +741,7 @@ function CreateMeshCentralServer() {
741
stream.on('error', function (data) {
742
// If there is an error reading this file, make sure this agent is not in the agent table
743
if (obj.meshAgentBinaries[this.info.id] != null) { delete obj.meshAgentBinaries[this.info.id]; }
744
+ if ((--archcount == 0) && (func != null)) { func(); }
745
});
746
stream.on('end', function () {
747
// Add the agent to the agent table with all information and the hash
@@ -748,11 +752,12 @@ function CreateMeshCentralServer() {
752
var stats = null;
753
try { stats = obj.fs.statSync(this.agentpath) } catch (e) { }
754
if (stats != null) { obj.meshAgentBinaries[this.info.id].size = stats.size; }
755
+ if ((--archcount == 0) && (func != null)) { func(); }
756
});
757
stream.info = meshAgentsArchitectureNumbers[archid];
758
stream.agentpath = agentpath;
759
stream.hash = obj.crypto.createHash('sha384', stream);
755
- } catch (e) { }
760
+ } catch (e) { if ((--archcount == 0) && (func != null)) { func(); } }
761
}
762
}
763
meshrelay.js
+1
-1
@@ -80,7 +80,7 @@ module.exports.CreateMeshRelay = function (parent, ws, req) {
80
}
81
82
if (obj.id == null) { try { obj.close(); } catch (e) { } return null; } // Attempt to connect without id, drop this.
83
- ws._socket.setKeepAlive(true, 0); // Set TCP keep alive
83
+ ws._socket.setKeepAlive(true, 240000); // Set TCP keep alive
84
85
// Validate that the id is valid, we only need to do this on non-authenticated sessions.
86
// TODO: Figure out when this needs to be done.
meshuser.js
+1
-1
@@ -59,7 +59,7 @@ module.exports.CreateMeshUser = function (parent, db, ws, req, args, domain) {
59
}
60
61
user.subscriptions = obj.parent.subscribe(user._id, ws); // Subscribe to events
62
- obj.ws._socket.setKeepAlive(true, 0); // Set TCP keep alive
62
+ obj.ws._socket.setKeepAlive(true, 240000); // Set TCP keep alive
63
64
// When data is received from the web socket
65
ws.on('message', function (msg) {
public/clickonce/minirouter/Application Files/MeshMiniRouter_2_0_0_10/MeshMiniRouter.application
new
+21
@@ -0,0 +1,21 @@
1
+<?xml version="1.0" encoding="utf-8"?>
2
+<asmv1:assembly xsi:schemaLocation="urn:schemas-microsoft-com:asm.v1 assembly.adaptive.xsd" manifestVersion="1.0" xmlns:asmv1="urn:schemas-microsoft-com:asm.v1" xmlns="urn:schemas-microsoft-com:asm.v2" xmlns:asmv2="urn:schemas-microsoft-com:asm.v2" xmlns:xrml="urn:mpeg:mpeg21:2003:01-REL-R-NS" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:asmv3="urn:schemas-microsoft-com:asm.v3" xmlns:dsig="http://www.w3.org/2000/09/xmldsig#" xmlns:co.v1="urn:schemas-microsoft-com:clickonce.v1" xmlns:co.v2="urn:schemas-microsoft-com:clickonce.v2">
3
+ <assemblyIdentity name="MeshMiniRouter.application" version="2.0.0.10" publicKeyToken="0000000000000000" language="neutral" processorArchitecture="msil" xmlns="urn:schemas-microsoft-com:asm.v1" />
4
+ <description asmv2:publisher="Meshcentral.com" asmv2:product="Meshcentral Mini-Router" asmv2:supportUrl="https://meshcentral.com/" xmlns="urn:schemas-microsoft-com:asm.v1" />
5
+ <deployment install="false" mapFileExtensions="true" trustURLParameters="true" />
6
+ <compatibleFrameworks xmlns="urn:schemas-microsoft-com:clickonce.v2">
7
+ <framework targetVersion="4.5" profile="Full" supportedRuntime="4.0.30319" />
8
+ </compatibleFrameworks>
9
+ <dependency>
10
+ <dependentAssembly dependencyType="install" codebase="Application Files\MeshMiniRouter_2_0_0_10\MeshMiniRouter.exe.manifest" size="4712">
11
+ <assemblyIdentity name="MeshMiniRouter.exe" version="2.0.0.10" publicKeyToken="0000000000000000" language="neutral" processorArchitecture="msil" type="win32" />
12
+ <hash>
13
+ <dsig:Transforms>
14
+ <dsig:Transform Algorithm="urn:schemas-microsoft-com:HashTransforms.Identity" />
15
+ </dsig:Transforms>
16
+ <dsig:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha256" />
17
+ <dsig:DigestValue>nAtlMki8bI8WHgD0B1tC4ZVmxIYy41iUEGTj8OMxNmU=</dsig:DigestValue>
18
+ </hash>
19
+ </dependentAssembly>
20
+ </dependency>
21
+</asmv1:assembly>
\ No newline at end of file
public/clickonce/minirouter/Application Files/MeshMiniRouter_2_0_0_10/MeshMiniRouter.exe.config.deploy
new
+42
@@ -0,0 +1,42 @@
1
+<?xml version="1.0"?>
2
+<configuration>
3
+ <configSections>
4
+ <sectionGroup name="userSettings" type="System.Configuration.UserSettingsGroup, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
5
+ <section name="MeshMiniRouterTool.Properties.Settings" type="System.Configuration.ClientSettingsSection, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" allowExeDefinition="MachineToLocalUser" requirePermission="false"/>
6
+ <section name="MeshMiniRouterTool.Settings1" type="System.Configuration.ClientSettingsSection, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" allowExeDefinition="MachineToLocalUser" requirePermission="false"/>
7
+ <section name="MeshNetworkRouterTool.Properties.Settings" type="System.Configuration.ClientSettingsSection, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" allowExeDefinition="MachineToLocalUser" requirePermission="false"/>
8
+ </sectionGroup>
9
+ </configSections>
10
+ <userSettings>
11
+ <MeshMiniRouterTool.Properties.Settings>
12
+ <setting name="PuttyPath" serializeAs="String">
13
+ <value/>
14
+ </setting>
15
+ <setting name="Upgraded" serializeAs="String">
16
+ <value>False</value>
17
+ </setting>
18
+ <setting name="UltraVncPath" serializeAs="String">
19
+ <value/>
20
+ </setting>
21
+ <setting name="HybridCloudManager" serializeAs="String">
22
+ <value/>
23
+ </setting>
24
+ <setting name="TightVncPath" serializeAs="String">
25
+ <value/>
26
+ </setting>
27
+ <setting name="WinSCPPath" serializeAs="String">
28
+ <value/>
29
+ </setting>
30
+ </MeshMiniRouterTool.Properties.Settings>
31
+ <MeshMiniRouterTool.Settings1>
32
+ <setting name="puttypath" serializeAs="String">
33
+ <value/>
34
+ </setting>
35
+ </MeshMiniRouterTool.Settings1>
36
+ <MeshNetworkRouterTool.Properties.Settings>
37
+ <setting name="Server" serializeAs="String">
38
+ <value/>
39
+ </setting>
40
+ </MeshNetworkRouterTool.Properties.Settings>
41
+ </userSettings>
42
+<startup><supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5"/></startup></configuration>
public/clickonce/minirouter/Application Files/MeshMiniRouter_2_0_0_10/MeshMiniRouter.exe.deploy
Binary files /dev/null and b/public/clickonce/minirouter/Application Files/MeshMiniRouter_2_0_0_10/MeshMiniRouter.exe.deploy differ
public/clickonce/minirouter/Application Files/MeshMiniRouter_2_0_0_10/MeshMiniRouter.exe.manifest
new
+82
@@ -0,0 +1,82 @@
1
+<?xml version="1.0" encoding="utf-8"?>
2
+<asmv1:assembly xsi:schemaLocation="urn:schemas-microsoft-com:asm.v1 assembly.adaptive.xsd" manifestVersion="1.0" xmlns:asmv1="urn:schemas-microsoft-com:asm.v1" xmlns="urn:schemas-microsoft-com:asm.v2" xmlns:asmv2="urn:schemas-microsoft-com:asm.v2" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:co.v1="urn:schemas-microsoft-com:clickonce.v1" xmlns:asmv3="urn:schemas-microsoft-com:asm.v3" xmlns:dsig="http://www.w3.org/2000/09/xmldsig#" xmlns:co.v2="urn:schemas-microsoft-com:clickonce.v2">
3
+ <asmv1:assemblyIdentity name="MeshMiniRouter.exe" version="2.0.0.10" publicKeyToken="0000000000000000" language="neutral" processorArchitecture="msil" type="win32" />
4
+ <description asmv2:iconFile="MeshMiniRouter.ico" xmlns="urn:schemas-microsoft-com:asm.v1" />
5
+ <application />
6
+ <entryPoint>
7
+ <assemblyIdentity name="MeshMiniRouter" version="1.0.6507.17826" language="neutral" processorArchitecture="msil" />
8
+ <commandLine file="MeshMiniRouter.exe" parameters="" />
9
+ </entryPoint>
10
+ <trustInfo>
11
+ <security>
12
+ <applicationRequestMinimum>
13
+ <PermissionSet version="1" class="System.Security.NamedPermissionSet" Name="Internet" Description="Default rights given to Internet applications" Unrestricted="true" ID="Custom" SameSite="site" />
14
+ <defaultAssemblyRequest permissionSetReference="Custom" />
15
+ </applicationRequestMinimum>
16
+ <requestedPrivileges xmlns="urn:schemas-microsoft-com:asm.v3">
17
+ <!-- UAC Manifest Options
18
+ If you want to change the Windows User Account Control level replace the
19
+ requestedExecutionLevel node with one of the following.
20
+
21
+ <requestedExecutionLevel level="asInvoker" uiAccess="false" />
22
+ <requestedExecutionLevel level="requireAdministrator" uiAccess="false" />
23
+ <requestedExecutionLevel level="highestAvailable" uiAccess="false" />
24
+
25
+ Specifying requestedExecutionLevel node will disable file and registry virtualization.
26
+ If you want to utilize File and Registry Virtualization for backward
27
+ compatibility then delete the requestedExecutionLevel node.
28
+ -->
29
+ <requestedExecutionLevel level="asInvoker" uiAccess="false" />
30
+ </requestedPrivileges>
31
+ </security>
32
+ </trustInfo>
33
+ <dependency>
34
+ <dependentOS>
35
+ <osVersionInfo>
36
+ <os majorVersion="5" minorVersion="1" buildNumber="2600" servicePackMajor="0" />
37
+ </osVersionInfo>
38
+ </dependentOS>
39
+ </dependency>
40
+ <dependency>
41
+ <dependentAssembly dependencyType="preRequisite" allowDelayedBinding="true">
42
+ <assemblyIdentity name="Microsoft.Windows.CommonLanguageRuntime" version="4.0.30319.0" />
43
+ </dependentAssembly>
44
+ </dependency>
45
+ <dependency>
46
+ <dependentAssembly dependencyType="install" allowDelayedBinding="true" codebase="MeshMiniRouter.exe" size="193536">
47
+ <assemblyIdentity name="MeshMiniRouter" version="1.0.6507.17826" language="neutral" processorArchitecture="msil" />
48
+ <hash>
49
+ <dsig:Transforms>
50
+ <dsig:Transform Algorithm="urn:schemas-microsoft-com:HashTransforms.Identity" />
51
+ </dsig:Transforms>
52
+ <dsig:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha256" />
53
+ <dsig:DigestValue>HHqrJ3vBMkqfPDfdzKBtZW4mtE/Sg5O5LdPB6KmBv3E=</dsig:DigestValue>
54
+ </hash>
55
+ </dependentAssembly>
56
+ </dependency>
57
+ <file name="MeshMiniRouter.exe.config" size="2397">
58
+ <hash>
59
+ <dsig:Transforms>
60
+ <dsig:Transform Algorithm="urn:schemas-microsoft-com:HashTransforms.Identity" />
61
+ </dsig:Transforms>
62
+ <dsig:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha256" />
63
+ <dsig:DigestValue>UylUFD4/o0KBti+5/eodTDgq4BkUJD0J0aUXNd3yHbY=</dsig:DigestValue>
64
+ </hash>
65
+ </file>
66
+ <file name="MeshMiniRouter.ico" size="1078">
67
+ <hash>
68
+ <dsig:Transforms>
69
+ <dsig:Transform Algorithm="urn:schemas-microsoft-com:HashTransforms.Identity" />
70
+ </dsig:Transforms>
71
+ <dsig:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha256" />
72
+ <dsig:DigestValue>mkjbDQuo7YXa8wZxdKEu/ECXrORwwtpRgNj8NBKbzHo=</dsig:DigestValue>
73
+ </hash>
74
+ </file>
75
+ <compatibility xmlns="urn:schemas-microsoft-com:compatibility.v1">
76
+ <application>
77
+ <!-- A list of all Windows versions that this application is designed to work with. Windows will automatically select the most compatible environment.-->
78
+ <!-- If your application is designed to work with Windows 7, uncomment the following supportedOS node-->
79
+ <!--<supportedOS Id="{35138b9a-5d96-4fbd-8e2d-a2440225f93a}"/>-->
80
+ </application>
81
+ </compatibility>
82
+</asmv1:assembly>
\ No newline at end of file
public/clickonce/minirouter/Application Files/MeshMiniRouter_2_0_0_10/MeshMiniRouter.ico.deploy
Binary files /dev/null and b/public/clickonce/minirouter/Application Files/MeshMiniRouter_2_0_0_10/MeshMiniRouter.ico.deploy differ
public/clickonce/minirouter/MeshMiniRouter.application
+4
-4
@@ -1,20 +1,20 @@
1
<?xml version="1.0" encoding="utf-8"?>
2
<asmv1:assembly xsi:schemaLocation="urn:schemas-microsoft-com:asm.v1 assembly.adaptive.xsd" manifestVersion="1.0" xmlns:asmv1="urn:schemas-microsoft-com:asm.v1" xmlns="urn:schemas-microsoft-com:asm.v2" xmlns:asmv2="urn:schemas-microsoft-com:asm.v2" xmlns:xrml="urn:mpeg:mpeg21:2003:01-REL-R-NS" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:asmv3="urn:schemas-microsoft-com:asm.v3" xmlns:dsig="http://www.w3.org/2000/09/xmldsig#" xmlns:co.v1="urn:schemas-microsoft-com:clickonce.v1" xmlns:co.v2="urn:schemas-microsoft-com:clickonce.v2">
3
- <assemblyIdentity name="MeshMiniRouter.application" version="2.0.0.7" publicKeyToken="0000000000000000" language="neutral" processorArchitecture="msil" xmlns="urn:schemas-microsoft-com:asm.v1" />
3
+ <assemblyIdentity name="MeshMiniRouter.application" version="2.0.0.10" publicKeyToken="0000000000000000" language="neutral" processorArchitecture="msil" xmlns="urn:schemas-microsoft-com:asm.v1" />
4
<description asmv2:publisher="Meshcentral.com" asmv2:product="Meshcentral Mini-Router" asmv2:supportUrl="https://meshcentral.com/" xmlns="urn:schemas-microsoft-com:asm.v1" />
5
<deployment install="false" mapFileExtensions="true" trustURLParameters="true" />
6
<compatibleFrameworks xmlns="urn:schemas-microsoft-com:clickonce.v2">
7
<framework targetVersion="4.5" profile="Full" supportedRuntime="4.0.30319" />
8
</compatibleFrameworks>
9
<dependency>
10
- <dependentAssembly dependencyType="install" codebase="Application Files\MeshMiniRouter_2_0_0_7\MeshMiniRouter.exe.manifest" size="4711">
11
- <assemblyIdentity name="MeshMiniRouter.exe" version="2.0.0.7" publicKeyToken="0000000000000000" language="neutral" processorArchitecture="msil" type="win32" />
10
+ <dependentAssembly dependencyType="install" codebase="Application Files\MeshMiniRouter_2_0_0_10\MeshMiniRouter.exe.manifest" size="4712">
11
+ <assemblyIdentity name="MeshMiniRouter.exe" version="2.0.0.10" publicKeyToken="0000000000000000" language="neutral" processorArchitecture="msil" type="win32" />
12
<hash>
13
<dsig:Transforms>
14
<dsig:Transform Algorithm="urn:schemas-microsoft-com:HashTransforms.Identity" />
15
</dsig:Transforms>
16
<dsig:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha256" />
17
- <dsig:DigestValue>VsPkLYR71TSqI8oGBBeXzb5hGi4R2xtQaGQJ0zmsTic=</dsig:DigestValue>
17
+ <dsig:DigestValue>nAtlMki8bI8WHgD0B1tC4ZVmxIYy41iUEGTj8OMxNmU=</dsig:DigestValue>
18
</hash>
19
</dependentAssembly>
20
</dependency>
public/clickonce/minirouter/publish.htm
+1
-1
@@ -59,7 +59,7 @@ FONT.key {font-weight: bold; color: darkgreen}
59
<TR><TD ALIGN="LEFT"><TABLE CELLPADDING="2" CELLSPACING="0" BORDER="0" WIDTH="540"><TR><TD WIDTH="496">
60
61
<!-- Begin AppInfo -->
62
-<TABLE><TR><TD COLSPAN="3"> </TD></TR><TR><TD><B>Name:</B></TD><TD WIDTH="5"><SPACER TYPE="block" WIDTH="10" /></TD><TD>Meshcentral Mini-Router</TD></TR><TR><TD COLSPAN="3"> </TD></TR><TR><TD><B>Version:</B></TD><TD WIDTH="5"><SPACER TYPE="block" WIDTH="10" /></TD><TD>2.0.0.7</TD></TR><TR><TD COLSPAN="3"> </TD></TR><TR><TD><B>Publisher:</B></TD><TD WIDTH="5"><SPACER TYPE="block" WIDTH="10" /></TD><TD>Meshcentral.com</TD></TR><tr><td colspan="3"> </td></tr></TABLE>
62
+<TABLE><TR><TD COLSPAN="3"> </TD></TR><TR><TD><B>Name:</B></TD><TD WIDTH="5"><SPACER TYPE="block" WIDTH="10" /></TD><TD>Meshcentral Mini-Router</TD></TR><TR><TD COLSPAN="3"> </TD></TR><TR><TD><B>Version:</B></TD><TD WIDTH="5"><SPACER TYPE="block" WIDTH="10" /></TD><TD>2.0.0.10</TD></TR><TR><TD COLSPAN="3"> </TD></TR><TR><TD><B>Publisher:</B></TD><TD WIDTH="5"><SPACER TYPE="block" WIDTH="10" /></TD><TD>Meshcentral.com</TD></TR><tr><td colspan="3"> </td></tr></TABLE>
63
<!-- End AppInfo -->
64
65
views/default.handlebars
+9
-4
@@ -2416,8 +2416,13 @@
2416
if (xxmap != null) x += '<a style=cursor:pointer onclick=p10showNodeLocationDialog("' + node._id + '") title="Show device locations information">Location</a> ';
2417
2418
// RDP link, show this link only of the remote machine is Windows.
2419
- if (((connectivity & 1) != 0) && (clickOnce == true) && (mesh.mtype == 2) && ((meshrights & 8) != 0) && (node.agent.id > 0) && (node.agent.id < 5)) { x += '<a style=cursor:pointer onclick=p10clickOnce("' + node._id + '","RDP") title="Requires Microsoft ClickOnce support in your browser.">RDP</a> '; }
2420
-
2419
+ if (((connectivity & 1) != 0) && (clickOnce == true) && (mesh.mtype == 2) && ((meshrights & 8) != 0)) {
2420
+ if ((node.agent.id > 0) && (node.agent.id < 5)) { x += '<a style=cursor:pointer onclick=p10clickOnce("' + node._id + '","RDP2",3389) title="Requires Microsoft ClickOnce support in your browser.">RDP</a> '; }
2421
+ if (node.agent.id > 4) {
2422
+ x += '<a style=cursor:pointer onclick=p10clickOnce("' + node._id + '","PSSH",22) title="Requires Microsoft ClickOnce support in your browser.">Putty</a> ';
2423
+ x += '<a style=cursor:pointer onclick=p10clickOnce("' + node._id + '","WSCP",22) title="Requires Microsoft ClickOnce support in your browser.">WinSCP</a> ';
2424
+ }
2425
+ }
2426
x += '</div><br>'
2427
2428
QH('p10html3', x);
@@ -2626,8 +2631,8 @@
2631
meshserver.Send({ action: 'removedevices', nodeids: [ nodeid ] });
2632
}
2633
2629
- function p10clickOnce(nodeid, protocol) {
2630
- meshserver.Send({ action: 'getcookie', nodeid: nodeid, tcpport: 3389, tag: 'clickonce', protocol: 'rdp' });
2634
+ function p10clickOnce(nodeid, protocol, port) {
2635
+ meshserver.Send({ action: 'getcookie', nodeid: nodeid, tcpport: port, tag: 'clickonce', protocol: protocol });
2636
}
2637
2638
// Show current location
webserver.js
+3
-3
@@ -704,7 +704,7 @@ module.exports.CreateWebServer = function (parent, db, args, secret, certificate
704
Debug(1, 'Websocket relay connected from ' + user.name + ' for ' + req.query.host + '.');
705
706
ws.pause(); // Hold this socket until we are ready.
707
- ws._socket.setKeepAlive(true, 0); // Set TCP keep alive
707
+ ws._socket.setKeepAlive(true, 240000); // Set TCP keep alive
708
709
// Fetch information about the target
710
obj.db.Get(req.query.host, function (err, docs) {
@@ -940,7 +940,7 @@ module.exports.CreateWebServer = function (parent, db, args, secret, certificate
940
function handleEchoWebSocket(ws, req) {
941
var domain = checkUserIpAddress(ws, req);
942
if (domain == null) return;
943
- ws._socket.setKeepAlive(true, 0); // Set TCP keep alive
943
+ ws._socket.setKeepAlive(true, 240000); // Set TCP keep alive
944
945
// When data is received from the web socket, echo it back
946
ws.on('message', function (data) {
@@ -1419,7 +1419,7 @@ module.exports.CreateWebServer = function (parent, db, args, secret, certificate
1419
if ((o.time == null) || (o.time == null) || (typeof o.time != 'number')) { return null; }
1420
o.time = o.time * 1000; // Decode the cookie creation time
1421
o.dtime = Date.now() - o.time; // Decode how long ago the cookie was created (in milliseconds)
1422
- 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)
1422
+ 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)
1423
return o;
1424
} catch (e) { return null; }
1425
}