- 08 Apr, 2016 1 commit
-
-
Lorenzo Colitti authored
netd_integration_test already runs all the tests in netd_test. Change-Id: I44c2ffaecded071a54af1c54c823856ffc6eb0cf
-
- 06 Apr, 2016 3 commits
-
-
Erik Kline authored
-
Erik Kline authored
Change-Id: I117adc3c7e240597e7fd91c709898bbbbe988261
-
Pierre Imai authored
Also add more test for netd's resolver. (cherry picked from commit 12f6baf1) Change-Id: I446f11b3462522ec3a18c2a3ec9401ad6cf77e8b
-
- 31 Mar, 2016 3 commits
-
-
Erik Kline authored
-
Erik Kline authored
Change-Id: I3e6560bbc46fd551d3501227250536cabeff4f71
-
Philip P. Moltmann authored
I added binary value support. This changes the format of the communication between the android framework and netd. Bug: 27696905 Change-Id: I85122062d63f1047c618be0b16e6e95621790fd6
-
- 30 Mar, 2016 2 commits
-
-
Lorenzo Colitti authored
Bug: 21725996 Change-Id: I2c049a934189f3c87ee15f052abc07d35814f0c9
-
Lorenzo Colitti authored
Bug: 21725996 Bug: 25691379 Change-Id: I24b838161eaf98dede2ae897157ba42414fc926f
-
- 28 Mar, 2016 2 commits
-
-
Lorenzo Colitti authored
Bug: 25691379 Bug: 21725996 Change-Id: Ia0598e60ad24714d53470e05849929831ba9dbf6
-
Lorenzo Colitti authored
This saves approximately 800ms on boot. From the perspective of the rules, this change is a no-op. As the unit test shows, the commands are the same, though some are in a slightly different order because iptables-restore requires that COMMIT be called between different tables (e.g., filter and mangle). For simplicity, enableBandwidthControl runs two iptables-restore commands instead of one. This is not semantically different from the previous code because the previous code just ran iptables commands one by one, which provides no atomicity. Running two commands is a bit slower than running one, but it's still much faster than using iptables. Using iptables-restore allows us to do things like ":<chain> -", which both creates the chain (if it does not already exist) and flushes it. This allows us to remove IPT_CLEANUP_COMMANDS and IPT_SETUP_COMMANDS. Those two sets of commands, which basically just did "-X bw_<foo>" and "-N bw_<foo>" were only necessary because the preceding "-F bw_<foo>" command would not create bw_<foo> if it did not already exist (e.g. in setupIptablesHooks, which runs on netd startup). Bug: 21725996 Change-Id: I6656aed4287dfcb2311c94800f430c143fb0b1a5
-
- 27 Mar, 2016 2 commits
-
-
Lorenzo Colitti authored
Bug: 25691379 Bug: 21725996 Change-Id: I196f568221b3bad98ba2d60e019c2b24c59a9cbc
-
Lorenzo Colitti authored
The data saver refactoring change was incorrect in >= two ways: 1. It relied on the bw_costly_shared chain, which is currently unused. NetworkManagementService just has a "TODO: support quota shared across interfaces" comment about it. What actually happens when setting quota is that each costly interface chain (e.g., bw_costly_rmnet_data0) directly hooks in the bw_penalty box chain. 2. Implementing app whitelisting using "RETURN" inside bw_happy_box was pointless because if data saver was enabled, there was a REJECT at the end of the bw_costly_shared chain that it was returning to. Instead, go back to the previous approach which hooked bw_happy_box at the end of bw_penalty_box. Also, add an additional bw_data_saver rule at the end of bw_happy_box. bw_data_saver only contains one rule: RETURN if data saver is enabled or REJECT if data saver is disabled. That way: 1. If the app is blacklisted, bw_penalty_box REJECTs. If not: 2. If the app is whitelisted (system apps are always whitelisted) bw_happy_box RETURNs to bw_costly_rmnet_data0, skipping bw_data_saver. 3. If an app is neither blacklisted nor whitelisted, bw_happy_box jumps to bw_data_saver. If data saver is enabled, it REJECTs the packet, and if not, it RETURNs to bw_costly_rmnet_data0. 4. When we RETURN to bw_costly_rmnet_data0, either because the app is whitelisted, or because data saver is off, bw_costly_rmnet_data0 applies mobile data usage limits, and then RETURNs to bw_OUTPUT, which calls xt_qtaguid, etc. Bug: 26685616 Bug: 27506285 Change-Id: If15397afde6862d95827a1fdd30f60efd7fab66a
-
- 25 Mar, 2016 1 commit
-
-
Lorenzo Colitti authored
Bug: 27824851 Change-Id: Iab5ebfd1c3d463d60d3dbd3a271737c8bc824298
-
- 24 Mar, 2016 1 commit
-
-
Lorenzo Colitti authored
Bug: 27824851 Change-Id: I98fa7aefdd9d0acf0a352970e3ba236227182da6
-
- 23 Mar, 2016 1 commit
-
-
Lorenzo Colitti authored
Bug: 26685616 Bug: 27506285 Change-Id: Id11ee717cfc1c79070b6bbec397986c25947646c
-
- 22 Mar, 2016 5 commits
-
-
Lorenzo Colitti authored
* changes: Stop using SIOCKILLADDR in netd. Add a rudimentary unit test for BandwidthController. Slightly restructure the data saver iptables rules. Remove the ability to enable/disable the happy box. Don't keep naughty/nice app state in BandwidthController.
-
Lorenzo Colitti authored
SOCK_DESTROY is now supported in all N device kernels. Bug: 26976388 Change-Id: I149ccda56edacac28602daddb01b5fd0222d5fb0
-
Lorenzo Colitti authored
Bug: 26685616 Bug: 27506285 Change-Id: I4457abd43697a0425f167b81c1432d743800abb8
-
Lorenzo Colitti authored
1. Make bw_costly_shared jump to bw_happy_box after bw_penalty_box. This allows the framework to manipulate whitelists and blacklists independently. 2. Make bw_happy box always whitelist system apps. Because bw_penalty_box is consulted before bw_happy_box, the framework can always blacklist certain system apps (e.g., the media server) by putting them in the blacklist. 3. Add a method to add/remove a reject at the end of bw_costly_shared. This will allow the framework to enable/disable data saver by changing only one rule. Bug: 26685616 Bug: 27506285 Change-Id: I67bff7c3c9ff5eb3f84fb84550cdf49f153e1b68
-
Erik Kline authored
This is called by "dumpsys netd". Bug: 27239233 Change-Id: I27fb308f8067243ff241a6f8fd6a83f406087d2a
-
- 21 Mar, 2016 1 commit
-
-
Dmitry Shmidt authored
Some wlan solutions can not switch or do not need to switch FW. In this case we don't want the function to fail and to prevent Wifi to start in settings. Bug: 27774657 Change-Id: I11f3cf709db6f17fc558454aa894e4a2211a9312 Signed-off-by:
Dmitry Shmidt <dimitrysh@google.com>
-
- 18 Mar, 2016 2 commits
-
-
Lorenzo Colitti authored
This code is unused, and the plan is to have the happy box enabled at all times. Bug: 26685616 Bug: 27506285 Change-Id: Ie15b0775d535df7ca94547a7d8b8a5ed536e6dbd
-
Lorenzo Colitti authored
Copies of this state are already kept in NetworkManagementService, NetworkPolicyManagerService, and iptables rules. A third copy of this state is not necessary. Bug: 26685616 Bug: 27506285 Change-Id: I8dd9fc60a28804ec95660092b13a2895f7480f56
-
- 17 Mar, 2016 1 commit
-
-
Lorenzo Colitti authored
Starting CommandListener tells NetworkManagementService that netd is ready to accept commands. Ensure that the binder service is started (i.e., we have called startThreadPool) before we do this. Bug: 27239233 Change-Id: Ica89e72f51eb4752cb5cea2e4096c6a9dc5776d7
-
- 14 Mar, 2016 2 commits
-
-
Felipe Leme authored
BUG: 27506285 BUG: 26685616 Change-Id: I8352ebbab1778c85e0a1da79a0acede5aea144a1
-
Pierre Imai authored
Change-Id: Ica37a812c37036ffecd45b8f078d8ed9928d01fc
-
- 09 Mar, 2016 1 commit
-
-
Erik Kline authored
Specifically: set explicitlySelected, protectedFromVpn and permissions. Bug: 26256264 Change-Id: I1ebd2c1878fb7166ac63c061c8731e66b0050a30
-
- 02 Mar, 2016 5 commits
-
-
Lorenzo Colitti authored
* changes: Move SockDiagTest into system/netd/server. Add an RPC to replace a UID firewall rule. Allow finer-grained locking, and use it in FirewallCmd.
-
Lorenzo Colitti authored
My recollection is that we decided to put unit tests next to the corresponding code and integration tests into tests/. Change-Id: I2dc1a074ba8d323253d9be3b2052d6b287bacc15
-
Lorenzo Colitti authored
Also add a binder_test that exercises binder RPCs to the real netd service running on the device Bug: 21725996 Bug: 27239233 Change-Id: Ic83d81605021a0578d6cd32f889290be61d76125
-
Erik Kline authored
am: 87732125 * commit '87732125': Remove unused costName variable
-
Erik Kline authored
Bug: 27432583 Change-Id: Ica6f8714eb6c40a4b6a94ac5e40144d0e781155e
-
- 01 Mar, 2016 1 commit
-
-
Felipe Leme authored
-
- 26 Feb, 2016 1 commit
-
-
Lorenzo Colitti authored
FirewallController is stateless and FirewallCmd does not access any other controllers, so it is safe not to take the big netd lock. Bug: 27239233 Change-Id: I246696c4b17fa005c7d6b38ecd627747aa608831
-
- 25 Feb, 2016 3 commits
-
-
Lorenzo Colitti authored
Change-Id: Ibdda590b828c61caa488e959f3e596dc981a2c65
-
Pierre Imai authored
Change-Id: Icd89045c7099949ea66bd88b2ce5551301366640
-
Pierre Imai authored
Change-Id: Icb76b43e89c5a9e5806b95002d3653dd99912494
-
- 23 Feb, 2016 2 commits
-
-
Lorenzo Colitti authored
Bug: 27239233 Change-Id: I34a5554604e6d8b8a50838c6911c28503cbf4540
-
Lorenzo Colitti authored
In this change: 1. AIDL files for a new, android.net.INetd service, and corresponding implementation using generated code. For now the interface is just a prototype: it only has one trivial method. 2. Permission checking code to check for CONNECTIVITY_INTERNAL. 3. Add a Big Netd Lock and provide a wrapper that makes it easy to ensure that it is taken by every CommandListener command. Bug: 27239233 Change-Id: I448d0ac233edd0e351a7fe7f13901fb6871683a2
-