History log of /frameworks/base/core/java/android/net/CaptivePortalTracker.java
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
3ec8e7fb79f2e662c2b06cfec118a0eeaefd9370 03-Oct-2013 Wink Saville <wink@google.com> Use networkType to display wifi and mobile notification separately.

There are two bugs one is I was clearing the notification in
CaptivePortalTracker when entering the ActivateState. (double check
according to bug 5021626 we should be calling enter)

Second is we could have the need to display both icons but can't
because we only allow one.

The solution I'm proposing here is to allow two notifications and
have then controlled separately.

Bug: 10886908
Change-Id: I30e7130bc542535492d175640a4990c592f32806
/frameworks/base/core/java/android/net/CaptivePortalTracker.java
9d4204d6257bf69885cf0718aa3adaa17457c318 30-Aug-2013 Wink Saville <wink@google.com> Add debug and remove SocketTimeoutException.

Bad merge from jb-mr2 to klp, the SocketTimeoutException
in isCaptivePortal should not be present. Also add debug
for bug 9972012. The SocketTimeoutException is a possible
cause of 9972012 but the logs from post #24 it was not
caused by a timeout, so this is not a fix.

Bug: 9972012
Change-Id: I290518832f8258d4682821815834f5621245b643
/frameworks/base/core/java/android/net/CaptivePortalTracker.java
7788c61af5927a0fac612ea94d5205eeec2f507f 29-Aug-2013 Wink Saville <wink@google.com> Merge commit '270226b0' into manualmerge

* commit '270226b0':
Add support for handling mobile provisioning networks.

Conflicts:
core/java/android/net/CaptivePortalTracker.java
core/java/android/net/ConnectivityManager.java
core/java/android/net/IConnectivityManager.aidl
core/java/android/net/MobileDataStateTracker.java
core/res/AndroidManifest.xml
services/java/com/android/server/ConnectivityService.java

Change-Id: I3925004011bb1243793c4c1b963d923dc2b00cb5
948282b0e6cf5310f09db97a4ae939db7c1cef72 29-Aug-2013 Wink Saville <wink@google.com> Add support for handling mobile provisioning networks.

When a sim is new or it has expired it needs to be provisioned
with the carrier. Basically provisioning is associating a sim with
a user account. When a sim isn't provisioned then operators will
restrict access to the network and only allow certain addresses
or services to be used.

This set of changes allows two types of provisioning networks to be
recognized. The first is a network that causes all DNS lookups to be
redirected to a different address than was intended. This is exemplified
by how T-Mobile works.

The second technique uses a special apn for provisioning. An example is
AT&T where lwaactivate is the provisioning apn and broadband is the
normal apn. We first try broadband and if we are unable to connect we
try lwaactivate. When we see the activate we identify it as special and
the ApnContext.isProvisioningApn will return true.

In the future our plan is to create a new network type that can be added
to the apn list, but for now it identified by name.

Here is a list of significant changes:

- CaptivePortalTracker now only test WiFi networks instead of all networks
- checkMobileProvisioning checks for provisioning networks and doesn't
try to ping.
- IConnectivityManager.aidl changes:
* getProvisioningOrActiveNetworkInfo was added to and used by Manage
mobile plan in WirelessSettings so even when there is no active
network it will still allow provisioning. Otherwise it would report
no internet connection.
* setSignInErrorNotificationVisible is used by both
CaptiviePortalTracker and checkMobileProvisioning so they use the
same code for the notifications.
* checkMobileProvisioning was simplified to have only a timeout as
returning the result is now harder as we abort simultaneous call
otherwise we'd could get into loops because we now check every time
we connect to mobile.
- Enhanced MDST to handle the provisioning network.
- Added CONNECTED_TO_PROVISIONING_NETWORK to NetworkInfo to make a new
state so we don't announce to the world we're connected.
- TelephonyIntents.ACTION_DATA_CONNECTION_CONNECTED_TO_PROVISIONING_APN
is sent by the low level data connection code to notify Connectivity
Service that a provisioning apn has connected. This allows CS to
handle the connection differently than a normal connection.

Bug: 10328264
Change-Id: I3925004011bb1243793c4c1b963d923dc2b00cb5
/frameworks/base/core/java/android/net/CaptivePortalTracker.java
89d16f7597d9e03bf3cf9eb1ba91b590ab1ac892 09-Aug-2013 Wink Saville <wink@google.com> am 9b7b4450: am 02eab434: am 4d87d91d: Merge "If in a mobile captive portal is detected enable fail fast." into jb-mr2-dev

* commit '9b7b4450185e723dc7021f7e8bae4a12d4dd5606':
If in a mobile captive portal is detected enable fail fast.
292a92e337f0a1b28b83f990459393f0d368c164 09-Aug-2013 Wink Saville <wink@google.com> am 7c00be48: am 55adb390: am 35152f13: Merge "Have CaptivePortalTracker use gservices updateable provisioning urls." into jb-mr2-dev

* commit '7c00be48fcb1986db14915beef549e925b5670d2':
Have CaptivePortalTracker use gservices updateable provisioning urls.
f35f3201db321c501ea3cdeeae36e88480bbe835 09-Aug-2013 Wink Saville <wink@google.com> Merge commit '81132d51' into fix-merge-conflict

* commit '81132d51':
In CaptiviePortalTracker a socket timeout is probably a captive portal.

Change-Id: I624732a5c29427bc22a156ccd46e6ff727af09c5
4d87d91dfe886713df96abd3c0d1c9e20cf385e5 09-Aug-2013 Wink Saville <wink@google.com> Merge "If in a mobile captive portal is detected enable fail fast." into jb-mr2-dev
35152f13b3302dbcb43345458dd5b8b092e37320 09-Aug-2013 Wink Saville <wink@google.com> Merge "Have CaptivePortalTracker use gservices updateable provisioning urls." into jb-mr2-dev
d747cbc898ef44e59c3fbf74a8327b6a12aad397 08-Aug-2013 Wink Saville <wink@google.com> If in a mobile captive portal is detected enable fail fast.

When captive portal checking completes pass back the result.
This is used to enable/disable failing fast for mobile. When
failing fast is enabled we don't check for data stalls and thus
won't be continually trying to do recovery operations, such as
restarting the radio.

Bug: 9462512
Change-Id: I0dea0eee519f8ee7f94e79d40e82c18f30d7fe2e
/frameworks/base/core/java/android/net/CaptivePortalTracker.java
1ed51627d94b140e8893b8e1dcde9bf37e2adca7 01-Aug-2013 Brian Williammee <bwill@google.com> Track latency of captive portal checks

When captive portal check occurs, track its latency, whether or not
we received a response, and whether or not the response was a captive
portal. Pair with information identifying the access point / base
station, and broadcast it (with a system|signature-protected
permission).

Broadcast only occurs if user has consented to
Settings.Global.WIFI_SCAN_ALWAYS_AVAILABLE.

Change-Id: I6fd59954a7ee2cc7acedf064a1465882653b2173
/frameworks/base/core/java/android/net/CaptivePortalTracker.java
bf34122a96ef3d02e9b7935e07eb4f9b04034828 02-Aug-2013 Wink Saville <wink@google.com> In CaptiviePortalTracker a socket timeout is probably a captive portal.

On a AT&T warm SIM a socket is not possible so a timeout occurs.
In CheckMp a timing out on a socket is declared as a "warm" sim,
make CaptivePortalTracker the same.

Bug: 10038362
Change-Id: Icb9fb0a1b67704dc9adf6a6348a3781fb9582a89
/frameworks/base/core/java/android/net/CaptivePortalTracker.java
42d4f08db2c15e1829c1fc5d1942cf029ab0895b 21-Jul-2013 Wink Saville <wink@google.com> Have CaptivePortalTracker use gservices updateable provisioning urls.

After detecting there is a captive portal the url used in the
notification for mobile networks should be updateable via gservices.
These urls will be the same as used by CheckMp and is needed for
carriers that have specific provisioning urls such as AT&T and Verizon.

Bug: 9622647
Change-Id: Idcf4dabc72ece1dbbe1d5e5a21e550dd06fe16c7
/frameworks/base/core/java/android/net/CaptivePortalTracker.java
108da0cfa4a2f59cc953a4ec61314e69b61d6777 12-Feb-2013 Russell Brenner <russellbrenner@google.com> Adjust captive portal test for setup wizard

During setup wizard, perform captive portal test without the typical
delays.

Change-Id: If596948e732966817aae6201440e87e19be0c2f8
/frameworks/base/core/java/android/net/CaptivePortalTracker.java
58c73c3f76c231cf128041aefadd4b6a6bcefac2 28-Jan-2013 Wink Saville <wink@google.com> Add protected log methods to StateMachine

This allow child classes to Override the logging and
have consistent behavior across StateMachines.

Change-Id: I7e23a44d08ca304ade2d7830fd0e307f63f1879e
/frameworks/base/core/java/android/net/CaptivePortalTracker.java
ebb8f413e63dee6d96904a49a3508b97671e5fe8 03-Oct-2012 Irfan Sheriff <isheriff@google.com> Add icon for mobile notification

Bug: 7087564
Change-Id: If856bdfa28c024fb775fd3f8231bd5a16fef59e6
/frameworks/base/core/java/android/net/CaptivePortalTracker.java
b8aad91f059527e04abaf8a83ed1ce6b5f09c55d 02-Oct-2012 Irfan Sheriff <isheriff@google.com> Add operator name to network notification

Bug: 7087564
Change-Id: Ibe7a09fc6858dfea5f65092777bbd6ca82177043
/frameworks/base/core/java/android/net/CaptivePortalTracker.java
625239a05401bbf18b04d9874cea3f82da7c29a1 27-Sep-2012 Jeff Sharkey <jsharkey@android.com> Migrate more Secure settings to Global.

Migrate networking, storage, battery, DropBox, and PackageManager
related Secure settings to Global table.

Bug: 7232014, 7231331, 7231198
Change-Id: I772c2a9586a2f708c9db95622477f235064b8f4d
/frameworks/base/core/java/android/net/CaptivePortalTracker.java
9538bdd3c77968c7673719c580ae653ede4654d6 20-Sep-2012 Irfan Sheriff <isheriff@google.com> Captive check for both mobile and wifi

Bug: 7113195
Bug: 7102238
Bug: 7087564

Change-Id: Iac08db9de3935338ad498aa3983d2ca82057dda1
/frameworks/base/core/java/android/net/CaptivePortalTracker.java
7f0aaac7f2a2bff6168467132c704fce2c7ca170 19-Sep-2012 Irfan Sheriff <isheriff@google.com> Get strings in

Bug: 65904101
Bug: 7087564
Change-Id: Ic4887a737a640010e12efd2a16b24af2215ba72a
/frameworks/base/core/java/android/net/CaptivePortalTracker.java
da6da0907b28d4704aabbdb1bbeb4300954670d1 16-Aug-2012 Irfan Sheriff <isheriff@google.com> Captive portal handling

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
/frameworks/base/core/java/android/net/CaptivePortalTracker.java