]> git.ipfire.org Git - thirdparty/systemd.git/commit
bus-message: avoid an infinite loop on empty structures
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Mon, 9 Jul 2018 08:52:51 +0000 (10:52 +0200)
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Tue, 2 Oct 2018 09:53:20 +0000 (11:53 +0200)
commitec6bda56cbca9509b1abde1122645630caca877c
tree3de7092226217b62dd504c19b649ff39c6469a84
parent6d1e0f4fcba8d6f425da3dc91805db95399b3c8b
bus-message: avoid an infinite loop on empty structures

The alternative would be to treat gvariant and !gvariant messages differently.
But this is a problem because we check signatures is variuos places before we
have an actual message, for example in sd_bus_add_object_vtable(). It seems
better to treat things consistent (i.e. follow the lowest common denominator)
and disallow empty structures everywhere.
src/libsystemd/sd-bus/bus-message.c
src/libsystemd/sd-bus/bus-signature.c
src/libsystemd/sd-bus/test-bus-gvariant.c
src/libsystemd/sd-bus/test-bus-marshal.c
src/libsystemd/sd-bus/test-bus-signature.c
test/fuzz/fuzz-bus-message/crash-26bba7182dedc8848939931d9fcefcb7922f2e56 [new file with mode: 0644]
test/fuzz/fuzz-bus-message/timeout-08ee8f6446a4064db064e8e0b3d220147f7d0b5b [new file with mode: 0644]