Fix permission issues on Android 13
This commit is contained in:
@@ -11,7 +11,7 @@ Connecting things to your VPN made simple. Share your VPN connection over hotspo
|
|||||||
|
|
||||||
| Release channel | [GitHub (recommended)](https://github.com/Mygod/VPNHotspot/releases) | [Google Play](https://play.google.com/store/apps/details?id=be.mygod.vpnhotspot) ([beta](https://play.google.com/apps/testing/be.mygod.vpnhotspot)) |
|
| Release channel | [GitHub (recommended)](https://github.com/Mygod/VPNHotspot/releases) | [Google Play](https://play.google.com/store/apps/details?id=be.mygod.vpnhotspot) ([beta](https://play.google.com/apps/testing/be.mygod.vpnhotspot)) |
|
||||||
|---------------------------------------------------------|:--------------------------------------------------------------------:|:---------------------------------------------------------------------------------------------------------------------------------------------------:|
|
|---------------------------------------------------------|:--------------------------------------------------------------------:|:---------------------------------------------------------------------------------------------------------------------------------------------------:|
|
||||||
| Monitor connected clients without root | ✓ | Up to Android 10 |
|
| Monitor connected clients without root | Up to Android 12L | Up to Android 10 |
|
||||||
| Use repeater/temporary hotspot without location enabled | Up to Android 10/9 | Up to Android 10/9 or Android 13+ |
|
| Use repeater/temporary hotspot without location enabled | Up to Android 10/9 | Up to Android 10/9 or Android 13+ |
|
||||||
| Auto update | Email updates via watching releases | ✓ |
|
| Auto update | Email updates via watching releases | ✓ |
|
||||||
| In-app update channel | GitHub | Google Play |
|
| In-app update channel | GitHub | Google Play |
|
||||||
|
|||||||
@@ -29,7 +29,8 @@ abstract class IpMonitor {
|
|||||||
"Dump (was interrupted and may be inconsistent.|terminated)$)").toRegex()
|
"Dump (was interrupted and may be inconsistent.|terminated)$)").toRegex()
|
||||||
var currentMode: Mode
|
var currentMode: Mode
|
||||||
get() {
|
get() {
|
||||||
val isLegacy = Build.VERSION.SDK_INT < 30 || BuildConfig.TARGET_SDK < 30
|
// Completely restricted on Android 13: https://github.com/termux/termux-app/issues/2993#issuecomment-1250312777
|
||||||
|
val isLegacy = Build.VERSION.SDK_INT < 33 && (Build.VERSION.SDK_INT < 30 || BuildConfig.TARGET_SDK < 30)
|
||||||
val defaultMode = if (isLegacy) @Suppress("DEPRECATION") {
|
val defaultMode = if (isLegacy) @Suppress("DEPRECATION") {
|
||||||
Mode.Poll
|
Mode.Poll
|
||||||
} else Mode.MonitorRoot
|
} else Mode.MonitorRoot
|
||||||
|
|||||||
@@ -120,7 +120,6 @@ data class SoftApConfigurationCompat(
|
|||||||
"WPA3-OWE Transition",
|
"WPA3-OWE Transition",
|
||||||
"WPA3-OWE",
|
"WPA3-OWE",
|
||||||
)
|
)
|
||||||
val DEFAULT_TIMEOUT = if (BuildConfig.TARGET_SDK >= 33 && Build.VERSION.SDK_INT >= 33) -1L else 0L
|
|
||||||
|
|
||||||
private val qrSanitizer = Regex("([\\\\\":;,])")
|
private val qrSanitizer = Regex("([\\\\\":;,])")
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user