The underlying issue is that webfig is essentially a JS that generates html dynamically that uses
window.sessionStore to store/retrieve the user/password in the
browser's session. And why auth is cleared in a new tab, as @optio suggests. And is not some simple "one click" as already @rextended states. And it's more complex than a simple proxy than I originally suggest — stuff need to happen with in the web browser to set auth (e.g. I thought it used cookie that be manageable in proxy, so such luck).
But there is some code in webfig to deal with it, but the sessionStore has to be set first:
function autoLogin() {
const user = window.sessionStorage.getItem("name");
if (user) {
doAuth(user, window.sessionStorage.getItem("password"));
window.sessionStorage.clear();
} else if (window.name) {
const [method, loginData] = window.name.split(/=(.*)/s);
window.name = "";
if (["login", "autologin"].includes(method) && loginData) {
const [user, pwd] = loginData.split(/\|(.*)/s);
doAuth(user, pwd);
}
} else logout();
}
I ended up just using REST and my own status page to avoid needing this. But being able to re-use webfig's "status page" (and Dude map too) without need the browser auth would be a nice-to-have.