Skip to content

Commit fdb2fc3

Browse files
psifertexplafosse
authored andcommitted
update documentation for troubleshooting linux apparmor with snap firefox
1 parent 444d216 commit fdb2fc3

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed

docs/guide/troubleshooting.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -147,6 +147,27 @@ If you're having trouble getting Binary Ninja installed in a headless server ins
147147
apt-get install libgl1-mesa-glx libfontconfig1 libxrender1 libegl1-mesa libxi6 libnspr4 libsm6
148148
```
149149

150+
#### Firefox Snap on Ubuntu 22.04 and Newer
151+
152+
If you have installed Binary Ninja into a path outside your home folder such as `/opt`, you will likely run into this limitation.
153+
154+
Ubuntu 22.04 and newer ship Firefox as a snap that is confined by AppArmor. The confinement blocks `snap.firefox.firefox` from reading arbitrary system paths outside the user's home directory, so paths such as `/opt/binaryninja/docs` are inaccessible. Binary Ninja's local help viewer fails under these conditions because Firefox cannot open the documentation files it launches from `/opt/binaryninja/`, and `dmesg` will show `apparmor="DENIED"` entries similar to:
155+
156+
```
157+
apparmor="DENIED" operation="open" profile="snap.firefox.firefox" name="/opt/binaryninja/docs/index.html" requested_mask="r" denied_mask="r"
158+
```
159+
160+
**Work-around 1:** Keep using the Firefox snap but relocate Binary Ninja so Firefox reads the docs inside `$HOME`. Moving the entire installation from `/opt/binaryninja` to a directory such as `~/Applications/binaryninja/` avoids the sandbox restriction because the snap may read anywhere under the user's home.
161+
162+
**Work-around 2:** Replace the snap build with the deb-packaged Firefox, which is not sandboxed and can read from `/opt`. Canonical publishes the deb via the `ppa:mozillateam/ppa`. A typical sequence looks like:
163+
164+
``` bash
165+
sudo add-apt-repository ppa:mozillateam/ppa
166+
sudo apt update
167+
sudo apt install firefox
168+
sudo snap remove firefox
169+
```
170+
150171
#### Wayland
151172

152173
Binary Ninja uses X11 by default, but ships Wayland client support as an option. To enable Wayland support, run Binary Ninja with the following option:

0 commit comments

Comments
 (0)