Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion Android/app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,10 @@

<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.CHANGE_NETWORK_STATE" />
<uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED" />
<uses-permission android:name="android.permission.FOREGROUND_SERVICE" />
<uses-permission android:name="android.permission.FOREGROUND_SERVICE_CONNECTED_DEVICE" />
<uses-permission android:name="android.permission.VIBRATE"/>
<uses-permission android:name="android.permission.QUERY_ALL_PACKAGES"/>

Expand All @@ -30,7 +32,8 @@
android:name="app.intra.sys.IntraVpnService"
android:exported="false"
android:label="@string/app_name"
android:permission="android.permission.BIND_VPN_SERVICE" >
android:permission="android.permission.BIND_VPN_SERVICE"
android:foregroundServiceType="connectedDevice">
<intent-filter>
<action android:name="android.net.VpnService"/>
</intent-filter>
Expand Down
9 changes: 8 additions & 1 deletion Android/app/src/main/java/app/intra/sys/IntraVpnService.java
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
import android.content.Intent;
import android.content.SharedPreferences;
import android.content.pm.PackageManager;
import android.content.pm.ServiceInfo;
import android.net.ConnectivityManager;
import android.net.Network;
import android.net.NetworkInfo;
Expand Down Expand Up @@ -190,7 +191,13 @@ public int onStartCommand(Intent intent, int flags, int startId) {
builder = builder.setVisibility(Notification.VISIBILITY_SECRET);
}

startForeground(SERVICE_ID, builder.getNotification());
if (Build.VERSION.SDK_INT >= VERSION_CODES.TIRAMISU) {
// https://developer.android.com/about/versions/14/changes/fgs-types-required
startForeground(SERVICE_ID, builder.build(),
ServiceInfo.FOREGROUND_SERVICE_TYPE_CONNECTED_DEVICE);
} else {
startForeground(SERVICE_ID, builder.build());
}

updateQuickSettingsTile();

Expand Down
6 changes: 3 additions & 3 deletions Android/gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ android.defaults.buildfeatures.buildconfig=true
android.nonTransitiveRClass=false
android.nonFinalResIds=false

ANDROID_COMPILE_SDK_VERSION=33
ANDROID_BUILD_TOOLS_VERSION=33.0.0
ANDROID_COMPILE_SDK_VERSION=34
ANDROID_BUILD_TOOLS_VERSION=34.0.0

ANDROID_MIN_SDK_VERSION=16
ANDROID_TARGET_SDK_VERSION=33
ANDROID_TARGET_SDK_VERSION=34
27 changes: 27 additions & 0 deletions Android/gradle/verification-metadata.xml
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,9 @@
</artifact>
</component>
<component group="androidx.arch.core" name="core-runtime" version="2.0.0">
<artifact name="core-runtime-2.0.0.aar">
<sha256 value="87e65fc767c712b437649c7cee2431ebb4bed6daef82e501d4125b3ed3f65f8e" origin="Generated by Gradle"/>
</artifact>
<artifact name="core-runtime-2.0.0.pom">
<sha256 value="e2007d41ddc69ee2a77fed7b5c1dc5a41e01122926ba59696aab7b18d2264411" origin="Generated by Gradle"/>
</artifact>
Expand Down Expand Up @@ -239,6 +242,9 @@
</artifact>
</component>
<component group="androidx.lifecycle" name="lifecycle-common" version="2.3.1">
<artifact name="lifecycle-common-2.3.1.jar">
<sha256 value="15848fb56db32f4c7cdc72b324003183d52a4884d6bf09be708ac7f587d139b5" origin="Generated by Gradle"/>
</artifact>
<artifact name="lifecycle-common-2.3.1.module">
<sha256 value="5fb7c8514d8c56cada5e29ef89dc0289e71942ab4cb0b2e6dca137b9dcb8fdd4" origin="Generated by Gradle"/>
</artifact>
Expand Down Expand Up @@ -281,6 +287,9 @@
</artifact>
</component>
<component group="androidx.lifecycle" name="lifecycle-runtime" version="2.3.1">
<artifact name="lifecycle-runtime-2.3.1.aar">
<sha256 value="dd294f4a689c71ff877fd41f3b67a3a62f7760d44ce420e6130f1fc3569d8f00" origin="Generated by Gradle"/>
</artifact>
<artifact name="lifecycle-runtime-2.3.1.module">
<sha256 value="2a7b90e5049b674b36bccfd68677b3a0b3178b3f7c2ef7ddf618d3895598c4ce" origin="Generated by Gradle"/>
</artifact>
Expand Down Expand Up @@ -1764,16 +1773,25 @@
</artifact>
</component>
<component group="junit" name="junit" version="4.13.1">
<artifact name="junit-4.13.1.jar">
<sha256 value="c30719db974d6452793fe191b3638a5777005485bae145924044530ffa5f6122" origin="Generated by Gradle"/>
</artifact>
<artifact name="junit-4.13.1.pom">
<sha256 value="c68defdedaaaeae1432e12a5302bf2bfa05057d8b5acc65aaa3f3d9853ff40d6" origin="Generated by Gradle"/>
</artifact>
</component>
<component group="net.bytebuddy" name="byte-buddy" version="1.7.9">
<artifact name="byte-buddy-1.7.9.jar">
<sha256 value="2ea2ada12b790d16ac7f6e6c065cb55cbcdb6ba519355f5958851159cad3b16a" origin="Generated by Gradle"/>
</artifact>
<artifact name="byte-buddy-1.7.9.pom">
<sha256 value="abf1ec22e85e9f99833f51c0342d116838e60dedb5b186421b5552aa39f9833b" origin="Generated by Gradle"/>
</artifact>
</component>
<component group="net.bytebuddy" name="byte-buddy-agent" version="1.7.9">
<artifact name="byte-buddy-agent-1.7.9.jar">
<sha256 value="ac1a993befb528c3271a83a9ad9c42d363d399e9deb26e0470e3c4962066c550" origin="Generated by Gradle"/>
</artifact>
<artifact name="byte-buddy-agent-1.7.9.pom">
<sha256 value="7df0a37b1bc03e393060f3d1395fdf7f35bb3608fe8ff425539e41c118cccbd1" origin="Generated by Gradle"/>
</artifact>
Expand Down Expand Up @@ -2120,6 +2138,9 @@
</artifact>
</component>
<component group="org.json" name="json" version="20180813">
<artifact name="json-20180813.jar">
<sha256 value="518080049ba83181914419d11a25d9bc9833a2d729b6a6e7469fa52851356da8" origin="Generated by Gradle"/>
</artifact>
<artifact name="json-20180813.pom">
<sha256 value="c7e660c50bf4ecda0fc81ab62b489db9171e207fa784ddcb48c6c85bb40b49f5" origin="Generated by Gradle"/>
</artifact>
Expand All @@ -2133,11 +2154,17 @@
</artifact>
</component>
<component group="org.mockito" name="mockito-core" version="2.13.0">
<artifact name="mockito-core-2.13.0.jar">
<sha256 value="92a746b37cf8c5730a5e7b35fd7d8cd72700089435ff92ee03ed8384d4eb3377" origin="Generated by Gradle"/>
</artifact>
<artifact name="mockito-core-2.13.0.pom">
<sha256 value="d6a107375f367d0198c505fe316102ee04f337275c17aad0240c992bb3ccd2f0" origin="Generated by Gradle"/>
</artifact>
</component>
<component group="org.objenesis" name="objenesis" version="2.6">
<artifact name="objenesis-2.6.jar">
<sha256 value="5e168368fbc250af3c79aa5fef0c3467a2d64e5a7bd74005f25d8399aeb0708d" origin="Generated by Gradle"/>
</artifact>
<artifact name="objenesis-2.6.pom">
<sha256 value="4c1307909dc62df1bd91f075503f8bdef5ae445e13353f1752af9448bea1d3f1" origin="Generated by Gradle"/>
</artifact>
Expand Down