build.gradle: update to SDK31 (#68)

Required for apps to update in the Play Store after November 1.

This requires:
- manifest must specify if Intents are exported.
- PendingIntent must declare FLAG_IMMUTABLE or MUTABLE

Signed-off-by: Denton Gentry <dgentry@tailscale.com>

Signed-off-by: Denton Gentry <dgentry@tailscale.com>
release-branch/1.32
Denton Gentry 2 years ago
parent ffe47d5ba7
commit 9b6f40ebb3

@ -25,9 +25,9 @@ android {
compileSdkVersion 30
defaultConfig {
minSdkVersion 22
targetSdkVersion 30
targetSdkVersion 31
versionCode 136
versionName "1.32.3-t9dd89b8c2-g246bf7b50e2"
versionName "1.33.21-t63ad49890-g80dfbd8a0c5"
}
compileOptions {
sourceCompatibility 1.8

@ -22,7 +22,8 @@
android:theme="@style/Theme.GioApp"
android:configChanges="orientation|screenSize|screenLayout|smallestScreenSize|keyboardHidden"
android:windowSoftInputMode="adjustResize"
android:launchMode="singleTask">
android:launchMode="singleTask"
android:exported="true">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
@ -55,7 +56,8 @@
</intent-filter>
</activity>
<service android:name=".IPNService"
android:permission="android.permission.BIND_VPN_SERVICE">
android:permission="android.permission.BIND_VPN_SERVICE"
android:exported="false">
<intent-filter>
<action android:name="android.net.VpnService"/>
</intent-filter>
@ -64,7 +66,8 @@
android:name=".QuickToggleService"
android:icon="@drawable/ic_tile"
android:label="@string/tile_name"
android:permission="android.permission.BIND_QUICK_SETTINGS_TILE">
android:permission="android.permission.BIND_QUICK_SETTINGS_TILE"
android:exported="true">
<intent-filter>
<action android:name="android.service.quicksettings.action.QS_TILE"/>
</intent-filter>

@ -45,7 +45,8 @@ public class IPNService extends VpnService {
}
private PendingIntent configIntent() {
return PendingIntent.getActivity(this, 0, new Intent(this, IPNActivity.class), PendingIntent.FLAG_UPDATE_CURRENT);
return PendingIntent.getActivity(this, 0, new Intent(this, IPNActivity.class),
PendingIntent.FLAG_UPDATE_CURRENT | PendingIntent.FLAG_IMMUTABLE);
}
private void disallowApp(VpnService.Builder b, String name) {

Loading…
Cancel
Save