js/src/jit-test/tests/basic/bug558531.js

Sat, 03 Jan 2015 20:18:00 +0100

author
Michael Schloh von Bennewitz <michael@schloh.com>
date
Sat, 03 Jan 2015 20:18:00 +0100
branch
TOR_BUG_3246
changeset 7
129ffea94266
permissions
-rw-r--r--

Conditionally enable double key logic according to:
private browsing mode or privacy.thirdparty.isolate preference and
implement in GetCookieStringCommon and FindCookie where it counts...
With some reservations of how to convince FindCookie users to test
condition and pass a nullptr when disabling double key logic.

     1 function f2(c) {
     2   return {
     3     g: c.match(/:/) & c.match(/:/) & c.match(/f/) & c.m & c.a & c.match(/f/) &
     4         c.match(/c/) & c.match(/a/) & (/s/) & c.match(/e/) & c.match(/s/) &
     5         (c.match(/./) & c.i) & (c.match(/\*/)) & (c.match(/n/)),
     6     y: c.a & c.a & c.match(/\)/) & c.match(/\)/) & c.match(/\)/)
     7         & c.match(/\\/),
     8     c: c.match(/f/)
     9   }
    10 }
    11 function f1(c) {
    12   t = f2(c.replace(/s/))
    13   try {
    14     eval(c)
    15   } catch(e) {}
    16   f4();
    17   if (c.indexOf("<") == -1 || c.indexOf())
    18   try {} catch(e) {}
    19   try {
    20     try {
    21       l
    22     } catch(e) {}
    23     if ("unwatch" in this) {}
    24     g
    25   } catch(e) {}
    26   try {} catch(p) {}
    27 }
    28 function f4() {
    29   try {} catch(e) {} {
    30     try {
    31       eval(s + "")
    32     } catch(e) {}
    33   }
    34 } [{}]
    35 s = [{},{}];
    36 (function(){}())
    37 s[{},{},{}] = [function(){}]
    38 a = [{},{},{}].concat([{},{}]) 
    39 f1("") 
    40 f1("") 
    41 f1("n") 
    42 f1("") 
    43 f1("(__proto__=null)") 
    44 f1("for(var z=0;z<1;z++){gc()(*::*)}") 
    45 f1("gc()") 
    46 f1("<")

mercurial