[Webkit-unassigned] [Bug 280684] New: speech synthesis with libspiel does not work with bubblewrap sandbox on

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue Oct 1 09:00:34 PDT 2024


https://bugs.webkit.org/show_bug.cgi?id=280684

            Bug ID: 280684
           Summary: speech synthesis with libspiel does not work with
                    bubblewrap sandbox on
           Product: WebKit
           Version: WebKit Local Build
          Hardware: Unspecified
                OS: Unspecified
            Status: NEW
          Severity: Normal
          Priority: P2
         Component: WebKitGTK
          Assignee: webkit-unassigned at lists.webkit.org
          Reporter: q66 at octaforge.org
                CC: bugs-noreply at webkitgtk.org

Added in https://bugs.webkit.org/show_bug.cgi?id=270742.

The speech synthesis does not work because libspiel is unable to find any providers. This is because our xdg-dbus-proxy configuration does not allow the provider names to be seen in the filter. Unfortunately, we cannot wildcard them because xdg-dbus-proxy does not allow wildcarding prefixes. That clashes with how the speech provider names work; e.g. for espeak you have `org.espeak.Speech.Provider`, for something else you have `org.somethingelse.Speech.Provider` (the `.Speech.Provider` suffix is the same always). Since the dbus proxy does not filter them correctly, the `ListNames` and `ListActivatableNames` output does not include the provider (which libspiel checks for) and it goes undetected.

I was able to make it work specifically for espeak with this little patch:

```
--- a/Source/WebKit/UIProcess/Launcher/glib/XDGDBusProxy.cpp
+++ b/Source/WebKit/UIProcess/Launcher/glib/XDGDBusProxy.cpp
@@ -85,6 +85,10 @@ std::optional<CString> XDGDBusProxy::dbusSessionProxy(const char* baseDirectory,
     if (allowPortals == AllowPortals::Yes)
         m_args.append("--talk=org.freedesktop.portal.Desktop");

+#if USE(SPIEL)
+    m_args.append("--talk=org.espeak.Speech.Provider");
+#endif
+
     if (!g_strcmp0(g_getenv("WEBKIT_ENABLE_DBUS_PROXY_LOGGING"), "1"))
         m_args.append("--log");

```

This is, of course, not correct, as it does not match providers generically (otherwise i'd open a pull request). I'm not sure what the best way would be to match them generically. Thoughts?

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20241001/4b396cab/attachment.htm>


More information about the webkit-unassigned mailing list