| > Make clients store a cookie or something and only reply if they prove ownership of it Unix domain socket authentication is stronger and doesn't require storing cookies on the client side. > what the hell is your threat model here? The attacker is just going to ptrace firefox and read all the secrets anyway. Which is why you can (and people do, e.g. flatpak) run applications where ptrace or global filesystem access is blocked. Which is why portals exist and why there shouldn't be a "get all secrets via dbus" escape hatch. > I _want_ other programs to be able to read secrets (e.g. keyring administrators, .netrc-style shared secrets, etc.) Then don't use it? Secure defaults matter for most users. > Do you hate a{sv}? If you propose JSON as alternative, you are going to make me laugh. Find the *kwargs here: https://wayland.app/protocols/xdg-shell Etc. etc. This isn't the 90s anymore. |
And pointless here, since everything runs under the same uid. You need to authenticate this is the same browser that stored this secret, not that this is the same uid (useless), or the same pid, or any other concept that unix domain socket authentication understands.
> Which is why you can (and people do, e.g. flatpak) run applications where ptrace or global filesystem access is blocked. Which is why portals exist and why there shouldn't be a "get all secrets via dbus" escape hatch.
In which case they do not connect to the same D-Bus "bus", and the problem is again non-existent. See how flatpak sandoxing does it.
> Then don't use it? Secure defaults matter for most users.
Right until they notice they can no longer view the keyring contents, or any other stupid limitation most desktop users couldn't care about.
In fact, if you do not need a shared secrets service, and your applications are containerized... why do you need a secrets IPC at all? Just let each program store its secrets in some of its supposedly private storage...
> Find the *kwargs here: https://wayland.app/protocols/xdg-shell
Much better to have a million non-extendable protocols competing with each other. To this day there are two protocols (at least) for exposing the address of the DbusMenu service of a surface, one for gnome-shell and one for kwin. So much for the uglyness of X atoms. And this has nothing really to do with the design of the IPC mechanism itself...