diff options
author | Colin Walters <walters@verbum.org> | 2008-12-12 14:50:21 -0500 |
---|---|---|
committer | Colin Walters <walters@verbum.org> | 2008-12-18 15:34:24 -0500 |
commit | dc77c213742d2a373e3ed134168e4377e7c99a61 (patch) | |
tree | aab3293832c9bb1810ac4f8bc5cf94a392b77c26 /bus/system.conf.in | |
parent | 3af94cf25081502b6b55ff291e350f2685eef526 (diff) | |
download | dbus-dc77c213742d2a373e3ed134168e4377e7c99a61.tar.gz dbus-dc77c213742d2a373e3ed134168e4377e7c99a61.tar.bz2 dbus-dc77c213742d2a373e3ed134168e4377e7c99a61.zip |
Clean up and clarify default system policy
The former was too reliant on old bugs and was generally unclear.
This one makes explicit exactly what is allowed and not.
Diffstat (limited to 'bus/system.conf.in')
-rw-r--r-- | bus/system.conf.in | 42 |
1 files changed, 19 insertions, 23 deletions
diff --git a/bus/system.conf.in b/bus/system.conf.in index 41e1bb1a..92f4cc42 100644 --- a/bus/system.conf.in +++ b/bus/system.conf.in @@ -42,33 +42,29 @@ <listen>@DBUS_SYSTEM_BUS_DEFAULT_ADDRESS@</listen> <policy context="default"> - <!-- Deny everything then punch holes --> - <deny send_interface="*"/> - <deny receive_interface="*"/> - <deny own="*"/> - <!-- But allow all users to connect --> + <!-- All users can connect to system bus --> <allow user="*"/> - <!-- Allow anyone to talk to the message bus --> - <!-- FIXME I think currently these allow rules are always implicit - even if they aren't in here --> - <allow send_destination="org.freedesktop.DBus"/> - <allow receive_sender="org.freedesktop.DBus"/> - <!-- Allow all signals to be sent by default --> + + <!-- Holes must be punched in service configuration files for + name ownership and sending method calls --> + <deny own="*"/> + <deny send_type="method_call"/> + + <!-- Signals and reply messages (method returns, errors) are allowed + by default --> <allow send_type="signal"/> - <!-- allow sending valid replies --> <allow send_requested_reply="true" send_type="method_return"/> <allow send_requested_reply="true" send_type="error"/> - <!-- allow receiving valid replies --> - <allow receive_requested_reply="true"/> - <!-- Note: the rule above also allows receiving of all non-reply messages - that are not denied later. See: - https://bugs.freedesktop.org/show_bug.cgi?id=18229 - Potentially this will be replaced in the future by the - following two rules: - <allow receive_requested_reply="true" receive_type="method_return"/> - <allow receive_requested_reply="true" receive_type="error"/> - --> - <!-- disallow changing the activation environment of system services --> + + <!-- All messages may be received by default --> + <allow receive_type="method_call"/> + <allow receive_type="method_return"/> + <allow receive_type="error"/> + <allow receive_type="signal"/> + + <!-- Allow anyone to talk to the message bus --> + <allow send_destination="org.freedesktop.DBus"/> + <!-- But disallow some specific bus services --> <deny send_destination="org.freedesktop.DBus" send_interface="org.freedesktop.DBus" send_member="UpdateActivationEnvironment"/> |