New issue
Advanced search Search tips

Issue 748695 link

Starred by 1 user

Issue metadata

Status: Archived
Owner:
Closed: Jul 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Chrome
Pri: ----
Type: Bug-Security



Sign in to add a comment

Security: overly permissive policy for dbus services owned by chrome process

Project Member Reported by lannm@google.com, Jul 25 2017

Issue description



In ChromeOS, dbus method calls owned by the chrome process that are expected to fail by policy instead succeed. I believe this is caused by the somewhat confusing semantic of `<allow send_destination="..."/>`, meaning "allow all messages to the *owner* of the specified service", and this line specifically: https://cs.chromium.org/chromium/src/chromeos/dbus/services/org.chromium.NetworkProxyService.conf?l=13&rcl=79c18709dcc89c752b5d34241214ab14db9ac768

An example that I expect to fail:

sudo -u nobody dbus-send --system --dest=org.chromium.LibCrosService --type=method_call --print-reply /org/chromium/LibCrosService org.chromium.LibCrosServiceInterface.SetDisplaySoftwareDimming boolean:false

based on this policy: https://cs.chromium.org/chromium/src/chromeos/dbus/services/org.chromium.LibCrosService.conf?rcl=c70a24f50c547d0f93eaa86bbcf4fb344b449561


I am testing a fix now that adds send_interface to the above rule.
 

Comment 1 by lannm@google.com, Jul 25 2017

Comment 2 by lannm@google.com, Jul 25 2017

Maybe overly paranoid but I'm being intentionally vague in the CL commit message since it will land publicly somewhat before it ships to CrOS...

Comment 3 by derat@chromium.org, Jul 26 2017

Cc: vapier@chromium.org jorgelo@chromium.org steve...@chromium.org hashimoto@chromium.org satorux@chromium.org benchan@chromium.org
Components: -OS OS>Systems
Thanks! I'll update the "D-Bus best practices" doc to mention this unless you get to it first.

Context for others: Chrome now exports multiple services (for  https://crbug.com/692246 ), and <allow send_destination=.../> rules referencing one service apparently also match all other services exported by Chrome. Adding send_interface appears to limit the rules as desired.

I don't know if there are any other processes on Chrome OS that own multiple service names.

Comment 4 by derat@chromium.org, Jul 26 2017

I have the doc change ready, but since it describes the problem, I'll hold off on uploading it until someone offers an opinion about how big of a deal this is. I'm not sure that there's anything interesting one can do by making method calls to a Chrome service from some unauthorized user.
Project Member

Comment 5 by sheriffbot@chromium.org, Jul 26 2017

Labels: Hotlist-Google

Comment 7 by la...@chromium.org, Jul 26 2017

Status: Fixed (was: Started)
Project Member

Comment 8 by sheriffbot@chromium.org, Jul 27 2017

Labels: -Restrict-View-SecurityTeam Restrict-View-SecurityNotify
I'm not super worried about malicious messages flowing *to* Chrome as opposed to *from* Chrome I don't think, but this could be a problem for other Chrome OS services as mentioned. Filed crbug.com/750139 to track.
Project Member

Comment 10 by bugdroid1@chromium.org, Aug 2 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromiumos/docs/+/6cafa6980096f44a96a9d267ac02a81cfe0601c8

commit 6cafa6980096f44a96a9d267ac02a81cfe0601c8
Author: Daniel Erat <derat@chromium.org>
Date: Wed Jul 26 01:43:19 2017

docs: Mention send_destination gotcha in D-Bus doc.

Make the D-Bus best practices doc mention that using <allow
send_destination="..."/> inadvertently grants permission to
call methods on other services exported by the same client.

BUG= chromium:748695 
TEST=none

Change-Id: I49253b34c93f194a45bb9474cf520194fc6c52bb

[modify] https://crrev.com/6cafa6980096f44a96a9d267ac02a81cfe0601c8/dbus_best_practices.md

Project Member

Comment 11 by sheriffbot@chromium.org, Nov 2 2017

Labels: -Restrict-View-SecurityNotify allpublic
This bug has been closed for more than 14 weeks. Removing security view restrictions.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot

Comment 12 by dchan@chromium.org, Jan 22 2018

Status: Archived (was: Fixed)

Sign in to add a comment