mirror of
https://github.com/netblue30/firejail.git
synced 2026-05-15 14:16:14 -06:00
[GH-ISSUE #2956] No sound in firefox until started without firejail once. #1851
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#1851
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 @lupusbytes on GitHub (Sep 9, 2019).
Original GitHub issue: https://github.com/netblue30/firejail/issues/2956
Hello.
I'm experiencing this bug where there is no sound in firefox, if I start it with firejail.
This is the output.
lupus@thinkpad ~ $ firejail firefox [2/2] Reading profile /etc/firejail/firefox.profile Reading profile /etc/firejail/firefox-common.profile Reading profile /etc/firejail/disable-common.inc Reading profile /etc/firejail/disable-devel.inc Reading profile /etc/firejail/disable-exec.inc Reading profile /etc/firejail/disable-interpreters.inc Reading profile /etc/firejail/disable-programs.inc Reading profile /etc/firejail/whitelist-common.inc Reading profile /etc/firejail/whitelist-var-common.inc Parent pid 12913, child pid 12914 Warning: An abstract unix socket for session D-BUS might still be available. Use --ne t or remove unix from --protocol set. Post-exec seccomp protector enabled Seccomp list in: !chroot, check list: @default-keep, prelist: unknown, Child process initialized in 76.40 ms Warning: an existing sandbox was detected. /usr/bin/firefox will run without any addi tional sandboxing features JavaScript warning: moz-extension://341144dd-7b39-4a91-bdf4-add9480cfd9c/content_scri pts/injected.js, line 7: unreachable code after return statement JavaScript error: resource://gre/modules/ExtensionContent.jsm, line 554: TypeError: A rgument 1 of PrecompiledScript.executeInGlobal is not an object. [Child 56, MediaDecoderStateMachine #1] WARNING: 7fbf90b3ee60 OpenCubeb() failed to i nit cubeb: file /var/tmp/notmpfs/portage/www-client/firefox-69.0/work/firefox-69.0/do m/media/AudioStream.cpp, line 305 [Child 56, MediaDecoderStateMachine #1] WARNING: Decoder=7fbf89f53200 [OnMediaSinkAu$ ioError]: file /var/tmp/notmpfs/portage/www-client/firefox-69.0/work/firefox-69.0/do$ /media/MediaDecoderStateMachine.cpp, line 3641If I then close Firefox and start it without firejail, like "/usr/bin/firefox", then the sound is working.
After this, if I open firefox with firejail again, then the sound will work until next reboot.
I'm running Gentoo Linux, kernel 5.2.13, and firejail is built from the live github version, 2 days ago. Firefox 69.0 is also built from source.
I have tried all the
firecfg --fix-soundandsudo firecfg. But this problem is persisent every time I reboot.@ghost commented on GitHub (Sep 10, 2019):
The warning suggests that you're starting firefox from within another firejail sandbox, which is non-standard and probably the cause of your issue. When you ran
sudo firecfgfirejail placed a symlink called firefox in/usr/local/bin(amongst all other supported applications). Does the issue persist when you undo this viasudo firecfg --clean, kill any lingering firefox processes and runfirejail /usr/bin/firefoxagain?@lupusbytes commented on GitHub (Sep 10, 2019):
My bad.. I didn't stop to think that when i typed
firejail firefox, it would actually runfirejail /usr/local/bin/firefoxwhich is already a symlink.However, If i run:
lupus@thinkpad ~ $ firejail /usr/bin/firefox Reading profile /etc/firejail/firefox.profile Reading profile /etc/firejail/firefox-common.profile Reading profile /etc/firejail/disable-common.inc Reading profile /etc/firejail/disable-devel.inc Reading profile /etc/firejail/disable-exec.inc Reading profile /etc/firejail/disable-interpreters.inc Reading profile /etc/firejail/disable-programs.inc Reading profile /etc/firejail/whitelist-common.inc Reading profile /etc/firejail/whitelist-var-common.inc Parent pid 16323, child pid 16324 Warning: An abstract unix socket for session D-BUS might still be available. Use --ne Post-exec seccomp protector enabled Seccomp list in: !chroot, check list: @default-keep, prelist: unknown, Child process initialized in 67.32 ms JavaScript warning: moz-extension://341144dd-7b39-4a91-bdf4-add9480cfd9c/content_scripts/injected.js, line 7: unreachable code after return statement JavaScript error: resource://gre/modules/ExtensionContent.jsm, line 554: TypeError: Argument 1 of PrecompiledScript.executeInGlobal is not an object. JavaScript warning: moz-extension://341144dd-7b39-4a91-bdf4-add9480cfd9c/content_scripts/injected.js, line 7: unreachable code after return statement [Child 56, MediaDecoderStateMachine #1] WARNING: 7f287ab2cd90 OpenCubeb() failed to init cubeb: file /var/tmp/notmpfs/portage/www-client/firefox-69.0/work/firefox-69.0/dom/media/AudioStream.cpp, line 305 [Child 56, MediaDecoderStateMachine #1] WARNING: Decoder=7f287aae1e00 [OnMediaSinkAudioError]: file /var/tmp/notmpfs/portage/www-client/firefox-69.0/work/firefox-69.0/dom/media/MediaDecoderStateMachine.cpp, line 3641I still get the AudoStream.cpp error and MediaDecoderStateMachine.cpp errors.
As you suggested i tried
sudo firecfg --cleanfirst and thenfirejail /usr/bin/firefox.The issue does persist unfortunately.
As I described in my original post, the fix for me is still to start firefox once, without firejail.
I tested it a bit further. When the browser is running, without firejail, I have to trigger some sort of sound, like going to YouTube, for the next firejailed instance to also have sound, else it will not work.
I know little about the internals of Firefox and firejail, but it could seem to me there some sort of pulseaudio socket or whatever will not be created if it's only running within firejail.
@rusty-snake commented on GitHub (Sep 10, 2019):
Works it with
firejail --noprofile firefox?/var/tmp/notmpfs/portage/www-client/there do you build firefox but there is no library/executable , right?@lupusbytes commented on GitHub (Sep 10, 2019):
Yes, sound works with
firejail --noprofile firefoxWhat does --noprofile mean exactly ?
You are correct, it was built there,
/var/tmp/notmpfs/portage/www-client/does not exist anymore.@rusty-snake commented on GitHub (Sep 10, 2019):
Ir disable the usage of profiles, so now we now that one option in firefox.profile or firefox-common.profile is causing this and not firejail itself. I don't have ideas what option could causeing this, so you need not try it out (I know its ugly if you have to reboot to test). But you could also watch with syslog if you haven't already.
@rusty-snake commented on GitHub (Sep 28, 2019):
@lupusbytes ping 🙄
@rusty-snake commented on GitHub (Oct 13, 2019):
@lupusbytes
I'm closing here due to inactivity, please fell free to reopen if you still have this issue.
@lupusbytes commented on GitHub (Feb 2, 2020):
I finally had some time to dig around..
Using firemon, i noticed that it was trying to execute
/usr/bin/pulseaudio --start --log-target=syslogOn my system, pulseaudio doesn't get automatically started on boot, only the first time the audio is needed.
When the very first time sound is needed by the system, and it's by firefox and firefox is running inside firejail, it fails to start pulseaudio.
Should I somehow whitelist pulseaudio ?
@rusty-snake commented on GitHub (Feb 2, 2020):
Then pulseaudio is started in the firefox sandbox, this may cause issues. Maybe a it is better to start pulse with firefox in a wrapper script like
start_pulseaudio ; firejail firefox.@lupusbytes commented on GitHub (Feb 2, 2020):
That makes sense, I should probably just start pulseaudio along with my window manager.