Ticket #13019: 0001-Bug-5926-Allow-spoofing-of-javascript-locale-to-en-U.patch

File 0001-Bug-5926-Allow-spoofing-of-javascript-locale-to-en-U.patch, 1.5 KB (added by arthuredelstein, 3 years ago)
  • src/chrome/content/torbutton.js

    From 466fa2da39a1c2fb5c86e8799f5c2ba6987cb5f6 Mon Sep 17 00:00:00 2001
    From: Arthur Edelstein <arthuredelstein@gmail.com>
    Date: Fri, 10 Oct 2014 15:41:19 -0700
    Subject: [PATCH] Bug #5926: Allow spoofing of javascript locale to en-US.
    
    ---
     src/chrome/content/torbutton.js | 3 +++
     1 file changed, 3 insertions(+)
    
    diff --git a/src/chrome/content/torbutton.js b/src/chrome/content/torbutton.js
    index 44020ec..7fddf07 100644
    a b function torbutton_update_fingerprinting_prefs() { 
    20302030          m_tb_prefs.setCharPref("intl.accept_languages", "en-us, en");
    20312031          m_tb_prefs.setCharPref("intl.accept_charsets", "iso-8859-1,*,utf-8");
    20322032          m_tb_prefs.setCharPref("intl.charsetmenu.browser.cache", "UTF-8");
     2033          m_tb_prefs.setCharPref("javascript.default_locale", "en-US");
    20332034        } else {
    20342035          if(m_tb_prefs.prefHasUserValue("intl.accept_languages"))
    20352036            m_tb_prefs.clearUserPref("intl.accept_languages");
    function torbutton_update_fingerprinting_prefs() { 
    20372038            m_tb_prefs.clearUserPref("intl.charsetmenu.browser.cache");
    20382039          if(m_tb_prefs.prefHasUserValue("intl.accept_charsets"))
    20392040            m_tb_prefs.clearUserPref("intl.accept_charsets");
     2041          if(m_tb_prefs.prefHasUserValue("javascript.default_locale"))
     2042            m_tb_prefs.clearUserPref("javascript.default_locale");
    20402043        }
    20412044      } else {
    20422045        m_tb_prefs.setIntPref("browser.display.max_font_attempts",-1);