mirror of
https://github.com/Ylianst/MeshCentral.git
synced 2025-03-02 23:09:10 -05:00
MeshCMD Route missing HTTP host header fix.
This commit is contained in:
parent
97bd723e4e
commit
8eaa1ee4a9
@ -2034,9 +2034,9 @@ function startRouter() {
|
|||||||
if (xtoken != null) { xurlargs.push('token=' + xtoken); }
|
if (xtoken != null) { xurlargs.push('token=' + xtoken); }
|
||||||
} else {
|
} else {
|
||||||
if (xtoken != null) {
|
if (xtoken != null) {
|
||||||
options.headers = { 'x-meshauth': Buffer.from(settings.username, 'binary').toString('base64') + ',' + Buffer.from(settings.password, 'binary').toString('base64') + ',' + Buffer.from(xtoken, 'binary').toString('base64') };
|
options.headers = { 'host': options.host, 'x-meshauth': Buffer.from(settings.username, 'binary').toString('base64') + ',' + Buffer.from(settings.password, 'binary').toString('base64') + ',' + Buffer.from(xtoken, 'binary').toString('base64') };
|
||||||
} else {
|
} else {
|
||||||
options.headers = { 'x-meshauth': Buffer.from(settings.username, 'binary').toString('base64') + ',' + Buffer.from(settings.password, 'binary').toString('base64') };
|
options.headers = { 'host': options.host, 'x-meshauth': Buffer.from(settings.username, 'binary').toString('base64') + ',' + Buffer.from(settings.password, 'binary').toString('base64') };
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else { options.headers = { 'x-meshauth': '*' }; } // Request inner authentication
|
} else { options.headers = { 'x-meshauth': '*' }; } // Request inner authentication
|
||||||
|
Loading…
x
Reference in New Issue
Block a user