build: install DBus service and data files for the new API
This commit is contained in:
4
.gitignore
vendored
4
.gitignore
vendored
@@ -42,6 +42,10 @@ policy/org.freedesktop.modem-manager.policy
|
||||
libqcdm/tests/test-qcdm
|
||||
libwmc/tests/test-wmc
|
||||
|
||||
data/org.freedesktop.ModemManager1.conf
|
||||
data/org.freedesktop.ModemManager1.service
|
||||
data/org.freedesktop.ModemManager1.policy
|
||||
|
||||
include/ModemManager-names.h
|
||||
|
||||
libmm-common/*.[ch]
|
||||
|
@@ -1,15 +1,15 @@
|
||||
|
||||
# DBus Service file
|
||||
dbusservicedir = $(DBUS_SYS_DIR)
|
||||
dbusservice_DATA = org.freedesktop.ModemManager.conf
|
||||
dbusservice_file_polkit = org.freedesktop.ModemManager.conf.polkit
|
||||
dbusservice_file_nopolkit = org.freedesktop.ModemManager.conf.nopolkit
|
||||
dbusservice_DATA = org.freedesktop.ModemManager1.conf
|
||||
dbusservice_file_polkit = org.freedesktop.ModemManager1.conf.polkit
|
||||
dbusservice_file_nopolkit = org.freedesktop.ModemManager1.conf.nopolkit
|
||||
|
||||
if WITH_POLKIT
|
||||
org.freedesktop.ModemManager.conf: $(top_srcdir)/data/$(dbusservice_file_polkit)
|
||||
org.freedesktop.ModemManager1.conf: $(top_srcdir)/data/$(dbusservice_file_polkit)
|
||||
cp -f $(top_srcdir)/data/$(dbusservice_file_polkit) $(dbusservice_DATA)
|
||||
else
|
||||
org.freedesktop.ModemManager.conf: $(top_srcdir)/data/$(dbusservice_file_nopolkit)
|
||||
org.freedesktop.ModemManager1.conf: $(top_srcdir)/data/$(dbusservice_file_nopolkit)
|
||||
cp -f $(top_srcdir)/data/$(dbusservice_file_nopolkit) $(dbusservice_DATA)
|
||||
endif
|
||||
|
||||
@@ -21,16 +21,16 @@ edit = @sed \
|
||||
-e 's|@localstatedir[@]|$(localstatedir)|g' \
|
||||
-e 's|@libexecdir[@]|$(libexecdir)|g'
|
||||
dbusactivationdir = $(datadir)/dbus-1/system-services
|
||||
dbusactivation_in_files = org.freedesktop.ModemManager.service.in
|
||||
dbusactivation_in_files = org.freedesktop.ModemManager1.service.in
|
||||
dbusactivation_DATA = $(dbusactivation_in_files:.service.in=.service)
|
||||
%service: %service.in
|
||||
$(edit) $< >$@
|
||||
|
||||
|
||||
# DBus Introspection files
|
||||
XMLS = $(wildcard $(top_srcdir)/introspection/*.xml)
|
||||
XMLS = $(wildcard $(top_srcdir)/new/*.xml)
|
||||
xmldir = $(datadir)/dbus-1/interfaces
|
||||
xml_DATA = $(filter-out $(top_srcdir)/introspection/all.xml, $(XMLS))
|
||||
xml_DATA = $(filter-out $(top_srcdir)/new/all.xml, $(XMLS))
|
||||
|
||||
|
||||
# Icon
|
||||
@@ -39,7 +39,7 @@ icon_DATA = modem-manager.png
|
||||
|
||||
|
||||
# Polkit
|
||||
dist_polkit_policy_in_files = org.freedesktop.modem-manager.policy.in
|
||||
dist_polkit_policy_in_files = org.freedesktop.ModemManager1.policy.in
|
||||
if WITH_POLKIT
|
||||
polkit_policydir = $(datadir)/polkit-1/actions
|
||||
dist_polkit_policy_DATA = $(dist_polkit_policy_in_files:.policy.in=.policy)
|
||||
|
@@ -1,154 +0,0 @@
|
||||
<!DOCTYPE busconfig PUBLIC
|
||||
"-//freedesktop//DTD D-BUS Bus Configuration 1.0//EN"
|
||||
"http://www.freedesktop.org/standards/dbus/1.0/busconfig.dtd">
|
||||
<busconfig>
|
||||
<policy context="default">
|
||||
<deny send_destination="org.freedesktop.ModemManager"/>
|
||||
|
||||
<allow send_destination="org.freedesktop.ModemManager"
|
||||
send_interface="org.freedesktop.DBus.Introspectable"/>
|
||||
|
||||
<!-- Methods listed here are explicitly allowed or PolicyKit protected.
|
||||
The rest are restricted to root for security.
|
||||
-->
|
||||
|
||||
<allow send_destination="org.freedesktop.ModemManager"
|
||||
send_interface="org.freedesktop.ModemManager"
|
||||
send_member="EnumerateDevices"/>
|
||||
|
||||
<allow send_destination="org.freedesktop.ModemManager"
|
||||
send_interface="org.freedesktop.DBus.Properties"/>
|
||||
|
||||
<allow send_destination="org.freedesktop.ModemManager"
|
||||
send_interface="org.freedesktop.ModemManager.Modem"
|
||||
send_member="GetInfo"/>
|
||||
|
||||
<allow send_destination="org.freedesktop.ModemManager"
|
||||
send_interface="org.freedesktop.ModemManager.Modem.Cdma"
|
||||
send_member="GetSignalQuality"/>
|
||||
|
||||
<allow send_destination="org.freedesktop.ModemManager"
|
||||
send_interface="org.freedesktop.ModemManager.Modem.Cdma"
|
||||
send_member="GetServingSystem"/>
|
||||
|
||||
<allow send_destination="org.freedesktop.ModemManager"
|
||||
send_interface="org.freedesktop.ModemManager.Modem.Cdma"
|
||||
send_member="GetRegistrationState"/>
|
||||
|
||||
<allow send_destination="org.freedesktop.ModemManager"
|
||||
send_interface="org.freedesktop.ModemManager.Modem.Cdma"
|
||||
send_member="GetEsn"/>
|
||||
|
||||
<allow send_destination="org.freedesktop.ModemManager"
|
||||
send_interface="org.freedesktop.ModemManager.Modem.Gsm.Network"
|
||||
send_member="GetSignalQuality"/>
|
||||
|
||||
<allow send_destination="org.freedesktop.ModemManager"
|
||||
send_interface="org.freedesktop.ModemManager.Modem.Gsm.Network"
|
||||
send_member="GetBand"/>
|
||||
|
||||
<allow send_destination="org.freedesktop.ModemManager"
|
||||
send_interface="org.freedesktop.ModemManager.Modem.Gsm.Network"
|
||||
send_member="GetNetworkMode"/>
|
||||
|
||||
<allow send_destination="org.freedesktop.ModemManager"
|
||||
send_interface="org.freedesktop.ModemManager.Modem.Gsm.Network"
|
||||
send_member="GetRegistrationInfo"/>
|
||||
|
||||
<allow send_destination="org.freedesktop.ModemManager"
|
||||
send_interface="org.freedesktop.ModemManager.Modem.Gsm.Network"
|
||||
send_member="Scan"/>
|
||||
|
||||
<allow send_destination="org.freedesktop.ModemManager"
|
||||
send_interface="org.freedesktop.ModemManager.Modem.Gsm.Card"
|
||||
send_member="GetImei"/>
|
||||
|
||||
<allow send_destination="org.freedesktop.ModemManager"
|
||||
send_interface="org.freedesktop.ModemManager.Modem.Gsm.Card"
|
||||
send_member="GetImsi"/>
|
||||
|
||||
<allow send_destination="org.freedesktop.ModemManager"
|
||||
send_interface="org.freedesktop.ModemManager.Modem.Gsm.Card"
|
||||
send_member="SendPuk"/>
|
||||
|
||||
<allow send_destination="org.freedesktop.ModemManager"
|
||||
send_interface="org.freedesktop.ModemManager.Modem.Gsm.Card"
|
||||
send_member="SendPin"/>
|
||||
|
||||
<allow send_destination="org.freedesktop.ModemManager"
|
||||
send_interface="org.freedesktop.ModemManager.Modem.Gsm.Card"
|
||||
send_member="EnablePin"/>
|
||||
|
||||
<allow send_destination="org.freedesktop.ModemManager"
|
||||
send_interface="org.freedesktop.ModemManager.Modem.Gsm.Card"
|
||||
send_member="ChangePin"/>
|
||||
|
||||
<allow send_destination="org.freedesktop.ModemManager"
|
||||
send_interface="org.freedesktop.ModemManager.Modem.Gsm.Contacts"
|
||||
send_member="Add"/>
|
||||
|
||||
<allow send_destination="org.freedesktop.ModemManager"
|
||||
send_interface="org.freedesktop.ModemManager.Modem.Gsm.Contacts"
|
||||
send_member="Delete"/>
|
||||
|
||||
<allow send_destination="org.freedesktop.ModemManager"
|
||||
send_interface="org.freedesktop.ModemManager.Modem.Gsm.Contacts"
|
||||
send_member="Get"/>
|
||||
|
||||
<allow send_destination="org.freedesktop.ModemManager"
|
||||
send_interface="org.freedesktop.ModemManager.Modem.Gsm.Contacts"
|
||||
send_member="List"/>
|
||||
|
||||
<allow send_destination="org.freedesktop.ModemManager"
|
||||
send_interface="org.freedesktop.ModemManager.Modem.Gsm.Contacts"
|
||||
send_member="Find"/>
|
||||
|
||||
<allow send_destination="org.freedesktop.ModemManager"
|
||||
send_interface="org.freedesktop.ModemManager.Modem.Gsm.Contacts"
|
||||
send_member="GetCount"/>
|
||||
|
||||
<allow send_destination="org.freedesktop.ModemManager"
|
||||
send_interface="org.freedesktop.ModemManager.Modem.Gsm.SMS"
|
||||
send_member="Delete"/>
|
||||
|
||||
<allow send_destination="org.freedesktop.ModemManager"
|
||||
send_interface="org.freedesktop.ModemManager.Modem.Gsm.SMS"
|
||||
send_member="Get"/>
|
||||
|
||||
<allow send_destination="org.freedesktop.ModemManager"
|
||||
send_interface="org.freedesktop.ModemManager.Modem.Gsm.SMS"
|
||||
send_member="List"/>
|
||||
|
||||
<allow send_destination="org.freedesktop.ModemManager"
|
||||
send_interface="org.freedesktop.ModemManager.Modem.Gsm.SMS"
|
||||
send_member="Save"/>
|
||||
|
||||
<allow send_destination="org.freedesktop.ModemManager"
|
||||
send_interface="org.freedesktop.ModemManager.Modem.Gsm.SMS"
|
||||
send_member="Send"/>
|
||||
|
||||
<allow send_destination="org.freedesktop.ModemManager"
|
||||
send_interface="org.freedesktop.ModemManager.Modem.Gsm.SMS"
|
||||
send_member="SendFromStorage"/>
|
||||
|
||||
<allow send_destination="org.freedesktop.ModemManager"
|
||||
send_interface="org.freedesktop.ModemManager.Modem.Gsm.SMS"
|
||||
send_member="SetIndication"/>
|
||||
|
||||
<allow send_destination="org.freedesktop.ModemManager"
|
||||
send_interface="org.freedesktop.ModemManager.Modem.Gsm.SMS"
|
||||
send_member="GetSmsc"/>
|
||||
|
||||
<allow send_destination="org.freedesktop.ModemManager"
|
||||
send_interface="org.freedesktop.ModemManager.Modem.Gsm.SMS"
|
||||
send_member="SetSmsc"/>
|
||||
</policy>
|
||||
|
||||
<policy user="root">
|
||||
<allow own="org.freedesktop.ModemManager"/>
|
||||
<allow send_destination="org.freedesktop.ModemManager"/>
|
||||
</policy>
|
||||
|
||||
<limit name="max_replies_per_connection">512</limit>
|
||||
</busconfig>
|
||||
|
@@ -5,11 +5,11 @@
|
||||
<!-- This config allows anyone to control ModemManager -->
|
||||
|
||||
<policy context="default">
|
||||
<allow send_destination="org.freedesktop.ModemManager"/>
|
||||
<allow send_destination="org.freedesktop.ModemManager1"/>
|
||||
</policy>
|
||||
|
||||
<policy user="root">
|
||||
<allow own="org.freedesktop.ModemManager"/>
|
||||
<allow own="org.freedesktop.ModemManager1"/>
|
||||
</policy>
|
||||
|
||||
<limit name="max_replies_per_connection">512</limit>
|
22
data/org.freedesktop.ModemManager1.conf.polkit
Normal file
22
data/org.freedesktop.ModemManager1.conf.polkit
Normal file
@@ -0,0 +1,22 @@
|
||||
<!DOCTYPE busconfig PUBLIC
|
||||
"-//freedesktop//DTD D-BUS Bus Configuration 1.0//EN"
|
||||
"http://www.freedesktop.org/standards/dbus/1.0/busconfig.dtd">
|
||||
<busconfig>
|
||||
<policy context="default">
|
||||
<deny send_destination="org.freedesktop.ModemManager1"/>
|
||||
|
||||
<allow send_destination="org.freedesktop.ModemManager1"
|
||||
send_interface="org.freedesktop.DBus.Introspectable"/>
|
||||
|
||||
<!-- Methods listed here are explicitly allowed or PolicyKit protected.
|
||||
The rest are restricted to root for security.
|
||||
-->
|
||||
</policy>
|
||||
|
||||
<policy user="root">
|
||||
<allow own="org.freedesktop.ModemManager1"/>
|
||||
<allow send_destination="org.freedesktop.ModemManager1"/>
|
||||
</policy>
|
||||
|
||||
<limit name="max_replies_per_connection">512</limit>
|
||||
</busconfig>
|
@@ -9,7 +9,7 @@
|
||||
<vendor_url>http://www.freedesktop.org/wiki/ModemManager</vendor_url>
|
||||
<icon_name>modem-manager</icon_name>
|
||||
|
||||
<action id="org.freedesktop.ModemManager.Control">
|
||||
<action id="org.freedesktop.ModemManager1.Control">
|
||||
<_description>Control the Modem Manager daemon</_description>
|
||||
<_message>System policy prevents controlling the Modem Manager.</_message>
|
||||
<defaults>
|
||||
@@ -18,7 +18,7 @@
|
||||
</defaults>
|
||||
</action>
|
||||
|
||||
<action id="org.freedesktop.ModemManager.Device.Control">
|
||||
<action id="org.freedesktop.ModemManager1.Device.Control">
|
||||
<_description>Unlock and control a mobile broadband device</_description>
|
||||
<_message>System policy prevents unlocking or controlling the mobile broadband device.</_message>
|
||||
<defaults>
|
||||
@@ -27,7 +27,7 @@
|
||||
</defaults>
|
||||
</action>
|
||||
|
||||
<action id="org.freedesktop.ModemManager.Device.Info">
|
||||
<action id="org.freedesktop.ModemManager1.Device.Info">
|
||||
<_description>Request mobile broadband device identifying information</_description>
|
||||
<_message>System policy prevents requesting identifying information from the mobile broadband device.</_message>
|
||||
<defaults>
|
||||
@@ -36,7 +36,7 @@
|
||||
</defaults>
|
||||
</action>
|
||||
|
||||
<action id="org.freedesktop.ModemManager.Contacts">
|
||||
<action id="org.freedesktop.ModemManager1.Contacts">
|
||||
<_description>Add, modify, and delete mobile broadband contacts</_description>
|
||||
<_message>System policy prevents adding, modifying, or deleting this device's contacts.</_message>
|
||||
<defaults>
|
||||
@@ -45,7 +45,7 @@
|
||||
</defaults>
|
||||
</action>
|
||||
|
||||
<action id="org.freedesktop.ModemManager.SMS">
|
||||
<action id="org.freedesktop.ModemManager1.Sms">
|
||||
<_description>Send, save, modify, and delete text messages</_description>
|
||||
<_message>System policy prevents sending or maniuplating this device's text messages.</_message>
|
||||
<defaults>
|
||||
@@ -54,7 +54,7 @@
|
||||
</defaults>
|
||||
</action>
|
||||
|
||||
<action id="org.freedesktop.ModemManager.Location">
|
||||
<action id="org.freedesktop.ModemManager1.Location">
|
||||
<_description>Enable and view geographic location and positioning information</_description>
|
||||
<_message>System policy prevents enabling or viewing geographic location information.</_message>
|
||||
<defaults>
|
||||
@@ -63,7 +63,7 @@
|
||||
</defaults>
|
||||
</action>
|
||||
|
||||
<action id="org.freedesktop.ModemManager.USSD">
|
||||
<action id="org.freedesktop.ModemManager1.USSD">
|
||||
<_description>Query and utilize network information and services</_description>
|
||||
<_message>System policy prevents querying or utilizing network information and services.</_message>
|
||||
<defaults>
|
||||
@@ -72,7 +72,7 @@
|
||||
</defaults>
|
||||
</action>
|
||||
|
||||
<action id="org.freedesktop.ModemManager.Firmware">
|
||||
<action id="org.freedesktop.ModemManager1.Firmware">
|
||||
<_description>Query and manage firmware on a mobile broadband device</_description>
|
||||
<_message>System policy prevents querying or managing this device's firmware.</_message>
|
||||
<defaults>
|
@@ -1,4 +1,4 @@
|
||||
[D-BUS Service]
|
||||
Name=org.freedesktop.ModemManager
|
||||
Name=org.freedesktop.ModemManager1
|
||||
Exec=@sbindir@/modem-manager
|
||||
User=root
|
Reference in New Issue
Block a user