From 873eee6422fdd7237b9bf86edb37f2958b23829e Mon Sep 17 00:00:00 2001 From: Bjoern Johansson Date: Thu, 6 Sep 2018 15:39:12 -0700 Subject: Create a network manager for the emulator Create a network manager for the emulator that will contain functionality related to network setup and management. Initial functionality includes address assignments to wifi interfaces as they come and go, and receiving and acting on wifi related commands over the qemu pipe. Currently the network manager only supports creation of access points and blocking/unblocking network traffic for an access point. In order to have a hostapd configuration file that can change the setup scripts will now copy the template configuration file to the vendor data partition which is writable and then modify it. BUG: 111997081 Test: Run CTS Verifier test Multinetwork connectivity Change-Id: I754e0c74cbaea9daa130915bed47ef3b2fba164e --- init.ranchu.rc | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'init.ranchu.rc') diff --git a/init.ranchu.rc b/init.ranchu.rc index 5871766..d7a61d4 100644 --- a/init.ranchu.rc +++ b/init.ranchu.rc @@ -57,7 +57,7 @@ on property:dev.bootcomplete=1 service ranchu-net /vendor/bin/init.ranchu-net.sh class late_start user root - group root wakelock + group root wakelock wifi oneshot service ipv6proxy /vendor/bin/execns router /vendor/bin/ipv6proxy -o eth0 -i wlan1,radio0-peer @@ -65,7 +65,7 @@ service ipv6proxy /vendor/bin/execns router /vendor/bin/ipv6proxy -o eth0 -i wla group root disabled -service emu_hostapd /vendor/bin/execns -u wifi -g wifi router /vendor/bin/hostapd_nohidl /vendor/etc/simulated_hostapd.conf +service emu_hostapd /vendor/bin/execns -u wifi -g wifi router /vendor/bin/hostapd_nohidl /data/vendor/wifi/hostapd/hostapd.conf user root group root wifi net_raw net_admin disabled @@ -75,6 +75,11 @@ service dhcpserver /vendor/bin/execns router /vendor/bin/dhcpserver --exclude-in group root disabled +service netmgr /vendor/bin/execns router /vendor/bin/netmgr --if-prefix wlan1_ --network 192.168.232.9/29 + user root + group root wifi + disabled + service dhcpclient_rtr /vendor/bin/execns router /vendor/bin/dhcpclient -i eth0 user root group root -- cgit v1.2.3