Commit 5d7b901d authored by anonym's avatar anonym
Browse files

Merge remote-tracking branch 'origin/feature/9833-replace-adblock-with-ublock' into devel

Fix-committed: #9833
parents a5bd73ca 7a432dea
......@@ -174,6 +174,10 @@ Package: xul-ext-torbirdy
Pin: release o=Debian,n=jessie-backports
Pin-Priority: 999
Package: xul-ext-ublock-origin
Pin: release o=Debian,n=jessie-backports
Pin-Priority: 999
Explanation: weirdness in chroot_apt install-binary
Package: *
Pin: release o=chroot_local-packages
......
......@@ -137,8 +137,8 @@ install_debian_extensions() {
destination="${1}"
shift
apt-get install --yes "${@}"
ln -s /usr/share/xul-ext/adblock-plus/ \
"${destination}"/'{d10d0bf8-f5b5-c8b4-a8b2-2b9879e08c5d}'
ln -s /usr/share/xul-ext/ublock-origin/ \
"${destination}"/'uBlock0@raymondhill.net'
}
create_default_profile() {
......@@ -170,7 +170,7 @@ TBB_TARBALLS_BASE_URL="$(cat "${TBB_DIST_URL_FILE}")"
# The Debian Iceweasel extensions we want to install and make
# available in the Tor Browser.
DEBIAN_EXT_PKGS="xul-ext-adblock-plus"
DEBIAN_EXT_PKGS="xul-ext-ublock-origin"
TMP="$(mktemp -d)"
download_and_verify_files "${TBB_TARBALLS_BASE_URL}" "${TBB_TARBALLS}" "${TMP}"
......
#!/bin/sh
set -e
echo "Installing sqlite3 for uBlock patterns+settings file conversion"
apt-get install --yes sqlite3
echo "Converting uBlock database dump into sqlite blob"
DUMP="/usr/share/tails/ublock-origin/ublock0.dump"
DATABASE="/etc/tor-browser/profile/extension-data/ublock0.sqlite"
mkdir -p "$(dirname "${DATABASE}")"
# The sed expression simply means: remove all CRLF ("\r\n"). The use
# of labels is simply to make this able to remove multiple CRLF to
# create a single (long) line. In the end, this restores the
# diff-friendly dump to the original sqlite dump.
sed ':a;N;$!ba;s_\r\n__g' "${DUMP}" | sqlite3 "${DATABASE}"
echo "Created uBlock sqlite blob successfully"
apt-get purge --remove --yes sqlite3
......@@ -38,3 +38,6 @@ update-ca-certificates
# debugging (and slightly make things easier for malware, perhaps) and
# otherwise just occupy disk space.
rm -f /boot/*.map /boot/*.map-*
# Remove text dump of uBlock settings file
rm -rf /usr/share/tails/ublock-origin/
......@@ -14,7 +14,6 @@
<RDF:Description RDF:about="chrome://browser/content/browser.xul#addon-bar"
collapsed="true" />
<RDF:Description RDF:about="chrome://browser/content/browser.xul#navigator-toolbox"
abp-iconposition="visible,addon-bar,addonbar-closebutton"
iconsize="small" />
<RDF:Description RDF:about="chrome://browser/content/browser.xul#nav-bar"
iconsize="small" />
......
......@@ -17,14 +17,6 @@ pref("extensions.torbutton.show_slider_notification", false);
// Disable the Tor Browser's automatic update checking
pref("app.update.enabled", false);
// Adblock Plus preferences
pref("extensions.adblockplus.correctTypos", false);
pref("extensions.adblockplus.currentVersion", "2.7.3");
pref("extensions.adblockplus.savestats", false);
pref("extensions.adblockplus.showinaddonbar", false);
pref("extensions.adblockplus.showintoolbar", false);
pref("extensions.adblockplus.subscriptions_autoupdate", false);
// Suppress prompt and always spoof useragent as English
pref("extensions.torbutton.spoof_english", true);
pref("extensions.torbutton.prompted_language", true);
......@@ -95,7 +87,7 @@ pref("browser.download.panel.shown", true);
// and instead only propose them to save downloaded files.
pref("browser.download.forbid_open_with", true);
// AdBlock Plus and the amnesia branding extensions are not signed and
// uBlock Origin and the amnesia branding extensions are not signed and
// therefore disabled by default for FF 45+ *unless* we set this
// option. This is only a temporary stop gap. See #11419.
pref("xpinstall.signatures.required", false);
......@@ -983,7 +983,7 @@ The default profile is split from the binaries and application data:
As for extensions we have the following differences:
* Tails also installs the
[Adblock plus](https://addons.mozilla.org/fr/firefox/addon/1865/)
[uBlock Origin](https://github.com/gorhill/uBlock/)
extension to protect against many tracking possibilities by removing
most ads.
......@@ -1423,7 +1423,7 @@ issues|support/known_issues]] page.
However the fact that different browser extensions are installed in Tails and in
the TBB surely allows more sophisticated attacks that usual fingerprint
as returned by tools such as <https://panopticlick.eff.org/> and
<http://ip-check.info/>. For example, the fact that Adblock is removing
<http://ip-check.info/>. For example, the fact that uBlock Origin is removing
ads could be analysed.
From the point of view of the local network administrator, Tails is
......
......@@ -56,12 +56,6 @@ Pre-freeze
The [[contribute/working_together/roles/release_manager]] role
documentation has more tasks that should be done early enough.
Update Tor Browser preferences
------------------------------
* update `extensions.adblockplus.currentVersion` in
`config/chroot_local-includes/etc/tor-browser/profile/preferences/0000tails.js`
Update Icedove preferences
------------------------------
......@@ -145,26 +139,34 @@ Reset the release branch's `config/base_branch`:
Update included files
=====================
AdBlock patterns
uBlock patterns and settings file
----------------
Patterns are stored in
`config/chroot_local-includes/etc/tor-browser/profile/adblockplus/`.
The patterns+settings file is stored as a converted sqlite text dump in
`config/chroot_local-includes/usr/share/tails/ublock-origin/ublock0.dump`.
1. Boot Tails
2. Start the tor Browser and open *Tools* → *Addons*
3. Select *Adblock Plus* in extensions
4. Open *Preferences* → *Filter preferences…*
5. For each filters, click *Actions* → *Update filters*
6. Close the Tor Browser
7. Copy the `.tor-browser/profile.default/adblockplus/patterns.ini` from
this Tor Browser instance to the
`config/chroot_local-includes/etc/tor-browser/profile/adblockplus`
directory in the Tails Git checkout.
2. Start the Tor Browser and open the uBlock dashboard by clicking on the uBlock icon.
3. Select the tab *3rd-party filters*
4. Click on the button *Update now* to update all used patterns
5. Close the Tor Browser
7. Copy the `.tor-browser/profile.default/extension-data/ublock0.sqlite`
from this Tor Browser instance into the root of Tails' Git repo and
run the following command:
echo '.dump' | sqlite3 ublock0.sqlite | \
grep -v "cached_asset_content://cache://compiled-" | \
awk '!/^INSERT/; /^INSERT/ {print $0 | "sort -n"}' | \
sed 's_\\n_\\n\r\n_g' | \
sed "/^INSERT INTO \"settings\" VALUES('\(remoteBlacklists\|cached_asset_entries\)'/"'s_,_,\r\n_g' > \
config/chroot_local-includes/usr/share/tails/ublock-origin/ublock0.dump
8. Commit:
git commit -m 'Update AdBlock Plus patterns.' \
config/chroot_local-includes/etc/tor-browser/profile/adblockplus/patterns.ini
git commit -m 'Update uBlock Origin patterns + settings file.' \
config/chroot_local-includes/usr/share/tails/ublock-origin/ublock0.dump
9. Remove the original `ublock0.sqlite` from the Git root.
Upgrade bundled binary Debian packages
--------------------------------------
......
......@@ -28,7 +28,7 @@ Networking
transparently enables SSL-encrypted connections to a great number
of major websites
- [NoScript](http://noscript.net/) to have even more control over JavaScript.
- [AdBlock Plus](https://adblockplus.org/en/firefox) to remove advertisements.
- [uBlock Origin](https://github.com/gorhill/uBlock/) to remove advertisements.
* [Pidgin](http://www.pidgin.im/) preconfigured with
[OTR](http://www.cypherpunks.ca/otr/index.php) for Off-the-Record
Messaging ([[More...|doc/anonymous_internet/pidgin]])
......
......@@ -35,8 +35,8 @@ Apart from that, **some of the <span class="application">Tor Browser</span> exte
specific to Tails**. More sophisticated
attacks can use those differences to distinguish Tails users.
For example, Tails includes <span class="application">Adblock
Plus</span> which removes advertisements. If an attacker can determine
For example, Tails includes <span class="application">uBlock
Origin</span> which removes advertisements. If an attacker can determine
that you are not downloading the advertisements that are included in a
webpage, that could help identify you as a Tails user.
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment