[torbutton/master] Bug 5710: Remove all sessionstore data in TBB.

commit 39c6fc278cb9a5a00449400e6c47c5e5ca47671b Author: Mike Perry <mikeperry-git@fscked.org> Date: Thu May 10 12:26:05 2012 -0700 Bug 5710: Remove all sessionstore data in TBB. I think we got it this time. --- src/components/tbSessionStore.js | 11 +++++++++++ 1 files changed, 11 insertions(+), 0 deletions(-) diff --git a/src/components/tbSessionStore.js b/src/components/tbSessionStore.js index 840b116..5ebc456 100644 --- a/src/components/tbSessionStore.js +++ b/src/components/tbSessionStore.js @@ -95,6 +95,17 @@ TBSessionBlocker.prototype = if (topic != "sessionstore-state-write") return; this.logger.log(3, "Got Session Store observe: "+topic); subject = subject.QueryInterface(Ci.nsISupportsString); + + // Simply block sessionstore writes entirely in Tor Browser + try { + if (this.prefs.getCharPref("torbrowser.version")) { + this.logger.log(3, "Blocking SessionStore write in Tor Browser"); + subject.data = null; + return; + } + } catch(e) { + } + this.logger.log(2, "Parsing JSON: "+subject); var state = this._safeJSONparse(subject);
participants (1)
-
mikeperry@torproject.org