[systemd-devel] Compatibility between D-Bus and kdbus

Daniel Mack daniel at zonque.org
Fri Oct 3 11:35:50 PDT 2014


On 10/02/2014 05:08 PM, Lennart Poettering wrote:
> On Thu, 02.10.14 15:59, Simon McVittie (simon.mcvittie at collabora.co.uk) wrote:
> 
>> It would probably be good if there was an official way to serialize
>> kdbus messages, with their full kdbus_msg headers, into a blob of bytes,
>> suitable for recording in files. Will Thompson proposed pcap as a common
>> container format for D-Bus messages when read/written by
>> monitoring/debugging tools like his Bustle utility, and it seems as good
>> as any other. Perhaps we could reserve D-Bus message format version 3
>> for an encapsulated kdbus_msg, containing a nested version-2 message in
>> its payload? Or define separate pcap packet types for "D-Bus message"
>> (already exists) and "encapsulated kdbus_msg" (doesn't yet)?
> 
> I am happy to add a pcap writer to busctl... Sounds like an easy
> job. Also fine with Dumping out kdbus_msg of course isn't that easy
> though as it might reference external memfds and memory areas... 

I've already implemented kdbus support into libpcap[1], so every program
that is able to receive traffic via that library can eventually capture
kdbus traffic from all accessible buses. We could, of course, also add
pcap support to busctl.

Also, I have a wireshark dissector for kdbus[2] up and running, which is
able to both read files and do live capture via libpcap.

I'm holding back patches for both projects until we've made kdbus public
and consider it stable. Until then, we still have the liberty of
changing internals and maybe break the ABI. But everyone who dares
giving those branches a try, I'd appreciate some feedback.

 [1] https://github.com/zonque/libpcap/tree/kdbus
 [2] https://github.com/zonque/wireshark/tree/kdbus


Thanks,
Daniel



More information about the dbus mailing list