[GH-ISSUE #1716] Firefox: access ~/Downloads folder if using --private-home #1158

Closed
opened 2026-05-05 07:33:38 -06:00 by gitea-mirror · 2 comments
Owner

Originally created by @damadmai on GitHub (Jan 6, 2018).
Original GitHub issue: https://github.com/netblue30/firejail/issues/1716

I'm using
firejail --private-home=.mozilla firefox %u --no-remote
for Firefox. So that my firefox profile, history etc. is not changed but my settings are used.

How to achieve making an directory accessible outside this sandbox like ~/Downloads?
Currently this folder is empty and I it not possible to exchange files with the sandbox.
They are lost on terminating the process because the temporary filesystem is deleted.

I know about firejail {--ls | --get | --put} but is there a more conveniet way to share a directory?

Originally created by @damadmai on GitHub (Jan 6, 2018). Original GitHub issue: https://github.com/netblue30/firejail/issues/1716 I'm using `firejail --private-home=.mozilla firefox %u --no-remote` for Firefox. So that my firefox profile, history etc. is not changed but my settings are used. How to achieve making an directory accessible outside this sandbox like ~/Downloads? Currently this folder is empty and I it not possible to exchange files with the sandbox. They are lost on terminating the process because the temporary filesystem is deleted. I know about `firejail {--ls | --get | --put}` but is there a more conveniet way to share a directory?
gitea-mirror 2026-05-05 07:33:38 -06:00
Author
Owner

@netblue30 commented on GitHub (Jan 7, 2018):

is there a more conveniet way to share a directory?

If you are the only one using the computer, you can create a directory outside your home and configure Firefox to use it as Downloads:

$ sudo mkdir /tmp-downloads
$ sudo chown username:username /tmp-downloads

The only thing in Firejail blacklisting files outside the regular Unix file system hierarchy is --apparmor option.

<!-- gh-comment-id:355822951 --> @netblue30 commented on GitHub (Jan 7, 2018): > is there a more conveniet way to share a directory? If you are the only one using the computer, you can create a directory outside your home and configure Firefox to use it as Downloads: ````` $ sudo mkdir /tmp-downloads $ sudo chown username:username /tmp-downloads ````` The only thing in Firejail blacklisting files outside the regular Unix file system hierarchy is --apparmor option.
Author
Owner

@chiraag-nataraj commented on GitHub (Jul 15, 2018):

@damadmai I actually used to use private-home before but found it tedious for exactly this reason. Nowadays, my regular profile does whatever it does (I have many privacy addons), but I also wrote up a little script to create a temporary firefox profile and copy over specific files/folders (see #2031 for the motivation I had for writing this script). The latest version of the script can be found at firefox.common (you can disable the private-lib stuff if you so wish, but imo it adds a bit of additional security and should just work OOTB). Note that the private-lib parts require gen_libraries. If you decide to use the script, please open an issue in that repository if you have problems.

<!-- gh-comment-id:405115566 --> @chiraag-nataraj commented on GitHub (Jul 15, 2018): @damadmai I actually used to use `private-home` before but found it tedious for exactly this reason. Nowadays, my regular profile does whatever it does (I have many privacy addons), but I also wrote up a little script to create a temporary firefox profile and copy over specific files/folders (see #2031 for the motivation I had for writing this script). The latest version of the script can be found at [firefox.common](https://github.com/chiraag-nataraj/firejail-profiles/blob/master/firefox.common) (you can disable the `private-lib` stuff if you so wish, but imo it adds a bit of additional security and _should_ just work OOTB). Note that the `private-lib` parts require [gen_libraries](https://github.com/chiraag-nataraj/firejail-profiles/blob/master/gen_libraries). If you decide to use the script, please open an issue in that repository if you have problems.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: github-starred/firejail#1158
No description provided.