-
Notifications
You must be signed in to change notification settings - Fork 584
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
profiles: telegram: allow opening links (xdg-open) #4783
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -8,6 +8,9 @@ include globals.local | |
noblacklist ${HOME}/.TelegramDesktop | ||
noblacklist ${HOME}/.local/share/TelegramDesktop | ||
|
||
# Allow opening hyperlinks | ||
include allow-bin-sh.inc | ||
|
||
include disable-common.inc | ||
include disable-devel.inc | ||
include disable-exec.inc | ||
|
@@ -41,7 +44,7 @@ seccomp.block-secondary | |
shell none | ||
|
||
disable-mnt | ||
private-bin telegram,Telegram,telegram-desktop | ||
private-bin bash,sh,telegram,Telegram,telegram-desktop,xdg-open | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Why bash? xdg-open is a shell-script, consider There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
I believe enabling There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Do not believe, test 😉. private-bin follows symlinks IIRC and even if it don't there are other shells commonly used as
(Fedora Linux 35; $ firejail --noprofile --private-bin=sh,ls ls -l /usr/bin
bash
ls
sh -> /usr/bin/bash I guess you had tested with only There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
On my system for xdg-open to work at all:
yeah, I think this is the way to go. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
That's correct, I think I tested with only
I think There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
It don't, read the issues title in your comment:
If I get you right (sh->dash; IMHO
Because you still run There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
I don't understand what you mean. A symlink points to a (text) path; it $ readlink /bin/sh
dash
$ /bin/sh -c 'echo yes'
yes
$ cd /tmp
$ cp -P /bin/sh .
$ readlink ./sh
dash
$ ./sh -c 'echo yes'
bash: ./sh: No such file or directory
$ echo 'echo hello world' >dash
$ chmod +x dash
$ ./dash
hello world
$ ./sh
hello world Do you mean that sh points to just "bash" outside of firejail but inside of it There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. What I want to tell is that I don't care about There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I just tried removing There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. (Continued on #4790) |
||
private-cache | ||
private-dev | ||
private-etc alsa,alternatives,ca-certificates,crypto-policies,fonts,group,ld.so.cache,ld.so.preload,localtime,machine-id,os-release,passwd,pki,pulse,resolv.conf,ssl,xdg | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Suggestion: use our inc file specifically designed for situations like this (instead of the two noblacklists)
include allow-bin-sh.inc
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice suggestion, thank you @glitsj16.