mirror of
https://github.com/Ylianst/MeshCentral.git
synced 2025-02-14 12:01:52 +00:00
fix external auth with loginkey passthrough #4883
Signed-off-by: si458 <simonsmith5521@gmail.com>
This commit is contained in:
parent
991c23c5f9
commit
b0d9b17e36
1 changed files with 3 additions and 1 deletions
|
@ -2815,7 +2815,9 @@ module.exports.CreateWebServer = function (parent, db, args, certificates, doneF
|
||||||
}
|
}
|
||||||
//res.redirect(domain.url); // This does not handle cookie correctly.
|
//res.redirect(domain.url); // This does not handle cookie correctly.
|
||||||
res.set('Content-Type', 'text/html');
|
res.set('Content-Type', 'text/html');
|
||||||
res.end('<html><head><meta http-equiv="refresh" content=0;url="' + domain.url + '"></head><body></body></html>');
|
let url = domain.url;
|
||||||
|
if (Object.keys(req.query).length > 0) { url += "?" + Object.keys(req.query).map(function(key) { return key + "=" + encodeURIComponent(req.query[key]); }).join("&"); }
|
||||||
|
res.end('<html><head><meta http-equiv="refresh" content=0;url="' + url + '"></head><body></body></html>');
|
||||||
}
|
}
|
||||||
|
|
||||||
// Indicates that any request to "/" should render "default" or "login" depending on login state
|
// Indicates that any request to "/" should render "default" or "login" depending on login state
|
||||||
|
|
Loading…
Reference in a new issue