mirror of
https://github.com/netblue30/firejail.git
synced 2026-05-15 14:16:14 -06:00
[GH-ISSUE #1470] No sound in Firefox (with apulse) #985
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#985
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 @Hund on GitHub (Aug 15, 2017).
Original GitHub issue: https://github.com/netblue30/firejail/issues/1470
I'm running Funtoo with Firefox 54 and Firejail 0.9.46. Since I don't like Pulseaudio, I installed apulse to make the sound work via ALSA instead. The only problem is that I get no sound if I run Firefox with Firejail.
What's wrong?
@reinerh commented on GitHub (Aug 16, 2017):
apulse uses LD_PRELOAD for calling different functions than intended.
And firejail is a suid binary. LD_PRELOAD doesn't work with suid binaries.
But using LD_PRELOAD inside the jail should work (though not completely sure).
So it probably depends on how you are starting the browser. ("apulse firejail firefox" vs. "firejail apulse firefox")
@Hund commented on GitHub (Aug 17, 2017):
The command
apulse firejail firefoxlets me start Firefox, but I do not get any sound. And the commandfirejail apulse firefoxresults in:And the output from the terminal:
@SkewedZeppelin commented on GitHub (Aug 17, 2017):
Try "firejail --profile=/etc/firejail/firefox.profile" apulse /usr/bin/firefox"
Also please give this a try https://github.com/i-rinat/apulse#access-errors-in-do_connect_pcm
@Hund commented on GitHub (Aug 17, 2017):
It didn't work.
Regarding the other link, I'm not sure if I explained myself poorly, but sound works in Frirefox if I don't run it with Firejail. :)
@SkewedZeppelin commented on GitHub (Aug 17, 2017):
But that error you just posted is what that link explains how to solve. Why that error isn't happening outside of Firejail I don't know, but its worth a try
@Hund commented on GitHub (Aug 17, 2017):
Oh, I see. I tried that now and it didn't help.
@netblue30 commented on GitHub (Aug 18, 2017):
Currently apulse is not supported, we'll try to bring it in. Try something much simpler like speaker-test (firejail --noprofile apulse speaker-test).
@h1z1 commented on GitHub (Aug 19, 2017):
Rather then LD_PRELOAD you could modify the rpath of firefox-bin or install apulse system wide. You sure you gave access to the right device? Anything in your asoundrc perhaps?
Two other shell variables you can tweak are ALSA_CARD and ALSA_PCM_CARD (there are others but those are the basics).
@Hund commented on GitHub (Aug 19, 2017):
@netblue30:
firejail --noprofile apulse speaker-testworks.@h1z1: I installed apulse via my package manager, so I assume it's available system wide?
I don't have a asoundrc file and I'm not sure what do to with
ALSA_CARDorALSA_PCM_CARD.@h1z1 commented on GitHub (Aug 19, 2017):
@Hund make sure something like
speaker-test -c2 -Ddefault.. Outputs to the right speakers. The two environment variables I gave override whatever default it's detecting.
Also what is the output of
cat /proc/asound/cards? Don't remember tbh if it's something I did or firejail but the config for alsa is not whitelisted, thus not read. At least there's only one place I see a whitelist and it's for ~/.asoundrc which is only part.@h1z1 commented on GitHub (Aug 19, 2017):
Not entirely sure why the above comment was edited by @Fred-Barclay or that it was even possible??
@Fred-Barclay commented on GitHub (Aug 19, 2017):
@h1z1 Sorry about that. I just added code tags to the post to make
this
look like
this.Cheers!
Fred
@Hund commented on GitHub (Aug 21, 2017):
Hm, I went back to Gentoo (for other reasons) and it works just fine now. I'm sure I haven't changed anything? Thank you for your time. :)