[PATCH 3/3] activation: optionally, use systemd for system bus activation

Colin Walters walters at verbum.org
Wed Jul 7 13:32:00 PDT 2010

On Wed, Jun 23, 2010 at 12:12 PM, Lennart Poettering <mzqohf at 0pointer.de> wrote:

> +  if (dbus_message_is_signal (message, "org.freedesktop.systemd1.Activator", "ActivationFailure"))
> +    {
> +      BusContext *context;
> +
> +      context = bus_connection_get_context (connection);
> +      return dbus_activation_systemd_failure(bus_context_get_activation(context), message);
> +    }
> +

I don't like having a magic signal that the bus processes here.
There's no checking of the sender which is clearly wrong.
Coincidentally I was thinking earlier today it'd be nice if the bus
had a "private" management interface on a separate socket.  Say
/var/run/dbus/system_bus_admin_socket.  That could be locked down
cleanly and separately from the system bus, and we could add hidden
interfaces there for e.g. systemd integration, rather than exposing
them to the world as a stable interface.

The multiple sockets trick plays well with SELinux too; I'm pretty
sure libvirt does this.

> +  fprintf (stderr, DBUS_DAEMON_NAME " [--version] [--session] [--system] [--config-file=FILE] [--print-address[=DESCRIPTOR]] [--print-pid[=DESCRIPTOR]] [--fork] [--nofork] [--introspect] [--address=ADDRESS] [--systemd-activation]\n");

Kind of gross.  I'd honestly prefer just a configure switch
--with-activation=systemd or something.  Why make it a runtime option?

More information about the dbus mailing list