summaryrefslogtreecommitdiffhomepage
path: root/android
diff options
context:
space:
mode:
authorJonatan Rhodin <jonatan.rhodin@mullvad.net>2024-03-19 16:36:16 +0100
committerJonatan Rhodin <jonatan.rhodin@mullvad.net>2024-03-20 13:52:49 +0100
commit1c8f1300fd1b2c512bbf2752a135e8f6acd346d9 (patch)
tree73e562c2a416e9b7fde71d96fa2cf41e0ca308f8 /android
parent4b4304f57a8236e349654f8841d09e6db1432dc2 (diff)
downloadmullvadvpn-1c8f1300fd1b2c512bbf2752a135e8f6acd346d9.tar.xz
mullvadvpn-1c8f1300fd1b2c512bbf2752a135e8f6acd346d9.zip
Prevent tapjacking attacks
Diffstat (limited to 'android')
-rw-r--r--android/app/src/main/kotlin/net/mullvad/mullvadvpn/ui/MainActivity.kt3
1 files changed, 3 insertions, 0 deletions
diff --git a/android/app/src/main/kotlin/net/mullvad/mullvadvpn/ui/MainActivity.kt b/android/app/src/main/kotlin/net/mullvad/mullvadvpn/ui/MainActivity.kt
index c7a9be2ff9..2bfe5d5d9d 100644
--- a/android/app/src/main/kotlin/net/mullvad/mullvadvpn/ui/MainActivity.kt
+++ b/android/app/src/main/kotlin/net/mullvad/mullvadvpn/ui/MainActivity.kt
@@ -65,6 +65,9 @@ class MainActivity : ComponentActivity() {
setContent { AppTheme { MullvadApp() } }
+ // This is to protect against tapjacking attacks
+ window.decorView.filterTouchesWhenObscured = true
+
// We use lifecycleScope here to get less start service in background exceptions
// Se this article for more information:
// https://medium.com/@lepicekmichal/android-background-service-without-hiccup-501e4479110f