mirror of
https://github.com/netblue30/firejail.git
synced 2026-05-15 14:16:14 -06:00
[GH-ISSUE #421] okular and gwenview profiles #304
Labels
No labels
LTS merge
LTS merge
bug
bug
converted-to-discussion
doc-todo
documentation
duplicate
enhancement
file-transfer
firecfg
firejail-in-firejail
firetools
graphics
help wanted
information_old
installation
invalid
modif
moved
needinfo
networking
notabug
notourbug
old-version
overlayfs
packaging
profile-request
pull-request
question
question_old
removal
runtime-permissions
sandbox-ipc
security
stale
wiki
wiki
wontfix
wordpress
workaround
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: github-starred/firejail#304
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @curiosity-seeker on GitHub (Apr 9, 2016).
Original GitHub issue: https://github.com/netblue30/firejail/issues/421
I suggest to add profiles for okular and gwenview. The following settings work for me:
I've chosen net none as reportedly ransomware has also been found in pdf and image files. I think it's worth consideration to also adjust the evince profile accordingly.
@ghost commented on GitHub (Apr 9, 2016):
Personally I think that global profiles that are distributed to everyone should not restrict legitimate uses. Allow whatever the program wants, and no more. It's better that each user tightens his profile to his own needs, than to cut functionality and have users bitch at you.
You can put your own profiles in
~/.config/firejail/and include the global profile. That's how I do it, and I agree with you that some programs have no business accessing any network.As for the profile, I would add a
noblacklistat the top, with the program's config dir.You could try
blacklisting/etcandprivate-etcany files that it needs.Try
private-binwith only the program's binary allowed.Also
protocol.@curiosity-seeker commented on GitHub (Apr 9, 2016):
Well, I haven't seen any negative side-effects for both programs by doing this.
I know, and it's something I'm doing, too.
Why should I do this if that config dir is not blacklisted by one of the .inc files? It would be a different situation if a whitelist approach were applied - but as long as whitelist globbing (#216) is not yet available, it's difficult to implement this for those 2 programs.
Yes, that's something I could try.
Not necessary with net none.
@ghost commented on GitHub (Apr 9, 2016):
You didn't, but maybe someone else would. What does the program need network access for?
But it is. As far as I can tell, whenever a new profile is added, its config dir is also added to disable-programs.inc, hence having to noblacklist before.
I assumed the case without
net none.Also
private-devand maybeprivate-tmp.@curiosity-seeker commented on GitHub (Apr 10, 2016):
Good question. Why do a pdf reader and an image viewer need network access? I'd say under normal circumstances they don't.
That's incorrect, IMHO. Only the specific entries in the .inc files are blacklisted, e.g., ~/.mozilla or ~/.config/chromium. That's why those directories must be noblacklisted in the Firefox and Chromium profiles, respectively. While other pofiles, e.g. the ones for evince or kmail, do not contain corresponding noblacklist entries for their config dirs - simply because they are not blacklisted in the .inc files.
@ghost commented on GitHub (Apr 12, 2016):
I agree.
Yes, but the question is why are they not blacklisted in disable-programs.inc? Is it because they are missing, or is that because they don't qualify? I would guess it's because they are missing, but netblue knows better.
@netblue30 commented on GitHub (Apr 12, 2016):
Because they are missing, we'll have to add them.
@curiosity-seeker commented on GitHub (Apr 12, 2016):
FWIW, I've added nogroups and private-* rules for both profiles. For gwenview this seems to work for me:
And for okular:
So far no problems. But other KDE users might want to try those settings, too.
@ghost commented on GitHub (Apr 12, 2016):
Lookie here what I got.
I went through every single motherfucking profile and checked whether it's been blacklisted or what. I took note of every profile that was neither blacklisted, nor had any hints as to the ~/.config dirs and I did not have it installed, so couldn't check for myself.
Exclamation marks are daemons, so they probably have no ~/.config dirs.
Wine noblacklists Steam, and I wonder why. Is that supposed to be?
SSH and GnuPG I didn't know whether it should be included in disable-programs, because it's already blacklisted in disable-common.
@netblue30 commented on GitHub (Apr 13, 2016):
@avoidr: That was cool, thanks for the patch!
What are the latest okular and gwenview you guys have running, let's bring them in.
@ghost commented on GitHub (Apr 13, 2016):
You're welcome! I'm happy it is appreciated.
I don't have gwenview in the repo. I'll look at okular today.
@curiosity-seeker commented on GitHub (Apr 13, 2016):
@netblue30 : I have gwenview 15.12.3-1 and okular 15.12.3-1 running on Manjaro.
The complete gwenview profile is this one:
And for okular:
@ghost commented on GitHub (Apr 13, 2016):
@curiosity-seeker: If you don't include
groupinprivate-etc, there is no need fornogroups.@ghost commented on GitHub (Apr 13, 2016):
Actually, network should be disabled. Documents have no business accessing any network, ever. Shit does more harm than good.
And I won't try okular, because fug it. This profile looks good. Just remember to blacklist config dirs in
disable-programs.incand to noblacklist them in the profiles again.@curiosity-seeker commented on GitHub (Apr 14, 2016):
Ah - yes! Thanks, good point.
@curiosity-seeker commented on GitHub (Apr 16, 2016):
I had to add
lprto the private-bin line in the okular profile. Otherwise it wouldn't be able to print. Oddly, this is not necessary for gwenview.
@netblue30 commented on GitHub (Apr 18, 2016):
OK, I've managed to check okular and gwenview profiles, all credits go to @curiosity-seeker, thanks! This is what I changed:
The profiles are on the master branch.
@curiosity-seeker commented on GitHub (Apr 18, 2016):
Thanks, @netblue30 ! It's interesting that distros behave differently ...
@curiosity-seeker commented on GitHub (Apr 22, 2016):
Just for the record: I had to add
bashto private-bin in both profiles - otherwise pdf files and images wouldn't open when launched in the file manager (krusader).@Utini2000 commented on GitHub (Aug 19, 2024):
How can I re-enable the capability to open .pdf from a smb share with this standard profile?
Because we life in a world where I need my system to actually let me to work :)
Edit:
okular.local:
protocol unix,inet,inet6,netlink
ignore net
@kmk3 commented on GitHub (Aug 19, 2024):
This issue is from 8 years ago and is not directly related to your problem.
If a profile is not working, open a new issue and follow the bug report
template: