Add default deny policy in conf files
[platform/core/connectivity/bluetooth-agent.git] / ag-agent / bluetooth-ag-agent.conf.in
index 63d0b7f..661c743 100644 (file)
@@ -1,26 +1,28 @@
 <!DOCTYPE busconfig PUBLIC "-//freedesktop//DTD D-BUS Bus Configuration 1.0//EN"
  "http://www.freedesktop.org/standards/dbus/1.0/busconfig.dtd">
 <busconfig>
-    <policy group="network_fw">
-    </policy>
-    <policy group="root">
+    <policy context="default">
+        <deny own="org.bluez.ag_agent"/>
+        <deny receive_sender="org.bluez.ag_agent"/>
+        <deny send_destination="org.bluez.ag_agent"/>
+        <check send_destination="org.bluez.ag_agent" send_interface="Org.Hfp.App.Interface" send_member="CheckPrivilege" privilege="http://tizen.org/privilege/bluetooth.admin" />
+        <check send_destination="org.bluez.ag_agent" send_interface="Org.Hfp.App.Interface" send_member="Play" privilege="http://tizen.org/privilege/bluetooth.admin" />
+        <check send_destination="org.bluez.ag_agent" send_interface="Org.Hfp.App.Interface" send_member="Stop" privilege="http://tizen.org/privilege/bluetooth.admin" />
+        <check send_destination="org.bluez.ag_agent" send_interface="Org.Hfp.App.Interface" send_member="ChangeCallStatus" privilege="http://tizen.org/privilege/bluetooth.admin" />
+        <check send_destination="org.bluez.ag_agent" send_interface="Org.Hfp.App.Interface" send_member="OutgoingCall" privilege="http://tizen.org/privilege/bluetooth.admin" />
+        <check send_destination="org.bluez.ag_agent" send_interface="Org.Hfp.App.Interface" send_member="IncomingCall" privilege="http://tizen.org/privilege/bluetooth.admin" />
+        <check send_destination="org.bluez.ag_agent" send_interface="Org.Hfp.App.Interface" send_member="SendVendorAtCmd" privilege="http://tizen.org/privilege/bluetooth.admin" />
+        <check send_destination="org.bluez.ag_agent" send_interface="Org.Hfp.App.Interface" send_member="SetVoiceDial" privilege="http://tizen.org/privilege/bluetooth.admin" />
+        <check send_destination="org.bluez.ag_agent" send_interface="Org.Hfp.App.Interface" send_member="SetSpeakerGain" privilege="http://tizen.org/privilege/bluetooth.admin" />
+        <check send_destination="org.bluez.ag_agent" send_interface="Org.Hfp.App.Interface" send_member="SwapHeadset" privilege="http://tizen.org/privilege/bluetooth.admin" />
     </policy>
     <policy group="pulse">
-           <allow own="Org.Hfp.App.Interface"/>
-           <allow send_interface="Org.Hfp.App.Interface"/>
-           <allow send_destination="Org.Hfp.App.Interface"/>
+           <allow receive_interface="Org.Hfp.App.Interface"/>
+        <allow send_interface="Org.Hfp.App.Interface"/>
     </policy>
-    <policy context="default">
-            <check send_destination="org.bluez.ag_agent" send_interface="Org.Hfp.App.Interface" send_member="CheckPrivilege" privilege="http://tizen.org/privilege/bluetooth.admin" />
-            <check send_destination="org.bluez.ag_agent" send_interface="Org.Hfp.App.Interface" send_member="Play" privilege="http://tizen.org/privilege/bluetooth.admin" />
-            <check send_destination="org.bluez.ag_agent" send_interface="Org.Hfp.App.Interface" send_member="Stop" privilege="http://tizen.org/privilege/bluetooth.admin" />
-            <check send_destination="org.bluez.ag_agent" send_interface="Org.Hfp.App.Interface" send_member="ChangeCallStatus" privilege="http://tizen.org/privilege/bluetooth.admin" />
-            <check send_destination="org.bluez.ag_agent" send_interface="Org.Hfp.App.Interface" send_member="OutgoingCall" privilege="http://tizen.org/privilege/bluetooth.admin" />
-            <check send_destination="org.bluez.ag_agent" send_interface="Org.Hfp.App.Interface" send_member="IncomingCall" privilege="http://tizen.org/privilege/bluetooth.admin" />
-            <check send_destination="org.bluez.ag_agent" send_interface="Org.Hfp.App.Interface" send_member="SendVendorAtCmd" privilege="http://tizen.org/privilege/bluetooth.admin" />
-            <check send_destination="org.bluez.ag_agent" send_interface="Org.Hfp.App.Interface" send_member="SetVoiceDial" privilege="http://tizen.org/privilege/bluetooth.admin" />
-            <check send_destination="org.bluez.ag_agent" send_interface="Org.Hfp.App.Interface" send_member="SetSpeakerGain" privilege="http://tizen.org/privilege/bluetooth.admin" />
-            <check send_destination="org.bluez.ag_agent" send_interface="Org.Hfp.App.Interface" send_member="SwapHeadset" privilege="http://tizen.org/privilege/bluetooth.admin" />
+    <policy group="network_fw">
+        <allow own="org.bluez.ag_agent"/>
+        <allow receive_sender="org.bluez.ag_agent"/>
+        <allow send_destination="org.bluez.ag_agent"/>
     </policy>
 </busconfig>
-