summaryrefslogtreecommitdiff
path: root/services/java/com/android/server/ConnectivityService.java
Commit message (Collapse)AuthorAgeFilesLines
...
| * Set routes from stacked links as well.Lorenzo Colitti2013-03-151-8/+13
| | | | | | | | | | | | | | | | | | Currently, ConnectivityService adds and removes routes to/from the routing table only based on the LinkProperties's routes. Make it update routes based on the stacked links as well. Bug: 8276725 Change-Id: I9a2adf537af5a04de0aaab3780afbcc3bb5c6acb
* | Revert "Fail fast if somebody is adding default routes"Wink Saville2013-03-151-14/+0
|/ | | | | | | | This reverts commit 6f210bd0191e1936bbc1f036912c6efc4ea69475 Mako wouldn't boot for me, reverting for now. Change-Id: Ie92d6bf77811e7257e86d65e1e15e1973c027cd7
* Fail fast if somebody is adding default routesRobert Greenwalt2013-03-141-0/+14
| | | | | bug:2655011 Change-Id: I25da940e024825bc6e1d1ac5fe7b0d951609c1c1
* Remove redundant parameter to modifyRouteLorenzo Colitti2013-03-121-6/+7
| | | | | | | | | modifyRoute takes both an interface name and a LinkProperties. This is redundant because all callers get the interface name from the LinkProperties. Make modifyRoute get the interface name from the LinkProperties instead. Change-Id: I41ba8e0a10241c2f1107204fcaca2be74556042b
* Always specify an interface for host routes.Lorenzo Colitti2013-03-081-5/+8
| | | | Change-Id: I05b4d87e7d7e8237c6f4a70f1fedae00f416f581
* Allow loopback traffic in lockdown mode.Jeff Sharkey2013-02-281-0/+1
| | | | | Bug: 8245184 Change-Id: If993e3d6f5c7ce5970bfe701074c85b9245aa2aa
* Remove two new permission checksRobert Greenwalt2013-02-221-2/+8
| | | | | | | | These checks while technically reasonable are a hard to swallow API change that may break existing apps and pragmatically serves no purpose: the protected data is available in publicly readable java VM properties. Change-Id: I522c493c2604a33e28d99e2be31054326c9a8323
* Improve ConnectivityManager docsRobert Greenwalt2013-02-221-2/+6
| | | | | | | Also fix some permission problems. bug:5738328 Change-Id: Ib32c223f425b1fc03b8cce528456bcb50b540fdf
* Migrate to using Mockito directly.Jeff Sharkey2013-02-191-11/+4
| | | | Change-Id: I1fcc5d1a780f5831bd6685f0735d4c0c6d245735
* am dc7b3e3b: am 9657ba0e: Merge "KeyStore: stop using state()"Kenny Root2013-02-141-1/+1
|\ | | | | | | | | | | # Via Android Git Automerger (1) and others * commit 'dc7b3e3b6e1aa3f347c7d843ee453688c4d90e29': KeyStore: stop using state()
| * KeyStore: stop using state()Kenny Root2013-02-141-1/+1
| | | | | | | | Change-Id: I721974fd95f8d1ab06a3fd1bbb4c9b4d9d1d7752
* | Fix a permissions probem in ConnectivityManagerRobert Greenwalt2013-02-121-1/+7
| | | | | | | | | | | | stopUsingNetworkFeature fails because of new permissions checks in netd. Change-Id: I04cb10d955c9dd9977c460c6c1db0d1910a863ce
* | Reintroduce the net.dns system properties <TEMP>Robert Greenwalt2013-02-111-0/+12
| | | | | | | | | | | | | | | | | | | | Removing these properties broke video playback as they used a custom dns resolver. We'll work together to resolve our resolver issues in the future, but this was the easy fix to get things working again. bug:8173236 Change-Id: I687dae59eda4fc449efc34eed11c3dc88a110ad0
* | Merge "Second pass tying into dns cache per interface"Robert Greenwalt2013-02-071-114/+43
|\ \
| * | Second pass tying into dns cache per interfaceMattias Falk2013-02-061-114/+43
| | | | | | | | | | | | | | | | | | | | | | | | | | | Set dns servers for secondary nets and attach the processes (pids) that are using the secondary nets to the secondary nets associated dns cache. bug:5465296 Change-Id: I1eaf92d5c6b81d287e9fb2763b3d972d9de34395
* | | Merge "Revert "Clean up published network condition reporting.""Wink Saville2013-01-311-21/+18
|\ \ \ | |/ / |/| |
| * | Revert "Clean up published network condition reporting."Wink Saville2013-01-311-21/+18
| | | | | | | | | | | | | | | | | | | | | | | | In some cases causes grey ICON's. This reverts commit 82413d0b2acad73b9a008e0c53392a54f9555cf8 Change-Id: I09f893d03651c3fb9fcb88ee9e5ac7ce6cb6e273
* | | Merge "Revert "Second pass tying into dns cache per interface""Robert Greenwalt2013-01-191-43/+114
|\ \ \ | |/ / |/| |
| * | Revert "Second pass tying into dns cache per interface"Robert Greenwalt2013-01-191-43/+114
| | | | | | | | | | | | | | | | | | This reverts commit f60f94a89e49c125f4aff6496710a0fb66579545 Change-Id: If52dffd5100a6b03275da0eabfa05e24c5ecada9
* | | Clean up published network condition reporting.Wink Saville2013-01-181-18/+21
|/ / | | | | | | Change-Id: I371c04bcb0547f1133e7ce12a6871aad3b3fdc6b
* | Second pass tying into dns cache per interfaceMattias Falk2013-01-111-114/+43
| | | | | | | | | | | | | | | | | | Set dns servers for secondary nets and attach the processes (pids) that are using the secondary nets to the secondary nets associated dns cache. Change-Id: Id865c2c3fdc0ec1c3e30c134e9ea4109f4f2fbeb bug:5465296
* | am 48576911: Merge from AOSP staging branchJean-Baptiste Queru2012-12-181-2/+5
|\| | | | | | | | | | | * commit '48576911a2de25c46ecfbecdf7dcb373b70be3a5': Return error upon attempt to use non-existent APN Memory leak due to bad destroy sequence
| * Merge from AOSP staging branchJean-Baptiste Queru2012-12-181-2/+5
| |\ | | | | | | | | | Change-Id: Iad3df4845e6fae16c4ae6dbddcad0121d4775dcd
| | * Return error upon attempt to use non-existent APNMikael Hedegren2012-12-181-2/+5
| | | | | | | | | | | | | | | | | | | | | | | | startUsingNetworkFeature will ignore errors from reconnect - causing ConnectivityService to send faulty information back to requester. Change-Id: I4e0fcc1addd84da409cdc1eed1a95d25d925e020
* | | Refactor getPersistedNetworkPreferenceJianzheng Zhou2012-12-061-6/+16
| | | | | | | | | | | | | | | | | | | | | | | | Optimize for updating mNetworkPreference according to device's networkAttributes setting from overlay config.xml when connectivityservice start. Change-Id: I90286332d4f453038f1ddac7dd9d1265d96b4859 Signed-off-by: Jianzheng Zhou <jianzheng.zhou@freescale.com>
* | | Merge "Support for dns domain."Robert Greenwalt2012-11-161-7/+7
|\ \ \ | |/ / |/| |
| * | Support for dns domain.Robert Greenwalt2012-11-161-7/+7
| |/ | | | | | | | | bug:6799630 Change-Id: I10070eddb65b7b60f0bc2b3e1e320e1aa4ec6e98
* / Increase readability of connectivity event log.Jeff Sharkey2012-11-091-12/+2
|/ | | | | Bug: 6322766 Change-Id: I556759f5fc1466cdd4db6b4574084a8068dc9909
* Remove extraneous logs.Dianne Hackborn2012-11-081-2/+2
| | | | Change-Id: I4c47d36748de91bd6fddc419afbf59552bf63e9a
* Migrate more Secure settings to Global.Jeff Sharkey2012-09-271-20/+20
| | | | | | | | Migrate networking, storage, battery, DropBox, and PackageManager related Secure settings to Global table. Bug: 7232014, 7231331, 7231198 Change-Id: I772c2a9586a2f708c9db95622477f235064b8f4d
* First step towards cleaning up Global settings.Jeff Sharkey2012-09-261-2/+2
| | | | | | | Remove all @Deprecated @hide settings, and clean up any stragglers. Bug: 7232125 Change-Id: Ibf67093c728d4a28565129b923edb1701d3b2789
* Update references to migrated global settings.Jeff Brown2012-09-251-9/+9
| | | | | | | | | | Fixed one setting that was migrated but not marked deprecated. Removed a hidden setting that is no longer used by the new power manager service. Bug: 7231172 Change-Id: I332f020f876a18d519a1a20598a172f1c98036f7
* Captive check for both mobile and wifiIrfan Sheriff2012-09-201-6/+6
| | | | | | | | Bug: 7113195 Bug: 7102238 Bug: 7087564 Change-Id: Iac08db9de3935338ad498aa3983d2ca82057dda1
* Actually move to Global settings.Jeff Sharkey2012-09-141-2/+17
| | | | | | | Also add better ConnectivityService logging. Bug: 7157464 Change-Id: Ia235a7e62ed809240913c4782920c1410c7d597d
* Restrict lockdown and firewall to AID_SYSTEM.Jeff Sharkey2012-09-061-1/+9
| | | | | Bug: 7076289 Change-Id: Iafa3054335e8b1c3c8c3b8db2a4191d4ed4c8c41
* Fix another issue #7097984 java.lang.SecurityException: Permission Denial:Dianne Hackborn2012-09-041-5/+25
| | | | | | | | broadcast asks to run as user -1 but is calling from user 0; this requires Dupped bug of a different problem. Change-Id: I15f4ab08b81f5f5746ba1cd183dee4f0b1281df5
* Improve multi-user broadcasts.Dianne Hackborn2012-08-301-5/+7
| | | | | | | | | | | | | | | | | | | You can now use ALL and CURRENT when sending broadcasts, to specify where the broadcast goes. Sticky broadcasts are now correctly separated per user, and registered receivers are filtered based on the requested target user. New Context APIs for more kinds of sending broadcasts as users. Updating a bunch of system code that sends broadcasts to explicitly specify which user the broadcast goes to. Made a single version of the code for interpreting the requested target user ID that all entries to activity manager (start activity, send broadcast, start service) use. Change-Id: Ie29f02dd5242ef8c8fa56c54593a315cd2574e1c
* Captive portal handlingIrfan Sheriff2012-08-271-21/+63
| | | | | | | | | | We now notify the user of a captive portal before switching to the network as default. This allows background applications to continue to work until the user confirms he wants to sign in to the captive portal. Also, moved out captive portal handling out of wifi as a seperate component. Change-Id: I7c7507481967e33a1afad0b4961688bd192f0d31
* Always-on VPN.Jeff Sharkey2012-08-271-7/+124
| | | | | | | | | | | | | | | | | | | Adds support for always-on VPN profiles, also called "lockdown." When enabled, LockdownVpnTracker manages the netd firewall to prevent unencrypted traffic from leaving the device. It creates narrow rules to only allow traffic to the selected VPN server. When an egress network becomes available, LockdownVpnTracker will try bringing up the VPN connection, and will reconnect if disconnected. ConnectivityService augments any NetworkInfo based on the lockdown VPN status to help apps wait until the VPN is connected. This feature requires that VPN profiles use an IP address for both VPN server and DNS. It also blocks non-default APN access when enabled. Waits for USER_PRESENT after boot to check KeyStore status. Bug: 5756357 Change-Id: If615f206b1634000d78a8350a17e88bfcac8e0d0
* Migrate legacy VPN arguments to system_server.Jeff Sharkey2012-08-241-6/+16
| | | | | | | | Generate the racoon and mtpd daemon arguments in system_server, instead of accepting them from Settings. Bug: 5756357 Change-Id: I42c1a644f6add477fe4222342640d7db15982cb8
* Begin moving VPN to NetworkStateTracker pattern.Jeff Sharkey2012-08-231-8/+15
| | | | | | | | | | | | Created base tracker that handles common bookkeeping, and move VPN to become a tracker. VPN status is now reflected in NetworkInfo, and is mapped to LegacyVpnInfo. Legacy VPN now "babysits" any init services it starts, watching for when they stop unexpectedly. Bug: 5756357 Change-Id: Iba7ec79da69469f6bd9a970cc39cf6b885b4c9c4
* Update TCP buffer size when switching network typeRobert Greenwalt2012-08-201-0/+5
| | | | | | | | | | | | | Import of non-merging change 41612 from AOSP When PDP connects in GSM network, the TCP buffer window size is set to max 8760. If the phone swicthes to UMTS, the TCP buffer size is not updated to UMTS, i.e. GPRS buffer size is still used with limited data transfer spead as a result. This fix makes sure the TCP buffer size is updated when switching network type. Change-Id: Ic44a557677ffe629e83ce1f522a9f058bee6e7b2
* Setup idletimer for network interface.Haoyu Bai2012-08-101-0/+58
| | | | | | | Cherry-picked from commit f71ca8a5728e425de61ba794c9653dd0b04f16e3 in master. DO NOT MERGE Change-Id: I6101c7ae041b4cc1237ce7a9983753dbdfa301d3
* Merge "Isolate NetworkStateTracker creation, test." into jb-mr1-devJeff Sharkey2012-08-081-70/+102
|\
| * Isolate NetworkStateTracker creation, test.Jeff Sharkey2012-08-081-70/+102
| | | | | | | | | | | | | | | | | | Change ConnectivityService to use a factory when creating NetworkStateTrackers, which gives us a good place to inject mocks for testing. Add initial tests to verify that network routes are added and removed as networks changed. Change-Id: I11cbc61a84c2ed4afa2670036295b1494eab26e1
* | Merge "Include network type that caused broadcast." into jb-mr1-devJeff Sharkey2012-08-061-0/+3
|\ \ | |/ |/|
| * Include network type that caused broadcast.Jeff Sharkey2012-08-061-0/+3
| | | | | | | | | | | | | | | | Network type can be obtained through EXTRA_NETWORK_INFO, but offer it as first-class extra since the returned NetworkInfo is deprecated. Bug: 6936247 Change-Id: Ief59577afd2bd930f0f4c5650b413feef86bfbc3
* | Make generic BaseNetworkObserver.Jeff Sharkey2012-08-051-15/+5
|/ | | | | | | This makes it easier to add new INetworkManagementEventObserver events in future. Change-Id: I432263d745558de4b878f313c1951230ed9db2b1
* Split NST handler events away from CS internals.Jeff Sharkey2012-07-261-46/+49
| | | | | | | Instead of sharing event space, use a different handler backed by the same looper. Change-Id: I11f1e4701c341665770ca640f3cba0c295bb7561
* Network data activity change intent for network interfaces.Haoyu Bai2012-07-171-0/+29
| | | | | | | | The activity notification is received from netd, an intent DATA_ACTIVITY_CHANGE is then raised for other part of the system to consume. Change-Id: Idfcc4763c51c5b314c57f546c12557082f06bebf