Project

General

Profile

Installation instructions (browser extension Mozilla) » History » Version 15

koszko, 03/04/2022 11:27 AM
explain how to make Haketilo's settings page work in Incognito mode + other small changes

1 1 koszko
# Installation instructions (Mozilla)
2 2 koszko
3 13 koszko
{{toc}}
4 12 koszko
5 1 koszko
## Browser compatibility
6
7 11 koszko
Haketilo is currently compatible with browsers based on Mozilla Firefox 60 and upwards.
8 1 koszko
9 15 koszko
Although this makes little difference to Haketilo, please consider using a Firefox derivative that ~~isn't malware~~ respects your freedom and privacy (i.e. does not snoop on you). Valid options are browsers in some of the ["ethical" GNU/Linux distros](https://www.gnu.org/distros/free-distros.html#for-pc) like Parabola and Trisquel, the Tor Browser and LibreWolf.
10 1 koszko
11 13 koszko
## Single-user install
12 1 koszko
13 13 koszko
Here we'll describe how to install Haketilo from a .xpi file served by our servers. Extensions in Firefox and its derivatives are often installed from the Mozilla Add-ons website (AMO) but this approach has serious privacy and freedom problems.
14
15
Right now we only provide an unsigned .xpi extension file. This means it hasn't been cryptographically signed by Mozilla and therefore some of Mozilla browsers and even derivatives will refuse to install it. While we're going to provide a signed version of the extension soon, you are strongly encouraged to use a Firefox derivative that allows you to manage your software and install unsigned add-ons as well.
16
17
*Note: even if your browser refuses to install a unsigned extensions, you can still 1) try it out by installing it as a "temporary" add-on on `about:debugging` page or 2) try installing it [[#Global-install-GNULinux-distributions|globally]]*
18
19
### Steps
20
21 12 koszko
*Note: depending on the versions of your web browser and Haketilo some UI elements and text messages might be slightly different on your machine than on the screenshots below*
22 9 koszko
23 12 koszko
First, download the extension's .xpi file from  the [[Releases]]. You can also download the cryptographic signatures to verify the file hasn't been tampered with. After downloading, go to the `about:addons` URL. In the extensions management page that shows up, click on the gear icon and select "Install Add-on From File...".
24
25 7 jahoti
![extensions page](mozilla_install_from_file.png)
26 3 koszko
27
Now, navigate to the downloaded .xpi file and select it.
28
29 6 jahoti
![navigating to the extension file](navigate_extension_xpi_file.png)
30 3 koszko
31 1 koszko
*Note: if, at this point, your browser shows you an error message about extension file being invalid but you're sure the browser supports installation of unsigned extensions, go to the `about:config` URL, confirm the warning prompt that appears, search for the `xpinstall.signatures.required` preference and double-click it to toggle its value to "false"*
32 5 jahoti
33 3 koszko
You should be presented with a dialog asking whether to add Haketilo to your browser. Once you click "Add", the add-on will install.
34 1 koszko
35
![adding Haketilo](mozilla_add_hachette.png)
36
37 15 koszko
The browser might ask whether you want to allow Haketilo to run in private windows. If you installed Haketilo for its script-blocking capabilities, you most likely also want to utilize them in Private Browsing mode and you can check this option. However, there might be some issues involved and it's recommended that you read the [[#Using-Haketilo-in-private-windows|related note]].
38 1 koszko
39 15 koszko
** If you enable Haketilo in **
40
41 1 koszko
![Haketilo installed, allowing extension to run in private windows](mozilla_hachette_installed_allow_private.png)
42
43 13 koszko
## Global install (GNU/Linux distributions)
44
45
Most Firefox-based browsers from GNU/Linux distros' package managers (including `firefox-esr` from Debian and `abrowser` from Trisquel) are configured to automatically pick up extensions placed under
46
```
47
/usr/share/mozilla/extensions/{ec8030f7-c20a-464f-9b0e-13a3a9e97384}
48
```
49
where `{ec8030f7-c20a-464f-9b0e-13a3a9e97384}` is the ID of Mozilla Firefox. This is what enables commands like *`apt install webext-ublock-origin`* to work on distros (in this case, Debian and Trisquel).
50
51
Here, we'll leverage this to install Haketilo system-wide and have it appear in the browser of every user account.
52
53
*Note: you need access to root account via `sudo` command for the instructions below to work*
54
55
*Note: it is assumed you have `curl` and `unzip` commands installed*
56
57
### Steps
58
59
*Note: depending on the versions of your web browser and Haketilo some UI elements and text messages might be slightly different on your machine than on the screenshots below*
60
61
Run the following in your POSIX shell, type your user password when prompted:
62
63
``` shell
64
HAKETILO_VER="1.0b1" # replace with the version you want to have installed
65
HAKETILO_URL="https://hydrilla.koszko.org/downloads/haketilo-$HAKETILO_VER.xpi"
66 1 koszko
FIREFOX_ID="{ec8030f7-c20a-464f-9b0e-13a3a9e97384}"
67 13 koszko
HAKETILO_ID="{6fe13369-88e9-440f-b837-5012fb3bedec}"
68 15 koszko
# You may need to use a different path for other browsers and distros.
69 13 koszko
EXT_PATH="/usr/share/mozilla/extensions/$FIREFOX_ID/$HAKETILO_ID/"
70
71
install_haketilo() {
72
    sudo mkdir -p "$EXT_PATH"
73
    cd "$EXT_PATH"
74
    curl "$HAKETILO_URL" -o /tmp/haketilo.xpi
75
    sudo unzip /tmp/haketilo.xpi
76
    rm /tmp/haketilo.xpi
77
}
78
79
install_haketilo
80 1 koszko
```
81 13 koszko
Optionally, you can modify this snippet to also verify the downloaded file with signatures provided on the [[Releases]] page.
82
83 15 koszko
Once you have performed the installation, you might (or might not) want to give Haketilo access to private browser windows. You can do it from the `about:addons` page. There might be some issues involved, so it's recommended that you read the [[#Using-Haketilo-in-private-windows|related note]].
84 13 koszko
85
![Haketio manage](haketilo_manage.png)
86 1 koszko
87
88
![Haketio allow in private tabs](haketilo_manage_allow_private_tabs.png)
89 15 koszko
90
## Post-installation notes
91
92
### Using Haketilo in private windows
93
94
If you're using the Private Browsing mode, you probably care about security and privacy. Those are basically unachievable with JavaScript globally allowed in the browser. Because of that, you likely want to give Haketilo permission to run in private windows as well.
95
96
*Note: it is a perfectly valid approach to aim for a purely script-less experience in private browsing windows and use an add-on like NoScript or uBlock Origin there instead of Haketilo*
97
98
Haketilo 1.0 uses IndexedDB in-browser database to store all its settings and data. Unfortunately, the ability to use IndexedDB in Private Browsing mode is disabled by default in many Mozilla-based browsers. This causes Haketilo's settings page to be inoperable even when Haketilo itself is allowed to run in private windows.
99
100
The following solutions exist.
101
102
#### 1. Don't use Private Browsing mode
103
104
This is probably not what you are interested in, so let's move ahead.
105
106
#### 2. Enable IndexedDB access in private windows
107
108
The relevant setting is controlled by "dom.indexedDB.privateBrowsing.enabled" preference. You need to navigate to `about:config` URL, click through the warning that appears, find the preference and set it to "true".
109
110
![toggling the "dom.indexedDB.privateBrowsing.enabled" preference](indexeddb_private_browsing.png)
111
112
##### Warning
113
This will also give pages browsed in Private Browsing mode the ability to use IndexedDB. In practice, pages that are going have their scripts blocked will not be able to access the IndexedDB database anyway. This means you have to carefully consider what remote JavaScript (if any) you're going to allow to execute. Only you can decide whether it is the right choice to toggle this preference.
114
115
#### 3. Access Haketilo's settings page from non-private windows
116
117
Other parts of Haketilo work properly regardless of IndexedDB settings for private windows. If you open Haketilo's settings page in a non-private window, configuration you make there will affect script blocking and injection in both private and non-private windows.
118 13 koszko
119 14 koszko
## Gratulations
120 8 jahoti
121 5 jahoti
That's it. You can now play a bit with the extension and [[User manual#Understanding-the-concepts|learn how it works]]. Also, make sure you realize its [[Known limitations|limitations]].