mirror of
https://github.com/netblue30/firejail.git
synced 2026-05-15 14:16:14 -06:00
[GH-ISSUE #6484] firefox: tts fails in reader view: cannot access espeak-ng #3288
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#3288
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 @Liorst4 on GitHub (Sep 21, 2024).
Original GitHub issue: https://github.com/netblue30/firejail/issues/6484
Description
When using reader view in firefox, the text to speech feature will fail, because it can't access espeak-ng and its data files.
Firefox on linux uses speech-dispatcher for text to speech.
speech-dispatcher may use espeak-ng (I think it has other backends).
So firefox needs to be able to access the
espeak-ngbinary and its data files.https://freebsoft.org/speechd
https://github.com/espeak-ng/espeak-ng
Steps to Reproduce
Run firefox under firejail.
Find an article with lots of text, use the reader view button.
In reader view press the headphones buttons and then the play buttons.
https://support.mozilla.org/en-US/kb/firefox-reader-view-clutter-free-web-pages
Expected behavior
Firefox should use espeak-ng to play a reading of the text.
Actual behavior
Speech dispatcher will play an error message about not being able to find any modules.
Something along the lines of "Its seems like your speech dispatcher is working but none of its sound modules are"
Additional context
I tried to play around with the profile config files.
I was able to make the text to speech work, but it broke other stuff, so this solution is not PR worthy.
Checklist
/usr/bin/vlc) "fixes" it).https://github.com/netblue30/firejail/issues/1139)browser-allow-drm yes/browser-disable-u2f noinfirejail.configto allow DRM/U2F in browsers.--profile=PROFILENAMEto set the right profile. (Only relevant for AppImages)@kmk3 commented on GitHub (Sep 22, 2024):
Basic debugging information is missing; please follow the bug report template:
@Liorst4 commented on GitHub (Sep 27, 2024):
Firejail logs
Running
firejail --private --trace=/tmp/trace.log firefox https://firejail.wordpress.com/blog/entering the reader mode and pressing the play button resulted in speech-dispatcher reading an error message aloud.Notable system calls in the log
I think that this is the firefox code that calls speech-dispatcher
Speech dispatcher logs
After some digging I found out that speech dispatcher does write logs, but in /run directory (inside the firejail)
I was able to get the by loading the log files inside firefox itself
file:///run/user/$UID/speech-dispatcher/log/espeak-ng.log
file:///run/user/$UID/speech-dispatcher/log/speech-dispatcher.log
@rusty-snake commented on GitHub (Sep 27, 2024):
So does it work if you whitelist it?
@Liorst4 commented on GitHub (Sep 27, 2024):
Its been a while since I wrote a profile.
I tried, but it didn't go well 😅
At first I tried to
noblacklistthe data driectory, but it didn't do anything.When I explicitly
whitelisted it, it worked, but other files weren't whitelisted so unrelated stuff broke.@kmk3 commented on GitHub (Sep 27, 2024):
Missing information:
firejail --version):was compiled (
git rev-parse HEAD):Make sure you're using at least firejail 0.9.72.
Unless you want to override the entire /etc/firejail/firefox.profile, it's
usually better to just put all changes in ~/.config/firejail/firefox.local and
remove ~/.config/firejail/firefox.profile if it exists.
Props for this debugging.
Does it work with just the following in firefox.local?
Using the above is likely part of the issue, as /etc is not whitelisted for
firefox in 0.9.72.
There were many changes to /etc handling in 0.9.73, so does it work with the
following while using firejail-git?