Thu, 15 Jan 2015 15:59:08 +0100
Implement a real Private Browsing Mode condition by changing the API/ABI;
This solves Tor bug #9701, complying with disk avoidance documented in
https://www.torproject.org/projects/torbrowser/design/#disk-avoidance.
1 // defineProperty can make a non-configurable writable property non-writable
3 load(libdir + "asserts.js");
4 var g = newGlobal();
5 var dbg = new Debugger;
6 var gw = dbg.addDebuggee(g);
7 gw.defineProperty("p", {writable: true, value: 1});
8 gw.defineProperty("p", {writable: false});
9 g.p = 4;
10 assertEq(g.p, 1);