-
-
Notifications
You must be signed in to change notification settings - Fork 160
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Track VPN mode changes #225
Comments
#225 Introduced ConnectivityManager.NetworkCallback() to track down the changes for the "Block connections without VPN" in Settings-> VPN. The callback will restart the VPN services if necessary and include/exclude the apps which are part of excluded apps list. #193 - Now the universal firewall(Block apps not in use) feature will prompt for the application force stop in case of application crash/failure in getting the accessibility permission. Removed the scroll calculation done for the swipe from one fragment to other in the view pager(firewall and DNS screen). Instead introduced new NestedScrollableHost(FrameLayout) to detect the swipe.
So, it looks like neither |
Or, wait, may be we were doing it incorrectly, ref: com.android.cts.vpnfirewall.ReflectorVpnService.
|
The above callback works only when "Always-on VPN" is toggled but not for "Block connections without VPN". One approach to consider now is, to check |
As of now, work around is introduced to check for the lockdown mode. Callbacks for the "Block Connection without VPN" is not |
So, |
From a quick glance at AOSP code, it looks like we can fully expect
ConnectivityManager.NetworkCallback#onCapabilitiesChange
to trigger whenever the VPN goes in and out of thelockdown
("Block connections without VPN") mode.Check for
VpnService#isLockdownEnabled
then when the callback triggers and rebuild the VPN as required (enabling exclude-apps and allowing VPN bypass when VPN not locked down, for example).See: #178, #39, #224
The text was updated successfully, but these errors were encountered: