Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
[dbus] Expose dynamic mode configuration on D-Bus. JB#43928
When usb-moded causes network interfaces to be brought up/down, firewall
rules should be adjusted accordingly. However currently there is no way
for connman to know which interface changes might be related to for
example developer mode activation.

Expose dynamic usb mode configuration (attributes relevant to connman)
on D-Bus.

Broadcast a signal whenever target mode changes (mode transition begins,
or fallback mode gets activated due to mode transition errors).

Also provide a method call for querying the current target configuration.

Signed-off-by: Simo Piiroinen <simo.piiroinen@jollamobile.com>
  • Loading branch information
spiiroin committed Mar 8, 2019
1 parent 7061235 commit 57f8c99
Show file tree
Hide file tree
Showing 4 changed files with 307 additions and 28 deletions.
2 changes: 2 additions & 0 deletions debian/usb_moded.conf
Expand Up @@ -25,6 +25,8 @@
send_interface="com.meego.usb_moded" send_member="get_net_config"/>
<allow send_destination="com.meego.usb_moded"
send_interface="com.meego.usb_moded" send_member="rescue_off"/>
<allow send_destination="com.meego.usb_moded"
send_interface="com.meego.usb_moded" send_member="get_target_mode_config"/>
<deny send_destination="com.meego.usb_moded"
send_interface="com.meego.usb_moded" send_member="set_whitelist"/>
<deny send_destination="com.meego.usb_moded"
Expand Down
6 changes: 6 additions & 0 deletions src/com.meego.usb_moded.xml
Expand Up @@ -90,5 +90,11 @@
<signal name="sig_usb_whitelisted_modes_ind">
<arg name="modes" type="s"/>
</signal>
<signal name="sig_usb_taget_mode_config_ind">
<arg name="config" type="a{sv}"/>
</signal>
<method name="get_target_mode_config">
<arg name="config" type="a{sv}" direction="out"/>
</signal>
</interface>
</node>

0 comments on commit 57f8c99

Please sign in to comment.