Updated MeshCMD to fix #3234

Ylian Saint-Hilaire committed Nov 3, 2021 at 10:58 UTC be104d819c7b39561f1edce2d8cc3fe0ac8843f8
3 files changed +2 -1
agents/MeshCmd-signed.exe
Binary files a/agents/MeshCmd-signed.exe and b/agents/MeshCmd-signed.exe differ
agents/MeshCmd64-signed.exe
Binary files a/agents/MeshCmd64-signed.exe and b/agents/MeshCmd64-signed.exe differ
agents/meshcmd.js
+2 -1
@@ -2039,12 +2039,13 @@ function startRouter() {
2039 options.headers = { 'host': options.host, 'x-meshauth': Buffer.from(settings.username, 'binary').toString('base64') + ',' + Buffer.from(settings.password, 'binary').toString('base64') };
2040 }
2041 }
2042 - } else { options.headers = { 'x-meshauth': '*' }; } // Request inner authentication
2042 + } else { options.headers = { 'host': options.host, 'x-meshauth': '*' }; } // Request inner authentication
2043 if (settings.loginkey) { xurlargs.push('key=' + settings.loginkey); }
2044 if (xurlargs.length > 0) { options.path += '?' + xurlargs.join('&'); }
2045 } catch (e) { console.log("Unable to parse \"serverUrl\"."); process.exit(1); return; }
2046
2047 debug(1, "Connecting to " + options.host + ".");
2048 + debug(1, "Connection options: " + JSON.stringify(options) + ".");
2049 options.checkServerIdentity = onVerifyServer;
2050 options.rejectUnauthorized = false;
2051 settings.websocket = http.request(options);