Age | Commit message (Collapse) | Author | Files | Lines |
|
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=69332
[altered commit message to not say it fixes memory leaks -smcv]
Reviewed-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
|
|
We don't want the regression tests' "session" getting mixed up in
system-wide "sessions". This doesn't actually matter yet, but it is
likely to matter in future.
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=61301
Reviewed-by: Chengwei Yang <chengwei.yang@intel.com>
[merged with earlier line-wrapping of TESTS_ENVIRONMENT -smcv]
Signed-off-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
|
|
The message bus which can monitor its conf dirs for changes and reload
confs immediately if dir monitor enabled, for example, inotify in Linux,
kqueue in *BSD.
However, it doesn't apply policy rules change for completed connections,
so to apply policy rules change, the client connection has to disconnect
first and then re-connect to message bus.
For imcomplete connections, it always has the latest review of policy
rules.
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=39463
Reviewed-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
|
|
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=61303
Reviewed-by: Chengwei Yang <chengwei.yang@intel.com>
Signed-off-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
|
|
The --with-dbus-session-bus-connect-address configure option and the
DBUS_SESSION_BUS_CONNECT_ADDRESS CMake variable expect a connectable
address, while the --with-dbus-session-bus-listen-address option and
the DBUS_SESSION_BUS_LISTEN_ADDRESS variable expect a listenable address.
DBUS_SYSTEM_BUS_DEFAULT_ADDRESS currently has to be an address that
is simultaneously listenable and connectable.
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=61303
Reviewed-by: Chengwei Yang <chengwei.yang@intel.com>
[fixed name of DBUS_SESSION_BUS_CONNECT_ADDRESS as per review -smcv]
Signed-off-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
|
|
|
|
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=66453
Signed-off-by: Chengwei Yang <chengwei.yang@intel.com>
Reviewed-by: Ralf Habacker <ralf.habacker@freenet.de>
|
|
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=66453
Signed-off-by: Chengwei Yang <chengwei.yang@intel.com>
Reviewed-by: Ralf Habacker <ralf.habacker@freenet.de>
|
|
So far, this bug can be triggered in systemd environment, if the
configured ListenStream for dbus.socket has characters must be escaped
first. Then we'll get an error like
"In D-Bus address, character '%c' should have been escaped\n"
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=46013
Reviewed-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
|
|
This is an important security measure. Without it, the system bus
would not deliver its intended security properties. The actual
implementation has always behaved like this, I think.
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=68597
Reviewed-by: Chengwei Yang <chengwei.yang@intel.com>
|
|
Previously, if we have interfaces:
interface com.example.foo:
method Ambiguous()
interface com.example.bar:
method Ambiguous()
method Unambiguous()
implementations were required to deliver a message with no INTERFACE
and METHOD=Unambiguous to "bar". A message with no INTERFACE and
METHOD=Ambiguous could either be delivered to "foo", delivered to "bar"
or treated as an error.
Relax this to allow an error for the unambiguous case, too, and
strongly recommend specifying the interface (which is best-practice).
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=68597
Reviewed-by: Chengwei Yang <chengwei.yang@intel.com>
Vaguely-acked-by: Thiago Macieira, David Zeuthen
[and desrt objected that it didn't go far enough]
Signed-off-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
|
|
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=70592
Reviewed-by: Chengwei Yang <chengwei.yang@intel.com>
Reviewed-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
|
|
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=71985
Reviewed-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
|
|
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=71820
Reviewed-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
|
|
https://bugs.freedesktop.org/show_bug.cgi?id=71627
Reviewed-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
|
|
dbus-sysdeps-win.c makes use of a constant called
PROCESS_QUERY_LIMITED_INFORMATION, which was added after Windows
XP. There is code present to make sure the constant is not used
when running on an XP system, but the constant is still required
at build time. Unfortunately, the Windows headers provided by
MinGW are old enough that they do not contain this constant, so
building with MinGW fails.
This patch adds a definition for the constant if one is not already
present.
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=71366
Reviewed-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
Reviewed-by: Ralf Habacker <ralf.habacker@freenet.de>
[altered comment to specify MinGW32 < 4, since mingw-w64
and MinGW 4.0+ do have this constant -smcv]
|
|
|
|
|
|
|
|
Signed-off-by: Radoslaw Pajak <r.pajak@samsung.com>
Reviewed-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=71526
|
|
Previous to the introduction of selinux_set_mapping(), DBus pulled
constants generated from the system's policy at build time. But this
means it's impossible to replace the system policy without rebuilding
userspace components.
This patch maps from arbitrary class/perm indices used by D-Bus and
the policy values and handles all the translation at runtime on
avc_has_perm() calls.
Bug: https://bugs.freedesktop.org/attachment.cgi?id=88719
Reviewed-By: Colin Walters <walters@verbum.org>
Tested-By: Colin Walters <walters@verbum.org>
|
|
Conflicts:
NEWS
|
|
|
|
In code that looks like n[i] = v(&i), where v increments i, C leaves it
undefined whether the old or new value of i is used to locate n[i].
As it happens, gcc used the pre-increment value of i, but MSVC
used the post-increment value.
Fix this by inserting a sequence point to disambiguate the intended order.
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=69924
Reviewed-by: Chengwei Yang <chengwei.yang@intel.com>
Reviewed-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
[wrote commit message, fixed whitespace -smcv]
Signed-off-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
|
|
|
|
|
|
|
|
|
|
As soon as capng_clear() is called, we won't appear to have
CAP_AUDIT_WRITE. Fix this by checking for it before resetting the
libcap state.
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=49062
Tested-by: Laurent Bigonville <bigon@debian.org>
Reviewed-by: Laurent Bigonville <bigon@debian.org>
Reviewed-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
Reviewed-by: Lennart Poettering <lennart@poettering.net>
|
|
This reverts commit c8bc5f24b721bc03679c44669cf5e655c1e99b5f.
Nothing changed since 0.22.
|
|
Conflicts:
NEWS
configure.ac
|
|
|
|
|
|
|
|
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=68559
Reviewed-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
|
|
|
|
In systemd environment, dbus-daemon will run as no-fork mode since this
is the recommended practice of systemd.
In that scenario, child activated by dbus-daemon will inherit
dbus-daemon standard streams, includes stdin/stdout/stderr. stdin will
be redirected to /dev/null by systemd and stdout/stderr will be catched
by systemd log subsystem. Since the child inherit stdout/stderr from
dbus-daemon, so from systemd journal log, the child log output will be
identified with dbus-daemon identifier. So it's a little confusing.
This patch redirects the child stdout/stderr to systemd journal stream,
and with its owned service name as identifier. However, thing not fixed
perfectly due to the socket ucred of the child is owned by dbus-daemon,
so the pid isn't the real pid of the chile.
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=68559
Reviewed-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
|
|
DBusBabysitter->executable is defined as executable name to use in error
messages. However, if servicehelper used, then the executable name is
servicehelper. It's not much help because we couldn't figure out which
service we're trying to activated if error happens.
In the following patch, we'll use service name to be activated as the
child log identifier and add a parameter to
_dbus_spawn_async_with_babysitter() to pass the log identifier. Since
this is not the case in test, so executable changed to log_name.
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=68559
Reviewed-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
|
|
Update three configurable elements for dbus-daemon manual, <syslog>,
<pidfile> and <allow_anonymous>, all of them are undocumented so far.
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=69125
Reviewed-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
|
|
DBUS_ACTIVATION_ADDRESS changed to DBUS_STARTER_ADDRESS and
DBUS_ACTIVATION_BUS_TYPE changed to DBUS_STARTER_BUS_TYPE since 2005 by
this commit - 8873c90
So the dbus_setenv() which used to unset the above two wrong environment
variables has no effect in fact. And giving that setenv(3) and putenv(3)
are not threadsafe, so it's better to remove them.
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=68308
Reviewed-by: Ralf Habacker <ralf.habacker@freenet.de>
Reviewed-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
Acked-by: Colin Walters <walters@verbum.org>
|
|
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=60859
Reviewed-by: Chengwei Yang
[removed unused variable based on review -smcv]
|
|
There are enough pipes, fds and processes here that it's important to
keep track of them.
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=60859
|
|
As Simon's comment
https://bugs.freedesktop.org/show_bug.cgi?id=66068#c8
we can do this in UNIX environment.
Reviewed-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
|
|
Add test cases for testing:
* If more arguments than requested are present, the requested
arguments are returned and the extra arguments are ignored.
* If arguments parse failed, ensure we didn't leak any memory or unix
fd
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=21259
[added a check for fd leaks around verify_test_message_args_ignored() -smcv]
Reviewed-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
|
|
This is an aged bug since 2009, so let's fix it. Say if a previous
parsing for unix fd or array of string successfully but then a later
element parsing fail, then the unix fd or array of string leaked.
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=21259
Reviewed-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
|
|
At privous, which increments the number of arguments already handled in
the last of loop, however, if there is any invalid argument, then it
will "goto out" and the number of arguments already handled is now
incorrect.
A following patch will use the number of arguments already handled as a
loop terminate condition, so it's good to fix it before.
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=21259
Reviewed-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
|
|
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=60859
Reviewed-by: Chengwei Yang <chengwei.yang@intel.com>
|
|
env is used as you'd expect now.
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=60859
Reviewed-by: Chengwei Yang <chengwei.yang@intel.com>
|
|
|
|
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=70799
Reviewed-by: Philip Withnall <philip.withnall@collabora.co.uk>
Reviewed-by: Ryan Lortie <desrt@desrt.ca>
|