- 23 Jun, 2020 1 commit
-
-
Florian Klink authored
In some edge cases (like cross compilation), it might be desirable to explicitly configure the path to the pkgconfig binary. Support doing this via the `PKG_CONFIG` environment variable.
-
- 22 Jun, 2020 1 commit
-
-
sg35zh authored
rationale: on some systems, MYMETA.* is parsed in order to generate rpm deps and those deps ends as runtime dependencies whereas they really are builtime deps for tests
-
- 10 May, 2020 6 commits
-
-
-
Similar optional argument is already supported by has_property() method.
-
-
Method append_variant() expects raw (non-variant) value as its argument, which is then put into DBus structure. So when variant value is provided, first unpack it and then put it into append_variant() method. This change fixes problem that Net::DBus created structure like "variant of variant of variant string" instead of "variant of string". Strictly typed applications do not expects that variant type is put in another variant type.
-
Method append_array() can be already called without type, so it make sense to allow also append_dict() to call without specifying type.
-
pali authored
Do not try to guess type from the first hash key/value. It is incompatible when you want to put into dbus dictionary perl hash with one scalar and one non-scalar type. So rather return from guess_type() method just "generic" [ &Net::DBus::Binding::Message::TYPE_VARIANT ] type without subtype. Missing subtype would be filled later by subsequent guess_type() calls for every one hash value. Also do not call guess_type() method on perl hash keys as it does not make sense. In perl all keys in hashes are just strings, so set type of keys in dbus dict to TYPE_STRING. This change fixes libdbus crash when Perl application was trying to do DBus method call with variable perl hash argument and guess_type() method was used. libdbus in this case caused segfault of whole perl process: dbus[3876]: Array or variant type requires that type string be written, but uint16 was written. The overall signature expected here was 'oha{ss}' and we are on byte 5 of that signature. D-Bus not built with -rdynamic so unable to print a backtrace [1] 3875 abort
-
- 16 Dec, 2019 7 commits
-
-
Daniel P. Berrangé authored
Signed-off-by:
Daniel P. Berrange <berrange@redhat.com>
-
Daniel P. Berrangé authored
Signed-off-by:
Daniel P. Berrange <berrange@redhat.com>
-
Don't leak memory by autovivifying undefined elements in the reactor timeouts array to empty hashes. Seems to only happen when a D-Bus method calls a D-Bus method in another service for some reason. Also prevent the same from occuring if toggle_timeout() is called with an invalid key. RT #108409 Signed-off-by:
Daniel P. Berrange <berrange@redhat.com>
-
Daniel P. Berrangé authored
RT #107466 Signed-off-by:
Daniel P. Berrange <berrange@redhat.com>
-
Daniel P. Berrangé authored
RT #105325 Signed-off-by:
Daniel P. Berrange <berrange@redhat.com>
-
Daniel P. Berrangé authored
RT #108071 Signed-off-by:
Daniel P. Berrange <berrange@redhat.com>
-
Daniel P. Berrangé authored
DBus introspection XML shouldn't need external entities, so we can turn off processing to be more robust against malicious XML. RT #118097 Signed-off-by:
Daniel P. Berrange <berrange@redhat.com>
-
- 01 Dec, 2019 5 commits
-
-
-
This would ensure that methods exported by dbus_method() would be really called with number of parameters as declared in dbus_method() definition.
-
It may happen that caller does not specify all required arguments and that would cause uninitialized value warnings like: Use of uninitialized value $interface in exists at Net/DBus/Binding/Introspector.pm line 291. Use of uninitialized value $pname in concatenation (.) or string at Net/DBus/BaseObject.pm line 544. So properly validate parameters and return error to caller when there too many too few parameters. Also call Introspector decode method in eval as it may throw error. This also discovered bug in test that GetAll method was called with additional nonsense parameter.
-
When caller invoke DBus method with more parameters as specified in Introspector XML file, try to decode all of them.
-
Variable $hasnext was incorrectly set to true expecting that passed message has at least one parameter. This is incorrect expectation as dbus message can have also zero parameters. To check that message iterator at current position is valid we can compare get_arg_type() method against invalid type as described in libdbus documentation: https://dbus.freedesktop.org/doc/api/html/group__DBusMessage.html#ga5aae3c882a75aed953d8b3d489e9b271 Simple way how to trigger this bug is to send message to interface org.freedesktop.DBus.Properties for method Get without any parameter. $ qdbus <service> <path> org.freedesktop.DBus.Properties.Get Error: org.freedesktop.DBus.Error.NoReply Message recipient disconnected from message bus without replying And Net::DBus application crash with following error: requested type 's' (115) did not match wire type '' (0) at Net/DBus/Binding/Iterator.pm line 239. cannot handle Net::DBus::Binding::Message::TYPE_INVALID at Net/DBus/Binding/Iterator.pm line 282. This patch fixes it and Net::DBus application does not crash anymore.
-
- 20 Nov, 2019 10 commits
-
-
pali authored
Because root node ends with slash, it is needed to correctly compose object path for objects which have root node as parent. So ensure that object path always starts with slash and never ends with slash (except for root node).
-
Currently user callback added by add_exception() method is never called due to incorrect name for _dispatch_fd() when reading file descriptor set from select() syscall. add_exception() put callback undef "exception" name and not "error".
-
This change makes qdbus to query property name. qdbus first tries to call method supplied by command line argument and if it fails with errororg.freedesktop.DBus.Error.UnknownMethod then it try to read property via org.freedesktop.DBus.Properties.Get method call. Other dbus client implementations also return UnknownMethod error when method does not exist.
-
Normally on system bus, user non-root applications are not allowed to request service name. But they can export objects identified by unique name of client's connection to the bus. So allow creating such service handles by specifying undef in service name parameter.
-
-
Perl method _dispatch_all_prop_read implements DBus method GetAll. When some application called GetAll implemented by Net::DBus it got bogus reply. And in more cases Net::DBus application crashed with error: process <pid>: Array or variant type requires that type string be written, but end_dict_entry was written. The overall signature expected here was 'a{sas}' and we are on byte 5 of that signature. Can't use string ("client") as an ARRAY ref while "strict refs" in use at Net/DBus/Binding/Iterator.pm line 598.
-
Currently Net::DBus supported only accepting unix file descriptor via exported local methods. This patch adds support for calling remote DBus methods and passing to them unix file descriptor from local process. Without this patch Net::DBus threw error for usage of dbus_unix_fd(): Unsupported scalar type 104 ('h') at Net/DBus/Binding/Iterator.pm line 466
-
-
TYPE_UNIX_FD is simple type and therefore it should not be passed to Net::DBus::Binding::Value via arrayref (which is for compound types). Net::DBus threw following error: Unsupported compound type 104 ('h') at Net/DBus/Binding/Iterator.pm line 435
-
Child node in Introspection XML Data must be relative. See specification: https://dbus.freedesktop.org/doc/dbus-specification.html#introspection-format Also qdbus tool cannot parse these "relative" paths with leading slash: QDBusConnection: error: could not send message to service "<service>" path "//" interface "org.freedesktop.DBus.Introspectable" member "Introspect": Invalid object path: // Therefore qdbus tool cannot be used to enumerate DBus objects exported by Net::DBus. With this patch applied, qdbus is finally happy.
-
- 14 Nov, 2019 1 commit
-
-
pali authored
basepath for root node is "/" and not "//". Root node is special case as it ends with slash. This patch fixes it. Also without this patch, Net::DBus generates warning: Use of uninitialized value $1 in hash element at Net/DBus/BaseObject.pm line 244.
-
- 12 Feb, 2019 1 commit
-
-
- 29 Oct, 2018 1 commit
-
-
intrigeri authored
-
- 25 Jan, 2018 3 commits
-
-
Daniel P. Berrangé authored
Signed-off-by:
Daniel P. Berrangé <berrange@redhat.com>
-
-
Fix it by adding protection for expiry so that it cannot be < 0 since the code was not handling that case. Added a textcase t/26-reactor-adjust-time.t which messes with the system clock so but sets it back afterwards. All unit tests pass.
-
- 08 Jul, 2016 1 commit
-
-
intrigeri authored
Those were identified by Debian's Lintian QA tool.
-
- 21 Mar, 2015 1 commit
-
-
intrigeri authored
-
- 16 Mar, 2015 2 commits
-
-
Daniel P. Berrangé authored
-
Daniel P. Berrangé authored
-