Skip Navigation

Is there a way to automatically and inteligently manage session token cookies in firefox ?

Hi, So, I wipe all cookies on every restart of firefox by default.

However, there are a very very few cookies I would like to restore. And only to certain multi-account containers

They are the session cookie to the few websites I login to. Because I'm annoyed to have to login again on every reboot.

But I still want to wipe every other cookies they store.

I tried to make a bookmarklet that can save the session cookie

Example this

javascript:(function() {     function getCookie(name) {         var value = "; " + document.cookie;         var parts = value.split("; " + name + "=");         if (parts.length == 2) return parts.pop().split(";").shift();     }     var cookieValue = getCookie('session_id');     if (cookieValue) {         var data = new Blob([`session_id=${cookieValue}`], {type: 'text/plain'});         var a = document.createElement('a');         a.style.display = 'none';         document.body.appendChild(a);         var url = window.URL.createObjectURL(data);         a.href = url;         a.download = 'session_id.txt';         a.click();         window.URL.revokeObjectURL(url);     } else {         alert('Cookie "session_id" does not exist.');     } })();

Unfortunately, unlike regular cookies, this doesn't work and it returns the cookie doesn't exist.

I would have made another bookmarklet which create a cookie from the file.

What I really need is an addon that lets me specify which cookies to save and restory, in which multi-account container

6

You're viewing a single thread.

6 comments
You've viewed 6 comments.