tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

WorkerNavigator_userAgentData.http.html (614B)


      1 <!DOCTYPE html>
      2 <title> WorkerNavigator.userAgentData </title>
      3 <script src="/resources/testharness.js"></script>
      4 <script src="/resources/testharnessreport.js"></script>
      5 <script>
      6 
      7  promise_test(async () => {
      8    const e = await new Promise((resolve, reject) => {
      9      const worker = new Worker("./support/WorkerNavigator.js");
     10      worker.onmessage = resolve;
     11    });
     12 
     13    assert_equals(e.data.brands, undefined);
     14    assert_equals(e.data.mobile, undefined);
     15    assert_equals(e.data.getHighEntropyValues, undefined);
     16  }, "Test that userAgentData is not available in workers in non-secure contexts");
     17 </script>