GUID ? What for ?

Havoc Pennington hp at
Mon Nov 6 07:03:57 PST 2006

10function wrote:
> Hello,
> May be i missed something while reading the DBus docs but i can't figure what the 'guid' value associated with a BUS path (local or remote) is used for ...
> [ like in : 'unix:path=/usr/local/var/run/dbus/system_bus_socket,guid=84b14345e4aaba5daf1651b672abbd00' ]
> Could someone give my clues/hints/lights about the guid usage ?

That guid identifies the server you are connecting to.

The basic idea is that if you implemented a dbus binding that concealed 
the concept of a connection (perhaps only exposing "objects"), it could 
transparently reuse connections instead of opening dozens of connections 
to the same server.

dbus_connection_open() will check whether a connection is already open 
to that guid and return the existing connection if so.

The guid is used instead of string equality on the address just because 
it's less fragile and doesn't introduce issues like whether two paths 
point to the same socket.


More information about the dbus mailing list