mirror of
https://github.com/inverse-inc/sogo.git
synced 2026-03-22 06:42:44 +00:00
fix(core): add security flags to cookies (HttpOnly, secure)
Fixes #4525
This commit is contained in:
@@ -7,11 +7,6 @@ function initLogin() {
|
||||
date.setTime(date.getTime() - 86400000);
|
||||
|
||||
var href = $("connectForm").action.split("/");
|
||||
var appName = href[href.length-2];
|
||||
|
||||
document.cookie = ("0xHIGHFLYxSOGo=discarded"
|
||||
+ "; expires=" + date.toGMTString()
|
||||
+ "; path=/" + appName + "/");
|
||||
|
||||
var about = $("about");
|
||||
if (about) {
|
||||
@@ -118,9 +113,7 @@ function onLoginCallback(http) {
|
||||
|
||||
if (http.status == 200) {
|
||||
// Make sure browser's cookies are enabled
|
||||
var loginCookie = readLoginCookie();
|
||||
|
||||
if (!loginCookie) {
|
||||
if (navigator && !navigator.cookieEnabled) {
|
||||
SetLogMessage("errorMessage", _("cookiesNotEnabled"));
|
||||
submitBtn.disabled = false;
|
||||
return;
|
||||
|
||||
Reference in New Issue
Block a user