[systemd-devel] siphash24 gives unmatched bloom_mask and bloom_filter?
eshark77 at 163.com
eshark77 at 163.com
Thu Jun 4 05:07:28 PDT 2015
Hi, All,
I use libsystemd.so for the kdbus protocol layer, and I met a question that I added a signal matching rule by sd_bus_add_match() , then I sent signal by sd_bus_send().
But I couldn't receive this signal because its bloom_filter caculated by siphash24() NOT match the bloom_mask which was also caculated by siphash24().
For example , when adding matching rule for " type='signal',interface='service.a.interface',path='/service/a',member='com_0yunos_0spms_0uninstall',arg0path='/p1/p2/p3' " by sd_bus_add_match(),
I got the following bloom_mask:
bloom: mask[0] = 0x40000c08000080d4
bloom: mask[1] = 0x8804104020100000
bloom: mask[2] = 0x40000610
bloom: mask[3] = 0x8000000000408
bloom: mask[4] = 0x120000000101000
bloom: mask[5] = 0x8048000022002000
bloom: mask[6] = 0x4000402000000110
bloom: mask[7] = 0x100000
But when I sent the exact same signal by sd_bus_send(), I got the following bloom_filter:
bloom: filter[0] = 0x60000e0801020086
bloom: filter[1] = 0x8804114084100000
bloom: filter[2] = 0x2000400c40400710
bloom: filter[3] = 0x208000000040528
bloom: filter[4] = 0x120010080002000
bloom: filter[5] = 0x8058000122406000
bloom: filter[6] = 0xc22000104111
bloom: filter[7] = 0x800300a120800000
Obviously, filter[0] & maks[0] != mask[0], which caused that I couldn't receive the signal.
I also tested with "type='signal',interface='service.a.interface',path='/service/a',member='com_0yunos_0spms_0uninstall' " , which works OK.
Could anyone gives me some suggestion?
Thanks a lot!
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/systemd-devel/attachments/20150604/427c00b6/attachment.html>
More information about the systemd-devel
mailing list