Bug 469151 (CVE-2008-4311) - CVE-2008-4311 dbus: incorrect use of [send|receive]_requested_reply policy rule attribute in system.conf
Summary: CVE-2008-4311 dbus: incorrect use of [send|receive]_requested_reply policy ru...
Alias: CVE-2008-4311
Product: Security Response
Classification: Other
Component: vulnerability
Version: unspecified
Hardware: All
OS: Linux
Target Milestone: ---
Assignee: Red Hat Product Security
QA Contact:
Depends On: 474895 489875 489877 489878 489879 489884 489886 489894 489899 489953 489955
TreeView+ depends on / blocked
Reported: 2008-10-30 09:51 UTC by Tomas Hoger
Modified: 2021-02-25 14:04 UTC (History)
12 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Last Closed: 2015-02-17 15:31:36 UTC

Attachments (Terms of Use)
The change I proposed in the upstream bug (1.11 KB, patch)
2008-11-18 09:32 UTC, Tomas Hoger
no flags Details | Diff

System ID Private Priority Status Summary Last Updated
Debian BTS 503532 0 None None None Never
FreeDesktop.org 18229 0 None None None Never

Description Tomas Hoger 2008-10-30 09:51:25 UTC
Joachim Breitner discovered that dbus policy rules with send_requested_reply="true" condition are not evaluated correctly and are also applied to non-reply messages.  This may result in the request message being allowed, even though it should have been denied.  This occurs when service does not specify explicit <deny> rules and relies on the default <deny send_interface="*"/> rule listed in system.conf file that may be overriden by the <allow send_requested_reply="true"/> rule, resulting in a bypass of the intended access restrictions policy.

Note: Most services using system bus seem to specify context="default" deny rules explicitly without relying on the default system bus access policy.


Comment 2 Tomas Hoger 2008-10-31 09:26:08 UTC
Brief summary of my upstream comment:

Current behaviour seems to comply with the semantics documented in dbus-daemon(1) man page.  Attributes [send|receive]_requested_reply are defined to be ignored for non-reply messages.  Therefore default system.conf configuration file seems to rely on an incorrect assumption that rule:

  <allow send_requested_reply="true"/>

only applies to reply messages, while it's actually <allow/> for non-replies.

We may need to change default system.conf to list:

  <allow send_requested_reply="true" send_type="method_return"/>
  <allow send_requested_reply="true" send_type="error"/>

(and similar for receive_requested_reply)

to make sure rule only applies to intended message types.  Other patches proposed so far change previously defined semantics.

Comment 4 Tomas Hoger 2008-11-12 14:27:35 UTC
Another update from the upstream bug:

Restricting rule:

  <allow receive_requested_reply="true"/>

seems to be problematic, as too many applications mistakenly rely on this rule.  Each dbus message is checked against policy two times - first to check if sender is permitted to send the message, second to check if receiver is permitted to receive the message.

So the applications may have all send rules defined correctly, very few have any rules receive rules.

Comment 5 Dan Williams 2008-11-17 16:35:54 UTC
Is there a patch for this yet upstream?

Comment 6 Tomas Hoger 2008-11-18 09:32:04 UTC
Created attachment 323869 [details]
The change I proposed in the upstream bug

Comment 7 Dan Williams 2008-12-01 17:14:11 UTC
Yeah, lets see if davidz can get some upstream comment on it.  I don't feel comfortable putting this into RHEL until we get _somebody_ from upstream to sign off on it.

Comment 11 Tomas Hoger 2008-12-07 10:29:17 UTC
Public now via new upstream release 1.2.6:

Comment 13 Jan Lieskovsky 2008-12-10 11:25:56 UTC
From CVE entry:

The default configuration of system.conf in D-Bus (aka DBus) before
1.2.6 omits the send_type attribute in certain rules, which allows
local users to bypass intended access restrictions by (1) sending
messages, related to send_requested_reply; and possibly (2) receiving
messages, related to receive_requested_reply.

Adding other references:

Comment 31 Josh Bressers 2009-09-22 18:58:30 UTC
I am going to defer this issue. The fix is very complicated and the risk outweighs the potential reward. This flaw may be fixed in a future dbus update.

Comment 32 Vincent Danen 2015-02-17 15:31:36 UTC

Red Hat Enterprise Linux 5 is now in Production 3 Phase of the support and maintenance life cycle. This has been rated as having Moderate security impact and is not currently planned to be addressed in future updates. For additional information, refer to the Red Hat Enterprise Linux Life Cycle: https://access.redhat.com/support/policy/updates/errata/.

Note You need to log in before you can comment on or make changes to this bug.