• Michael Catanzaro's avatar
    Remove GSettings use from web process · e99ecd02
    Michael Catanzaro authored
    Our scheme to sync settings from the host to the web process extension
    has failed, because it depended on the web process's ability to read
    host settings: i.e. its design never actually worked, since the whole
    purpose was to avoid depending on host settings, which are inaccessible
    inside the sandbox.
    Instead of fixing this, we can just not allow the web process to read
    Epiphany settings at all. Toolkit level settings should go through
    either XSettings or xdg-desktop-portal. Add an assertion to ensure the
    web process crashes if it tries to use ephy_settings_get() to avoid
    mistakes here.
    Currently we use two settings: do-not-track, and remember-passwords. We
    can remove the do-not-track setting and just always strip tracking query
    parameters from URLs, especially since this setting is hidden since 3.34
    anyway. In the future, we'll want to remove this code and let ITP do its
    thing instead. As for remember-passwords, we can manually sync the state
    of this setting to the web process using D-Bus.
    Finally, remove the unused browser_mode variable.
    Note this goes a long way to fixing #865, because we no longer use a
    custom GKeyfileSettingsBackend for web process permissions. Also note
    the removed code was leaking a GKeyfileSettingsBackend, contributing to
    inotify overuse.
    Fixes #993
ephy-web-process-extension-proxy.h 4.55 KB