mirror of
https://github.com/linagora/tmail-flutter.git
synced 2026-12-05 16:08:46 +00:00
* Move inline web scripts to files and enforce the nginx page policy * Render CSP_* through the nginx image entrypoint and allow blob: in connect-src * Allow CSP_IMG_SRC and document nginx add_header inheritance and connect-src ports * Keep a read-only logo mount from stopping nginx and add optional CSP_REPORT_URI * fix: start nginx when the root or a logo mount is read-only * docs: document the web CSP variables and upgrade steps --------- Co-authored-by: Dat H. Pham <dphamhoang@linagora.com>
16 lines
700 B
JavaScript
16 lines
700 B
JavaScript
const AUTH_RESPONSE_KEY = "auth_info";
|
|
const CODE_VERIFIER_KEY = "auth_code_verifier";
|
|
window.onload = function () {
|
|
try {
|
|
sessionStorage.removeItem(AUTH_RESPONSE_KEY);
|
|
sessionStorage.removeItem(CODE_VERIFIER_KEY);
|
|
localStorage.removeItem(AUTH_RESPONSE_KEY);
|
|
localStorage.removeItem(CODE_VERIFIER_KEY);
|
|
// A caller-supplied redirect target is never followed; "./" keeps subpath (--base-href) deploys inside the app.
|
|
window.location.replace("./");
|
|
} catch (error) {
|
|
console.error("[Logout Auth Redirect] Redirection failed:", error);
|
|
window.location.replace("./");
|
|
}
|
|
}
|