AU: Beginnings of dbus support.
The AU will be a daemon that runs as root. Non-root will communicate
via dbus with the updater to do things such as: query status, request
forced or full updates, etc.
New files for dbus:
UpdateEngine.conf - security configuration
dbus_constants.h - common constants
dbus_service.* - The object exposed over dbus
org.chromium.UpdateEngine.service - the dbus service file
udpate_attempter.* - Refactored this out of main.cc
update_engine_client.cc - Simple command line utility to interact with
Update Engine over dbus. Whereas Update Engine runs as root, this tool
runs as non-root user.
Review URL: http://codereview.chromium.org/1733013
diff --git a/UpdateEngine.conf b/UpdateEngine.conf
new file mode 100644
index 0000000..88d6dc4
--- /dev/null
+++ b/UpdateEngine.conf
@@ -0,0 +1,23 @@
+<!DOCTYPE busconfig PUBLIC "-//freedesktop//DTD D-BUS Bus Configuration 1.0//EN"
+ "http://www.freedesktop.org/standards/dbus/1.0/busconfig.dtd">
+<busconfig>
+ <policy user="root">
+ <allow own="org.chromium.UpdateEngine" />
+ <allow send_destination="org.chromium.UpdateEngine" />
+ </policy>
+ <policy user="chronos">
+ <!-- introspection is denied -->
+ <deny send_destination="org.chromium.UpdateEngine"
+ send_interface="org.freedesktop.DBus.Introspectable" />
+ <!-- properties denied -->
+ <deny send_destination="org.chromium.UpdateEngine"
+ send_interface="org.freedesktop.DBus.Properties" />
+ <!-- allow explicit methods -->
+ <allow send_destination="org.chromium.UpdateEngine"
+ send_interface="org.chromium.UpdateEngineInterface"
+ send_member="GetStatus"/>
+ </policy>
+ <policy context="default">
+ <deny send_destination="org.chromium.UpdateEngine" />
+ </policy>
+</busconfig>