From cdf6094579c1d4b773f3b46abe3a0c33a32826b3 Mon Sep 17 00:00:00 2001 From: Brian Hanson Date: Thu, 22 Jun 2023 13:34:13 -0500 Subject: [PATCH] - Renamed project namespace to hanson.xyz.vpnhotspotmod - Added BroadcastReceiver to recive intents to start wifi and bluetooth tether options via tasker - Modified TetherService to run sticky - Modified TetherManager to 'monitor' all new interfaces as soon as they are created --- build.gradle.kts | 2 +- gradlew | 0 gradlew.bat | 184 +++++++++--------- mobile/build.gradle.kts | 4 +- mobile/google-services.json | 2 +- .../1.json | 0 .../2.json | 0 .../xyz/vpnhotspotmod}/room/MigrationTest.kt | 2 +- .../xyz/vpnhotspotmod}/util/UpdateChecker.kt | 6 +- .../xyz/vpnhotspotmod}/util/UpdateChecker.kt | 6 +- mobile/src/main/AndroidManifest.xml | 11 +- .../xyz/vpnhotspotmod}/AlertDialogFragment.kt | 2 +- .../xyz/vpnhotspotmod}/App.kt | 14 +- .../xyz/vpnhotspotmod}/BootReceiver.kt | 4 +- .../xyz/vpnhotspotmod}/EBegFragment.kt | 10 +- .../IpNeighbourMonitoringService.kt | 6 +- .../vpnhotspotmod}/LocalOnlyHotspotService.kt | 32 +-- .../xyz/vpnhotspotmod}/MainActivity.kt | 24 +-- .../xyz/vpnhotspotmod/MyBroadcastReceiver.kt | 53 +++++ .../xyz/vpnhotspotmod}/RepeaterService.kt | 44 ++--- .../xyz/vpnhotspotmod}/RoutingManager.kt | 12 +- .../xyz/vpnhotspotmod}/ServiceNotification.kt | 4 +- .../SettingsPreferenceFragment.kt | 34 ++-- .../xyz/vpnhotspotmod}/TetheringService.kt | 23 ++- .../xyz/vpnhotspotmod}/client/Client.kt | 20 +- .../vpnhotspotmod}/client/ClientViewModel.kt | 26 +-- .../vpnhotspotmod}/client/ClientsFragment.kt | 34 ++-- .../xyz/vpnhotspotmod}/client/MacLookup.kt | 12 +- .../manage/BluetoothTethering.kt | 12 +- .../xyz/vpnhotspotmod}/manage/Data.kt | 2 +- .../vpnhotspotmod}/manage/InterfaceManager.kt | 15 +- .../IpNeighbourMonitoringTileService.kt | 10 +- .../manage/LocalOnlyHotspotManager.kt | 16 +- .../manage/LocalOnlyHotspotTileService.kt | 8 +- .../xyz/vpnhotspotmod}/manage/ManageBar.kt | 8 +- .../xyz/vpnhotspotmod}/manage/Manager.kt | 8 +- .../vpnhotspotmod}/manage/RepeaterManager.kt | 32 +-- .../manage/RepeaterTileService.kt | 12 +- .../vpnhotspotmod}/manage/TetherManager.kt | 24 +-- .../manage/TetheringFragment.kt | 34 ++-- .../manage/TetheringTileService.kt | 18 +- .../xyz/vpnhotspotmod}/net/DhcpWorkaround.kt | 12 +- .../net/InetAddressComparator.kt | 2 +- .../xyz/vpnhotspotmod}/net/IpNeighbour.kt | 8 +- .../vpnhotspotmod}/net/MacAddressCompat.kt | 2 +- .../xyz/vpnhotspotmod}/net/Routing.kt | 28 +-- .../net/TetherOffloadManager.kt | 6 +- .../xyz/vpnhotspotmod}/net/TetherType.kt | 10 +- .../vpnhotspotmod}/net/TetheringManager.kt | 41 +++- .../net/monitor/DefaultNetworkMonitor.kt | 6 +- .../net/monitor/FallbackUpstreamMonitor.kt | 4 +- .../net/monitor/InterfaceMonitor.kt | 8 +- .../vpnhotspotmod}/net/monitor/IpMonitor.kt | 18 +- .../net/monitor/IpNeighbourMonitor.kt | 6 +- .../net/monitor/TetherTimeoutMonitor.kt | 10 +- .../net/monitor/TrafficRecorder.kt | 18 +- .../net/monitor/UpstreamMonitor.kt | 4 +- .../vpnhotspotmod}/net/monitor/VpnMonitor.kt | 6 +- .../net/wifi/P2pSupplicantConfiguration.kt | 10 +- .../net/wifi/SoftApCapability.kt | 6 +- .../net/wifi/SoftApConfigurationCompat.kt | 14 +- .../xyz/vpnhotspotmod}/net/wifi/SoftApInfo.kt | 6 +- .../vpnhotspotmod}/net/wifi/VendorElements.kt | 2 +- .../net/wifi/WifiApDialogFragment.kt | 24 +-- .../vpnhotspotmod}/net/wifi/WifiApManager.kt | 6 +- .../xyz/vpnhotspotmod}/net/wifi/WifiClient.kt | 4 +- .../vpnhotspotmod}/net/wifi/WifiDoubleLock.kt | 6 +- .../net/wifi/WifiP2pManagerHelper.kt | 10 +- .../vpnhotspotmod}/net/wifi/WifiSsidCompat.kt | 2 +- ...CompleteNetworkPreferenceDialogFragment.kt | 12 +- .../preference/SharedPreferenceDataStore.kt | 2 +- .../preference/SummaryFallbackProvider.kt | 2 +- .../preference/UpstreamsPreference.kt | 14 +- .../xyz/vpnhotspotmod}/room/AppDatabase.kt | 4 +- .../xyz/vpnhotspotmod}/room/ClientRecord.kt | 4 +- .../xyz/vpnhotspotmod}/room/Converters.kt | 6 +- .../xyz/vpnhotspotmod}/room/TrafficRecord.kt | 2 +- .../root/LocalOnlyHotspotCallbacks.kt | 2 +- .../xyz/vpnhotspotmod}/root/MiscCommands.kt | 12 +- .../vpnhotspotmod}/root/RepeaterCommands.kt | 14 +- .../xyz/vpnhotspotmod}/root/RootManager.kt | 8 +- .../vpnhotspotmod}/root/RoutingCommands.kt | 4 +- .../xyz/vpnhotspotmod}/root/WifiApCommands.kt | 12 +- .../xyz/vpnhotspotmod}/util/AppUpdate.kt | 2 +- .../xyz/vpnhotspotmod}/util/ConstantLookup.kt | 6 +- .../vpnhotspotmod}/util/CustomTabsUrlSpan.kt | 2 +- .../vpnhotspotmod}/util/DeviceStorageApp.kt | 2 +- .../xyz/vpnhotspotmod}/util/Events.kt | 2 +- .../util/KillableTileService.kt | 4 +- .../xyz/vpnhotspotmod}/util/QRCodeDialog.kt | 4 +- .../xyz/vpnhotspotmod}/util/RangeInput.kt | 2 +- .../xyz/vpnhotspotmod}/util/RootSession.kt | 6 +- .../util/ServiceForegroundConnector.kt | 2 +- .../xyz/vpnhotspotmod}/util/Services.kt | 2 +- .../xyz/vpnhotspotmod}/util/UnblockCentral.kt | 2 +- .../xyz/vpnhotspotmod}/util/Utils.kt | 8 +- .../widget/AlwaysAutoCompleteEditText.kt | 2 +- .../widget/AutoCollapseTextView.kt | 2 +- .../xyz/vpnhotspotmod}/widget/LinkTextView.kt | 2 +- .../vpnhotspotmod}/widget/SmartSnackbar.kt | 6 +- .../res/drawable/ic_launcher_background.xml | 0 .../res/drawable/ic_launcher_foreground.xml | 0 mobile/src/main/res/layout/activity_main.xml | 2 +- .../src/main/res/layout/listitem_client.xml | 10 +- .../main/res/layout/listitem_interface.xml | 4 +- .../src/main/res/layout/listitem_manage.xml | 2 +- .../src/main/res/layout/listitem_repeater.xml | 6 +- ...reference_widget_edittext_autocomplete.xml | 2 +- mobile/src/main/res/values/strings.xml | 2 +- mobile/src/main/res/xml/pref_settings.xml | 2 +- 110 files changed, 661 insertions(+), 572 deletions(-) mode change 100755 => 100644 gradlew rename mobile/schemas/{be.mygod.vpnhotspot.room.AppDatabase => hanson.xyz.vpnhotspotmod.room.AppDatabase}/1.json (100%) rename mobile/schemas/{be.mygod.vpnhotspot.room.AppDatabase => hanson.xyz.vpnhotspotmod.room.AppDatabase}/2.json (100%) rename mobile/src/androidTest/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/room/MigrationTest.kt (95%) rename mobile/src/freedom/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/util/UpdateChecker.kt (97%) rename mobile/src/google/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/util/UpdateChecker.kt (96%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/AlertDialogFragment.kt (98%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/App.kt (94%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/BootReceiver.kt (98%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/EBegFragment.kt (96%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/IpNeighbourMonitoringService.kt (86%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/LocalOnlyHotspotService.kt (91%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/MainActivity.kt (89%) create mode 100644 mobile/src/main/java/hanson/xyz/vpnhotspotmod/MyBroadcastReceiver.kt rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/RepeaterService.kt (94%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/RoutingManager.kt (93%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/ServiceNotification.kt (98%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/SettingsPreferenceFragment.kt (87%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/TetheringService.kt (91%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/client/Client.kt (85%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/client/ClientViewModel.kt (86%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/client/ClientsFragment.kt (93%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/client/MacLookup.kt (95%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/manage/BluetoothTethering.kt (94%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/manage/Data.kt (86%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/manage/InterfaceManager.kt (84%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/manage/IpNeighbourMonitoringTileService.kt (82%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/manage/LocalOnlyHotspotManager.kt (85%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/manage/LocalOnlyHotspotTileService.kt (91%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/manage/ManageBar.kt (87%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/manage/Manager.kt (89%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/manage/RepeaterManager.kt (93%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/manage/RepeaterTileService.kt (90%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/manage/TetherManager.kt (96%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/manage/TetheringFragment.kt (94%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/manage/TetheringTileService.kt (95%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/net/DhcpWorkaround.kt (87%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/net/InetAddressComparator.kt (91%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/net/IpNeighbour.kt (97%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/net/MacAddressCompat.kt (96%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/net/Routing.kt (96%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/net/TetherOffloadManager.kt (85%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/net/TetherType.kt (96%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/net/TetheringManager.kt (95%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/net/monitor/DefaultNetworkMonitor.kt (94%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/net/monitor/FallbackUpstreamMonitor.kt (94%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/net/monitor/InterfaceMonitor.kt (94%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/net/monitor/IpMonitor.kt (94%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/net/monitor/IpNeighbourMonitor.kt (95%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/net/monitor/TetherTimeoutMonitor.kt (93%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/net/monitor/TrafficRecorder.kt (93%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/net/monitor/UpstreamMonitor.kt (96%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/net/monitor/VpnMonitor.kt (94%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/net/wifi/P2pSupplicantConfiguration.kt (96%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/net/wifi/SoftApCapability.kt (93%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/net/wifi/SoftApConfigurationCompat.kt (98%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/net/wifi/SoftApInfo.kt (92%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/net/wifi/VendorElements.kt (96%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/net/wifi/WifiApDialogFragment.kt (97%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/net/wifi/WifiApManager.kt (99%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/net/wifi/WifiClient.kt (89%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/net/wifi/WifiDoubleLock.kt (96%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/net/wifi/WifiP2pManagerHelper.kt (96%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/net/wifi/WifiSsidCompat.kt (98%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/preference/AutoCompleteNetworkPreferenceDialogFragment.kt (90%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/preference/SharedPreferenceDataStore.kt (96%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/preference/SummaryFallbackProvider.kt (90%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/preference/UpstreamsPreference.kt (88%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/room/AppDatabase.kt (92%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/room/ClientRecord.kt (93%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/room/Converters.kt (88%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/room/TrafficRecord.kt (98%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/root/LocalOnlyHotspotCallbacks.kt (94%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/root/MiscCommands.kt (96%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/root/RepeaterCommands.kt (88%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/root/RootManager.kt (91%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/root/RoutingCommands.kt (96%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/root/WifiApCommands.kt (97%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/util/AppUpdate.kt (90%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/util/ConstantLookup.kt (94%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/util/CustomTabsUrlSpan.kt (83%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/util/DeviceStorageApp.kt (92%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/util/Events.kt (96%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/util/KillableTileService.kt (92%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/util/QRCodeDialog.kt (96%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/util/RangeInput.kt (97%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/util/RootSession.kt (95%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/util/ServiceForegroundConnector.kt (96%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/util/Services.kt (96%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/util/UnblockCentral.kt (97%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/util/Utils.kt (98%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/widget/AlwaysAutoCompleteEditText.kt (95%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/widget/AutoCollapseTextView.kt (93%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/widget/LinkTextView.kt (94%) rename mobile/src/main/java/{be/mygod/vpnhotspot => hanson/xyz/vpnhotspotmod}/widget/SmartSnackbar.kt (93%) mode change 100755 => 100644 mobile/src/main/res/drawable/ic_launcher_background.xml mode change 100755 => 100644 mobile/src/main/res/drawable/ic_launcher_foreground.xml diff --git a/build.gradle.kts b/build.gradle.kts index c764ccd6..93041244 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -1,5 +1,5 @@ plugins { - id("com.android.application") version "8.2.0-alpha07" apply false + id("com.android.application") version "8.0.2" apply false id("com.github.ben-manes.versions") version "0.47.0" id("org.jetbrains.kotlin.android") version "1.8.21" apply false } diff --git a/gradlew b/gradlew old mode 100755 new mode 100644 diff --git a/gradlew.bat b/gradlew.bat index 6689b85b..93e3f59f 100644 --- a/gradlew.bat +++ b/gradlew.bat @@ -1,92 +1,92 @@ -@rem -@rem Copyright 2015 the original author or authors. -@rem -@rem Licensed under the Apache License, Version 2.0 (the "License"); -@rem you may not use this file except in compliance with the License. -@rem You may obtain a copy of the License at -@rem -@rem https://www.apache.org/licenses/LICENSE-2.0 -@rem -@rem Unless required by applicable law or agreed to in writing, software -@rem distributed under the License is distributed on an "AS IS" BASIS, -@rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -@rem See the License for the specific language governing permissions and -@rem limitations under the License. -@rem - -@if "%DEBUG%"=="" @echo off -@rem ########################################################################## -@rem -@rem Gradle startup script for Windows -@rem -@rem ########################################################################## - -@rem Set local scope for the variables with windows NT shell -if "%OS%"=="Windows_NT" setlocal - -set DIRNAME=%~dp0 -if "%DIRNAME%"=="" set DIRNAME=. -@rem This is normally unused -set APP_BASE_NAME=%~n0 -set APP_HOME=%DIRNAME% - -@rem Resolve any "." and ".." in APP_HOME to make it shorter. -for %%i in ("%APP_HOME%") do set APP_HOME=%%~fi - -@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. -set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m" - -@rem Find java.exe -if defined JAVA_HOME goto findJavaFromJavaHome - -set JAVA_EXE=java.exe -%JAVA_EXE% -version >NUL 2>&1 -if %ERRORLEVEL% equ 0 goto execute - -echo. -echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. -echo. -echo Please set the JAVA_HOME variable in your environment to match the -echo location of your Java installation. - -goto fail - -:findJavaFromJavaHome -set JAVA_HOME=%JAVA_HOME:"=% -set JAVA_EXE=%JAVA_HOME%/bin/java.exe - -if exist "%JAVA_EXE%" goto execute - -echo. -echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% -echo. -echo Please set the JAVA_HOME variable in your environment to match the -echo location of your Java installation. - -goto fail - -:execute -@rem Setup the command line - -set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar - - -@rem Execute Gradle -"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %* - -:end -@rem End local scope for the variables with windows NT shell -if %ERRORLEVEL% equ 0 goto mainEnd - -:fail -rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of -rem the _cmd.exe /c_ return code! -set EXIT_CODE=%ERRORLEVEL% -if %EXIT_CODE% equ 0 set EXIT_CODE=1 -if not ""=="%GRADLE_EXIT_CONSOLE%" exit %EXIT_CODE% -exit /b %EXIT_CODE% - -:mainEnd -if "%OS%"=="Windows_NT" endlocal - -:omega +@rem +@rem Copyright 2015 the original author or authors. +@rem +@rem Licensed under the Apache License, Version 2.0 (the "License"); +@rem you may not use this file except in compliance with the License. +@rem You may obtain a copy of the License at +@rem +@rem https://www.apache.org/licenses/LICENSE-2.0 +@rem +@rem Unless required by applicable law or agreed to in writing, software +@rem distributed under the License is distributed on an "AS IS" BASIS, +@rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +@rem See the License for the specific language governing permissions and +@rem limitations under the License. +@rem + +@if "%DEBUG%"=="" @echo off +@rem ########################################################################## +@rem +@rem Gradle startup script for Windows +@rem +@rem ########################################################################## + +@rem Set local scope for the variables with windows NT shell +if "%OS%"=="Windows_NT" setlocal + +set DIRNAME=%~dp0 +if "%DIRNAME%"=="" set DIRNAME=. +@rem This is normally unused +set APP_BASE_NAME=%~n0 +set APP_HOME=%DIRNAME% + +@rem Resolve any "." and ".." in APP_HOME to make it shorter. +for %%i in ("%APP_HOME%") do set APP_HOME=%%~fi + +@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. +set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m" + +@rem Find java.exe +if defined JAVA_HOME goto findJavaFromJavaHome + +set JAVA_EXE=java.exe +%JAVA_EXE% -version >NUL 2>&1 +if %ERRORLEVEL% equ 0 goto execute + +echo. +echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. +echo. +echo Please set the JAVA_HOME variable in your environment to match the +echo location of your Java installation. + +goto fail + +:findJavaFromJavaHome +set JAVA_HOME=%JAVA_HOME:"=% +set JAVA_EXE=%JAVA_HOME%/bin/java.exe + +if exist "%JAVA_EXE%" goto execute + +echo. +echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% +echo. +echo Please set the JAVA_HOME variable in your environment to match the +echo location of your Java installation. + +goto fail + +:execute +@rem Setup the command line + +set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar + + +@rem Execute Gradle +"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %* + +:end +@rem End local scope for the variables with windows NT shell +if %ERRORLEVEL% equ 0 goto mainEnd + +:fail +rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of +rem the _cmd.exe /c_ return code! +set EXIT_CODE=%ERRORLEVEL% +if %EXIT_CODE% equ 0 set EXIT_CODE=1 +if not ""=="%GRADLE_EXIT_CONSOLE%" exit %EXIT_CODE% +exit /b %EXIT_CODE% + +:mainEnd +if "%OS%"=="Windows_NT" endlocal + +:omega diff --git a/mobile/build.gradle.kts b/mobile/build.gradle.kts index e55b9299..ba564112 100644 --- a/mobile/build.gradle.kts +++ b/mobile/build.gradle.kts @@ -9,7 +9,7 @@ plugins { } android { - namespace = "be.mygod.vpnhotspot" + namespace = "hanson.xyz.vpnhotspotmod" val javaVersion = 11 buildToolsVersion = "34.0.0" @@ -24,7 +24,6 @@ android { } compileSdk = 34 defaultConfig { - applicationId = "be.mygod.vpnhotspot" minSdk = 28 targetSdk = 34 resourceConfigurations.addAll(arrayOf("it", "pt-rBR", "ru", "zh-rCN", "zh-rTW")) @@ -36,6 +35,7 @@ android { put("room.incremental", "true") put("room.schemaLocation", "$projectDir/schemas") } + applicationId = "hanson.xyz.vpnhotspotmod" } buildFeatures { buildConfig = true diff --git a/mobile/google-services.json b/mobile/google-services.json index 3d515800..557d78b4 100644 --- a/mobile/google-services.json +++ b/mobile/google-services.json @@ -10,7 +10,7 @@ "client_info": { "mobilesdk_app_id": "1:13108846109:android:63120dcb2e900ed0", "android_client_info": { - "package_name": "be.mygod.vpnhotspot" + "package_name": "hanson.xyz.vpnhotspotmod" } }, "oauth_client": [ diff --git a/mobile/schemas/be.mygod.vpnhotspot.room.AppDatabase/1.json b/mobile/schemas/hanson.xyz.vpnhotspotmod.room.AppDatabase/1.json similarity index 100% rename from mobile/schemas/be.mygod.vpnhotspot.room.AppDatabase/1.json rename to mobile/schemas/hanson.xyz.vpnhotspotmod.room.AppDatabase/1.json diff --git a/mobile/schemas/be.mygod.vpnhotspot.room.AppDatabase/2.json b/mobile/schemas/hanson.xyz.vpnhotspotmod.room.AppDatabase/2.json similarity index 100% rename from mobile/schemas/be.mygod.vpnhotspot.room.AppDatabase/2.json rename to mobile/schemas/hanson.xyz.vpnhotspotmod.room.AppDatabase/2.json diff --git a/mobile/src/androidTest/java/be/mygod/vpnhotspot/room/MigrationTest.kt b/mobile/src/androidTest/java/hanson/xyz/vpnhotspotmod/room/MigrationTest.kt similarity index 95% rename from mobile/src/androidTest/java/be/mygod/vpnhotspot/room/MigrationTest.kt rename to mobile/src/androidTest/java/hanson/xyz/vpnhotspotmod/room/MigrationTest.kt index b7c5a154..36e021fa 100644 --- a/mobile/src/androidTest/java/be/mygod/vpnhotspot/room/MigrationTest.kt +++ b/mobile/src/androidTest/java/hanson/xyz/vpnhotspotmod/room/MigrationTest.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.room +package hanson.xyz.vpnhotspotmod.room import androidx.room.testing.MigrationTestHelper import androidx.sqlite.db.framework.FrameworkSQLiteOpenHelperFactory diff --git a/mobile/src/freedom/java/be/mygod/vpnhotspot/util/UpdateChecker.kt b/mobile/src/freedom/java/hanson/xyz/vpnhotspotmod/util/UpdateChecker.kt similarity index 97% rename from mobile/src/freedom/java/be/mygod/vpnhotspot/util/UpdateChecker.kt rename to mobile/src/freedom/java/hanson/xyz/vpnhotspotmod/util/UpdateChecker.kt index 69fe6576..04b8ff5e 100644 --- a/mobile/src/freedom/java/be/mygod/vpnhotspot/util/UpdateChecker.kt +++ b/mobile/src/freedom/java/hanson/xyz/vpnhotspotmod/util/UpdateChecker.kt @@ -1,10 +1,10 @@ -package be.mygod.vpnhotspot.util +package hanson.xyz.vpnhotspotmod.util import android.app.Activity import android.net.Uri import androidx.core.content.edit -import be.mygod.vpnhotspot.App.Companion.app -import be.mygod.vpnhotspot.BuildConfig +import hanson.xyz.vpnhotspotmod.App.Companion.app +import hanson.xyz.vpnhotspotmod.BuildConfig import kotlinx.coroutines.currentCoroutineContext import kotlinx.coroutines.delay import kotlinx.coroutines.ensureActive diff --git a/mobile/src/google/java/be/mygod/vpnhotspot/util/UpdateChecker.kt b/mobile/src/google/java/hanson/xyz/vpnhotspotmod/util/UpdateChecker.kt similarity index 96% rename from mobile/src/google/java/be/mygod/vpnhotspot/util/UpdateChecker.kt rename to mobile/src/google/java/hanson/xyz/vpnhotspotmod/util/UpdateChecker.kt index bf63a8ef..2c276f7a 100644 --- a/mobile/src/google/java/be/mygod/vpnhotspot/util/UpdateChecker.kt +++ b/mobile/src/google/java/hanson/xyz/vpnhotspotmod/util/UpdateChecker.kt @@ -1,8 +1,8 @@ -package be.mygod.vpnhotspot.util +package hanson.xyz.vpnhotspotmod.util import android.app.Activity import android.net.Uri -import be.mygod.vpnhotspot.App.Companion.app +import hanson.xyz.vpnhotspotmod.App.Companion.app import com.google.android.play.core.appupdate.AppUpdateManagerFactory import com.google.android.play.core.install.InstallException import com.google.android.play.core.install.model.InstallErrorCode @@ -23,7 +23,7 @@ object UpdateChecker { } catch (e: Exception) { Timber.w(e) app.customTabsIntent.launchUrl(activity, - Uri.parse("https://play.google.com/store/apps/details?id=be.mygod.vpnhotspot")) + Uri.parse("https://play.google.com/store/apps/details?id=hanson.xyz.vpnhotspotmod")) } } private class UpdateDownloading(private val update: AppUpdateResult.InProgress) : AppUpdate { diff --git a/mobile/src/main/AndroidManifest.xml b/mobile/src/main/AndroidManifest.xml index 3a2ef675..3889d7c6 100644 --- a/mobile/src/main/AndroidManifest.xml +++ b/mobile/src/main/AndroidManifest.xml @@ -214,9 +214,18 @@ + + + + + + + + + get() = parent.ifaceLookup override val icon get() = R.drawable.ic_action_perm_scan_wifi diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/manage/LocalOnlyHotspotTileService.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/manage/LocalOnlyHotspotTileService.kt similarity index 91% rename from mobile/src/main/java/be/mygod/vpnhotspot/manage/LocalOnlyHotspotTileService.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/manage/LocalOnlyHotspotTileService.kt index 2a7b7c3e..e4d184d7 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/manage/LocalOnlyHotspotTileService.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/manage/LocalOnlyHotspotTileService.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.manage +package hanson.xyz.vpnhotspotmod.manage import android.content.ComponentName import android.content.Context @@ -6,9 +6,9 @@ import android.content.Intent import android.graphics.drawable.Icon import android.os.IBinder import android.service.quicksettings.Tile -import be.mygod.vpnhotspot.LocalOnlyHotspotService -import be.mygod.vpnhotspot.R -import be.mygod.vpnhotspot.util.stopAndUnbind +import hanson.xyz.vpnhotspotmod.LocalOnlyHotspotService +import hanson.xyz.vpnhotspotmod.R +import hanson.xyz.vpnhotspotmod.util.stopAndUnbind class LocalOnlyHotspotTileService : IpNeighbourMonitoringTileService() { private val tile by lazy { Icon.createWithResource(application, R.drawable.ic_action_perm_scan_wifi) } diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/manage/ManageBar.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/manage/ManageBar.kt similarity index 87% rename from mobile/src/main/java/be/mygod/vpnhotspot/manage/ManageBar.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/manage/ManageBar.kt index 02c8ed62..e75ec110 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/manage/ManageBar.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/manage/ManageBar.kt @@ -1,13 +1,13 @@ -package be.mygod.vpnhotspot.manage +package hanson.xyz.vpnhotspotmod.manage import android.content.Context import android.content.Intent import android.view.View import androidx.databinding.BaseObservable import androidx.recyclerview.widget.RecyclerView -import be.mygod.vpnhotspot.App.Companion.app -import be.mygod.vpnhotspot.databinding.ListitemManageBinding -import be.mygod.vpnhotspot.net.TetherOffloadManager +import hanson.xyz.vpnhotspotmod.App.Companion.app +import hanson.xyz.vpnhotspotmod.databinding.ListitemManageBinding +import hanson.xyz.vpnhotspotmod.net.TetherOffloadManager object ManageBar : Manager() { private const val TAG = "ManageBar" diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/manage/Manager.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/manage/Manager.kt similarity index 89% rename from mobile/src/main/java/be/mygod/vpnhotspot/manage/Manager.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/manage/Manager.kt index baa163ba..8734e347 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/manage/Manager.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/manage/Manager.kt @@ -1,13 +1,13 @@ -package be.mygod.vpnhotspot.manage +package hanson.xyz.vpnhotspotmod.manage import android.annotation.SuppressLint import android.view.LayoutInflater import android.view.ViewGroup import androidx.recyclerview.widget.DiffUtil import androidx.recyclerview.widget.RecyclerView -import be.mygod.vpnhotspot.databinding.ListitemInterfaceBinding -import be.mygod.vpnhotspot.databinding.ListitemManageBinding -import be.mygod.vpnhotspot.databinding.ListitemRepeaterBinding +import hanson.xyz.vpnhotspotmod.databinding.ListitemInterfaceBinding +import hanson.xyz.vpnhotspotmod.databinding.ListitemManageBinding +import hanson.xyz.vpnhotspotmod.databinding.ListitemRepeaterBinding abstract class Manager { companion object DiffCallback : DiffUtil.ItemCallback() { diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/manage/RepeaterManager.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/manage/RepeaterManager.kt similarity index 93% rename from mobile/src/main/java/be/mygod/vpnhotspot/manage/RepeaterManager.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/manage/RepeaterManager.kt index d0aabcba..5b8596c5 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/manage/RepeaterManager.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/manage/RepeaterManager.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.manage +package hanson.xyz.vpnhotspotmod.manage import android.Manifest import android.content.ComponentName @@ -24,21 +24,21 @@ import androidx.lifecycle.ViewModel import androidx.lifecycle.lifecycleScope import androidx.lifecycle.withStarted import androidx.recyclerview.widget.RecyclerView -import be.mygod.vpnhotspot.AlertDialogFragment -import be.mygod.vpnhotspot.BR -import be.mygod.vpnhotspot.Empty -import be.mygod.vpnhotspot.R -import be.mygod.vpnhotspot.RepeaterService -import be.mygod.vpnhotspot.databinding.ListitemRepeaterBinding -import be.mygod.vpnhotspot.net.wifi.P2pSupplicantConfiguration -import be.mygod.vpnhotspot.net.wifi.SoftApConfigurationCompat -import be.mygod.vpnhotspot.net.wifi.WifiApDialogFragment -import be.mygod.vpnhotspot.net.wifi.WifiApManager -import be.mygod.vpnhotspot.net.wifi.WifiSsidCompat -import be.mygod.vpnhotspot.util.ServiceForegroundConnector -import be.mygod.vpnhotspot.util.formatAddresses -import be.mygod.vpnhotspot.util.showAllowingStateLoss -import be.mygod.vpnhotspot.widget.SmartSnackbar +import hanson.xyz.vpnhotspotmod.AlertDialogFragment +import hanson.xyz.vpnhotspotmod.BR +import hanson.xyz.vpnhotspotmod.Empty +import hanson.xyz.vpnhotspotmod.R +import hanson.xyz.vpnhotspotmod.RepeaterService +import hanson.xyz.vpnhotspotmod.databinding.ListitemRepeaterBinding +import hanson.xyz.vpnhotspotmod.net.wifi.P2pSupplicantConfiguration +import hanson.xyz.vpnhotspotmod.net.wifi.SoftApConfigurationCompat +import hanson.xyz.vpnhotspotmod.net.wifi.WifiApDialogFragment +import hanson.xyz.vpnhotspotmod.net.wifi.WifiApManager +import hanson.xyz.vpnhotspotmod.net.wifi.WifiSsidCompat +import hanson.xyz.vpnhotspotmod.util.ServiceForegroundConnector +import hanson.xyz.vpnhotspotmod.util.formatAddresses +import hanson.xyz.vpnhotspotmod.util.showAllowingStateLoss +import hanson.xyz.vpnhotspotmod.widget.SmartSnackbar import kotlinx.coroutines.CancellationException import kotlinx.coroutines.Dispatchers import kotlinx.coroutines.GlobalScope diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/manage/RepeaterTileService.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/manage/RepeaterTileService.kt similarity index 90% rename from mobile/src/main/java/be/mygod/vpnhotspot/manage/RepeaterTileService.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/manage/RepeaterTileService.kt index 1b394ac4..d1552122 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/manage/RepeaterTileService.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/manage/RepeaterTileService.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.manage +package hanson.xyz.vpnhotspotmod.manage import android.content.ComponentName import android.content.Context @@ -7,11 +7,11 @@ import android.graphics.drawable.Icon import android.net.wifi.p2p.WifiP2pGroup import android.os.IBinder import android.service.quicksettings.Tile -import be.mygod.vpnhotspot.R -import be.mygod.vpnhotspot.RepeaterService -import be.mygod.vpnhotspot.util.KillableTileService -import be.mygod.vpnhotspot.util.Services -import be.mygod.vpnhotspot.util.stopAndUnbind +import hanson.xyz.vpnhotspotmod.R +import hanson.xyz.vpnhotspotmod.RepeaterService +import hanson.xyz.vpnhotspotmod.util.KillableTileService +import hanson.xyz.vpnhotspotmod.util.Services +import hanson.xyz.vpnhotspotmod.util.stopAndUnbind class RepeaterTileService : KillableTileService() { private val tile by lazy { Icon.createWithResource(application, R.drawable.ic_action_settings_input_antenna) } diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/manage/TetherManager.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/manage/TetherManager.kt similarity index 96% rename from mobile/src/main/java/be/mygod/vpnhotspot/manage/TetherManager.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/manage/TetherManager.kt index 10308788..e20e6004 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/manage/TetherManager.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/manage/TetherManager.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.manage +package hanson.xyz.vpnhotspotmod.manage import android.Manifest import android.annotation.TargetApi @@ -19,16 +19,16 @@ import androidx.core.view.updatePaddingRelative import androidx.lifecycle.DefaultLifecycleObserver import androidx.lifecycle.LifecycleOwner import androidx.recyclerview.widget.RecyclerView -import be.mygod.vpnhotspot.App.Companion.app -import be.mygod.vpnhotspot.MainActivity -import be.mygod.vpnhotspot.R -import be.mygod.vpnhotspot.databinding.ListitemInterfaceBinding -import be.mygod.vpnhotspot.net.TetherType -import be.mygod.vpnhotspot.net.TetheringManager -import be.mygod.vpnhotspot.net.wifi.* -import be.mygod.vpnhotspot.root.WifiApCommands -import be.mygod.vpnhotspot.util.* -import be.mygod.vpnhotspot.widget.SmartSnackbar +import hanson.xyz.vpnhotspotmod.App.Companion.app +import hanson.xyz.vpnhotspotmod.MainActivity +import hanson.xyz.vpnhotspotmod.R +import hanson.xyz.vpnhotspotmod.databinding.ListitemInterfaceBinding +import hanson.xyz.vpnhotspotmod.net.TetherType +import hanson.xyz.vpnhotspotmod.net.TetheringManager +import hanson.xyz.vpnhotspotmod.net.wifi.* +import hanson.xyz.vpnhotspotmod.root.WifiApCommands +import hanson.xyz.vpnhotspotmod.util.* +import hanson.xyz.vpnhotspotmod.widget.SmartSnackbar import kotlinx.coroutines.Dispatchers import kotlinx.coroutines.GlobalScope import kotlinx.coroutines.launch @@ -78,7 +78,7 @@ sealed class TetherManager(protected val parent: TetheringFragment) : Manager(), /** * A convenient class to delegate stuff to BaseObservable. */ - inner class Data : be.mygod.vpnhotspot.manage.Data() { + inner class Data : hanson.xyz.vpnhotspotmod.manage.Data() { override val icon get() = tetherType.icon override val title get() = this@TetherManager.title override val text get() = this@TetherManager.text diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/manage/TetheringFragment.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/manage/TetheringFragment.kt similarity index 94% rename from mobile/src/main/java/be/mygod/vpnhotspot/manage/TetheringFragment.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/manage/TetheringFragment.kt index 9d2c1019..c1f5a891 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/manage/TetheringFragment.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/manage/TetheringFragment.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.manage +package hanson.xyz.vpnhotspotmod.manage import android.annotation.TargetApi import android.bluetooth.BluetoothManager @@ -21,22 +21,22 @@ import androidx.recyclerview.widget.DefaultItemAnimator import androidx.recyclerview.widget.LinearLayoutManager import androidx.recyclerview.widget.ListAdapter import androidx.recyclerview.widget.RecyclerView -import be.mygod.vpnhotspot.* -import be.mygod.vpnhotspot.App.Companion.app -import be.mygod.vpnhotspot.databinding.FragmentTetheringBinding -import be.mygod.vpnhotspot.net.TetherType -import be.mygod.vpnhotspot.net.TetheringManager -import be.mygod.vpnhotspot.net.TetheringManager.localOnlyTetheredIfaces -import be.mygod.vpnhotspot.net.TetheringManager.tetheredIfaces -import be.mygod.vpnhotspot.net.monitor.TetherTimeoutMonitor -import be.mygod.vpnhotspot.net.wifi.SoftApConfigurationCompat -import be.mygod.vpnhotspot.net.wifi.SoftApConfigurationCompat.Companion.toCompat -import be.mygod.vpnhotspot.net.wifi.WifiApDialogFragment -import be.mygod.vpnhotspot.net.wifi.WifiApManager -import be.mygod.vpnhotspot.root.RootManager -import be.mygod.vpnhotspot.root.WifiApCommands -import be.mygod.vpnhotspot.util.* -import be.mygod.vpnhotspot.widget.SmartSnackbar +import hanson.xyz.vpnhotspotmod.* +import hanson.xyz.vpnhotspotmod.App.Companion.app +import hanson.xyz.vpnhotspotmod.databinding.FragmentTetheringBinding +import hanson.xyz.vpnhotspotmod.net.TetherType +import hanson.xyz.vpnhotspotmod.net.TetheringManager +import hanson.xyz.vpnhotspotmod.net.TetheringManager.localOnlyTetheredIfaces +import hanson.xyz.vpnhotspotmod.net.TetheringManager.tetheredIfaces +import hanson.xyz.vpnhotspotmod.net.monitor.TetherTimeoutMonitor +import hanson.xyz.vpnhotspotmod.net.wifi.SoftApConfigurationCompat +import hanson.xyz.vpnhotspotmod.net.wifi.SoftApConfigurationCompat.Companion.toCompat +import hanson.xyz.vpnhotspotmod.net.wifi.WifiApDialogFragment +import hanson.xyz.vpnhotspotmod.net.wifi.WifiApManager +import hanson.xyz.vpnhotspotmod.root.RootManager +import hanson.xyz.vpnhotspotmod.root.WifiApCommands +import hanson.xyz.vpnhotspotmod.util.* +import hanson.xyz.vpnhotspotmod.widget.SmartSnackbar import com.google.android.material.snackbar.Snackbar import kotlinx.coroutines.CancellationException import kotlinx.coroutines.CompletableDeferred diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/manage/TetheringTileService.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/manage/TetheringTileService.kt similarity index 95% rename from mobile/src/main/java/be/mygod/vpnhotspot/manage/TetheringTileService.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/manage/TetheringTileService.kt index 6e8ba3f3..7ff44d4f 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/manage/TetheringTileService.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/manage/TetheringTileService.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.manage +package hanson.xyz.vpnhotspotmod.manage import android.bluetooth.BluetoothManager import android.content.ComponentName @@ -12,14 +12,14 @@ import android.service.quicksettings.Tile import android.widget.Toast import androidx.annotation.RequiresApi import androidx.core.content.getSystemService -import be.mygod.vpnhotspot.R -import be.mygod.vpnhotspot.TetheringService -import be.mygod.vpnhotspot.net.TetherType -import be.mygod.vpnhotspot.net.TetheringManager -import be.mygod.vpnhotspot.net.TetheringManager.tetheredIfaces -import be.mygod.vpnhotspot.util.broadcastReceiver -import be.mygod.vpnhotspot.util.readableMessage -import be.mygod.vpnhotspot.util.stopAndUnbind +import hanson.xyz.vpnhotspotmod.R +import hanson.xyz.vpnhotspotmod.TetheringService +import hanson.xyz.vpnhotspotmod.net.TetherType +import hanson.xyz.vpnhotspotmod.net.TetheringManager +import hanson.xyz.vpnhotspotmod.net.TetheringManager.tetheredIfaces +import hanson.xyz.vpnhotspotmod.util.broadcastReceiver +import hanson.xyz.vpnhotspotmod.util.readableMessage +import hanson.xyz.vpnhotspotmod.util.stopAndUnbind import kotlinx.coroutines.Dispatchers import kotlinx.coroutines.GlobalScope import kotlinx.coroutines.launch diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/net/DhcpWorkaround.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/DhcpWorkaround.kt similarity index 87% rename from mobile/src/main/java/be/mygod/vpnhotspot/net/DhcpWorkaround.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/DhcpWorkaround.kt index e0907eb7..595a57ce 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/net/DhcpWorkaround.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/DhcpWorkaround.kt @@ -1,11 +1,11 @@ -package be.mygod.vpnhotspot.net +package hanson.xyz.vpnhotspotmod.net import android.content.SharedPreferences -import be.mygod.vpnhotspot.App.Companion.app -import be.mygod.vpnhotspot.net.Routing.Companion.IP -import be.mygod.vpnhotspot.root.RoutingCommands -import be.mygod.vpnhotspot.util.RootSession -import be.mygod.vpnhotspot.widget.SmartSnackbar +import hanson.xyz.vpnhotspotmod.App.Companion.app +import hanson.xyz.vpnhotspotmod.net.Routing.Companion.IP +import hanson.xyz.vpnhotspotmod.root.RoutingCommands +import hanson.xyz.vpnhotspotmod.util.RootSession +import hanson.xyz.vpnhotspotmod.widget.SmartSnackbar import kotlinx.coroutines.CancellationException import kotlinx.coroutines.GlobalScope import kotlinx.coroutines.launch diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/net/InetAddressComparator.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/InetAddressComparator.kt similarity index 91% rename from mobile/src/main/java/be/mygod/vpnhotspot/net/InetAddressComparator.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/InetAddressComparator.kt index e168ebb1..bf8a13ea 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/net/InetAddressComparator.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/InetAddressComparator.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.net +package hanson.xyz.vpnhotspotmod.net import java.net.InetAddress diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/net/IpNeighbour.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/IpNeighbour.kt similarity index 97% rename from mobile/src/main/java/be/mygod/vpnhotspot/net/IpNeighbour.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/IpNeighbour.kt index 99a3d282..3f1291c3 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/net/IpNeighbour.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/IpNeighbour.kt @@ -1,13 +1,13 @@ -package be.mygod.vpnhotspot.net +package hanson.xyz.vpnhotspotmod.net import android.net.MacAddress import android.os.Build import android.system.ErrnoException import android.system.Os import android.system.OsConstants -import be.mygod.vpnhotspot.root.ReadArp -import be.mygod.vpnhotspot.root.RootManager -import be.mygod.vpnhotspot.util.parseNumericAddress +import hanson.xyz.vpnhotspotmod.root.ReadArp +import hanson.xyz.vpnhotspotmod.root.RootManager +import hanson.xyz.vpnhotspotmod.util.parseNumericAddress import kotlinx.coroutines.CancellationException import timber.log.Timber import java.io.File diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/net/MacAddressCompat.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/MacAddressCompat.kt similarity index 96% rename from mobile/src/main/java/be/mygod/vpnhotspot/net/MacAddressCompat.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/MacAddressCompat.kt index 8a0b8ba1..30ffacc4 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/net/MacAddressCompat.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/MacAddressCompat.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.net +package hanson.xyz.vpnhotspotmod.net import android.net.MacAddress import java.nio.ByteBuffer diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/net/Routing.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/Routing.kt similarity index 96% rename from mobile/src/main/java/be/mygod/vpnhotspot/net/Routing.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/Routing.kt index 8c296277..bddb4623 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/net/Routing.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/Routing.kt @@ -1,22 +1,22 @@ -package be.mygod.vpnhotspot.net +package hanson.xyz.vpnhotspotmod.net import android.net.LinkProperties import android.net.MacAddress import android.net.RouteInfo import android.system.Os -import be.mygod.vpnhotspot.App.Companion.app -import be.mygod.vpnhotspot.R -import be.mygod.vpnhotspot.net.monitor.FallbackUpstreamMonitor -import be.mygod.vpnhotspot.net.monitor.IpNeighbourMonitor -import be.mygod.vpnhotspot.net.monitor.TrafficRecorder -import be.mygod.vpnhotspot.net.monitor.UpstreamMonitor -import be.mygod.vpnhotspot.room.AppDatabase -import be.mygod.vpnhotspot.root.RootManager -import be.mygod.vpnhotspot.root.RoutingCommands -import be.mygod.vpnhotspot.util.RootSession -import be.mygod.vpnhotspot.util.allInterfaceNames -import be.mygod.vpnhotspot.util.allRoutes -import be.mygod.vpnhotspot.widget.SmartSnackbar +import hanson.xyz.vpnhotspotmod.App.Companion.app +import hanson.xyz.vpnhotspotmod.R +import hanson.xyz.vpnhotspotmod.net.monitor.FallbackUpstreamMonitor +import hanson.xyz.vpnhotspotmod.net.monitor.IpNeighbourMonitor +import hanson.xyz.vpnhotspotmod.net.monitor.TrafficRecorder +import hanson.xyz.vpnhotspotmod.net.monitor.UpstreamMonitor +import hanson.xyz.vpnhotspotmod.room.AppDatabase +import hanson.xyz.vpnhotspotmod.root.RootManager +import hanson.xyz.vpnhotspotmod.root.RoutingCommands +import hanson.xyz.vpnhotspotmod.util.RootSession +import hanson.xyz.vpnhotspotmod.util.allInterfaceNames +import hanson.xyz.vpnhotspotmod.util.allRoutes +import hanson.xyz.vpnhotspotmod.widget.SmartSnackbar import kotlinx.coroutines.CancellationException import timber.log.Timber import java.io.BufferedWriter diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/net/TetherOffloadManager.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/TetherOffloadManager.kt similarity index 85% rename from mobile/src/main/java/be/mygod/vpnhotspot/net/TetherOffloadManager.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/TetherOffloadManager.kt index 573cb8c6..def054b7 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/net/TetherOffloadManager.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/TetherOffloadManager.kt @@ -1,8 +1,8 @@ -package be.mygod.vpnhotspot.net +package hanson.xyz.vpnhotspotmod.net import android.provider.Settings -import be.mygod.vpnhotspot.App.Companion.app -import be.mygod.vpnhotspot.root.SettingsGlobalPut +import hanson.xyz.vpnhotspotmod.App.Companion.app +import hanson.xyz.vpnhotspotmod.root.SettingsGlobalPut /** * It's hard to change tethering rules with Tethering hardware acceleration enabled for now. diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/net/TetherType.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/TetherType.kt similarity index 96% rename from mobile/src/main/java/be/mygod/vpnhotspot/net/TetherType.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/TetherType.kt index 2bdd1549..b4b62e00 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/net/TetherType.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/TetherType.kt @@ -1,13 +1,13 @@ -package be.mygod.vpnhotspot.net +package hanson.xyz.vpnhotspotmod.net import android.content.res.Resources import android.os.Build import androidx.annotation.DrawableRes import androidx.annotation.RequiresApi -import be.mygod.vpnhotspot.App.Companion.app -import be.mygod.vpnhotspot.R -import be.mygod.vpnhotspot.util.Event0 -import be.mygod.vpnhotspot.util.findIdentifier +import hanson.xyz.vpnhotspotmod.App.Companion.app +import hanson.xyz.vpnhotspotmod.R +import hanson.xyz.vpnhotspotmod.util.Event0 +import hanson.xyz.vpnhotspotmod.util.findIdentifier import timber.log.Timber import java.util.regex.Pattern diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/net/TetheringManager.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/TetheringManager.kt similarity index 95% rename from mobile/src/main/java/be/mygod/vpnhotspot/net/TetheringManager.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/TetheringManager.kt index a84032bc..c36d954b 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/net/TetheringManager.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/TetheringManager.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.net +package hanson.xyz.vpnhotspotmod.net import android.annotation.SuppressLint import android.annotation.TargetApi @@ -12,14 +12,18 @@ import android.net.Network import android.os.Build import android.os.DeadObjectException import android.os.Handler +import android.os.Looper import androidx.annotation.RequiresApi +import androidx.core.content.ContextCompat.startActivity import androidx.core.os.ExecutorCompat -import be.mygod.vpnhotspot.App.Companion.app -import be.mygod.vpnhotspot.root.RootManager -import be.mygod.vpnhotspot.root.StartTethering -import be.mygod.vpnhotspot.root.StopTethering -import be.mygod.vpnhotspot.util.* +import hanson.xyz.vpnhotspotmod.App.Companion.app +import hanson.xyz.vpnhotspotmod.root.RootManager +import hanson.xyz.vpnhotspotmod.root.StartTethering +import hanson.xyz.vpnhotspotmod.root.StopTethering +import hanson.xyz.vpnhotspotmod.util.* import com.android.dx.stock.ProxyBuilder +import hanson.xyz.vpnhotspotmod.App +import hanson.xyz.vpnhotspotmod.TetheringService import kotlinx.coroutines.Dispatchers import kotlinx.coroutines.GlobalScope import kotlinx.coroutines.launch @@ -335,7 +339,7 @@ object TetheringManager { rootCache.mkdirs() check(rootCache.exists()) { "Creating root cache dir failed" } RootManager.use { - it.execute(be.mygod.vpnhotspot.root.StartTetheringLegacy( + it.execute(hanson.xyz.vpnhotspotmod.root.StartTetheringLegacy( rootCache, type, showProvisioningUi)) }.value } catch (eRoot: Exception) { @@ -447,7 +451,9 @@ object TetheringManager { * multiple times later upon changes. * @param interfaces The list of tetherable interface names. */ - fun onTetherableInterfacesChanged(interfaces: List) {} + fun onTetherableInterfacesChanged(interfaces: List) { + //hansonxyz + } /** * Called when there was a change in the list of tethered interfaces. @@ -554,10 +560,27 @@ object TetheringManager { @Suppress("UNCHECKED_CAST") callback?.onTetherableInterfacesChanged(args!![0] as List) } + + // modified by hansonxyz method.matches1>("onTetheredInterfacesChanged") -> { @Suppress("UNCHECKED_CAST") - callback?.onTetheredInterfacesChanged(args!![0] as List) + val tetheredInterfaces = args!![0] as List + callback?.onTetheredInterfacesChanged(tetheredInterfaces) + + // hansonxyz + tetheredInterfaces?.let { + for (iface in it) { + App.app.startForegroundService( + Intent(App.app, TetheringService::class.java) + .putExtra( + TetheringService.EXTRA_ADD_INTERFACES, + arrayOf(iface) + ) + ) + } + } } + method.matches("onError", String::class.java, Integer.TYPE) -> { callback?.onError(args!![0] as String, args[1] as Int) } diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/DefaultNetworkMonitor.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/monitor/DefaultNetworkMonitor.kt similarity index 94% rename from mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/DefaultNetworkMonitor.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/monitor/DefaultNetworkMonitor.kt index 919f2f6f..3f08bfd9 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/DefaultNetworkMonitor.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/monitor/DefaultNetworkMonitor.kt @@ -1,12 +1,12 @@ -package be.mygod.vpnhotspot.net.monitor +package hanson.xyz.vpnhotspotmod.net.monitor import android.net.ConnectivityManager import android.net.LinkProperties import android.net.Network import android.net.NetworkCapabilities import android.os.Build -import be.mygod.vpnhotspot.util.Services -import be.mygod.vpnhotspot.util.globalNetworkRequestBuilder +import hanson.xyz.vpnhotspotmod.util.Services +import hanson.xyz.vpnhotspotmod.util.globalNetworkRequestBuilder import kotlinx.coroutines.GlobalScope import kotlinx.coroutines.launch diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/FallbackUpstreamMonitor.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/monitor/FallbackUpstreamMonitor.kt similarity index 94% rename from mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/FallbackUpstreamMonitor.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/monitor/FallbackUpstreamMonitor.kt index 94e7219d..671c15e0 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/FallbackUpstreamMonitor.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/monitor/FallbackUpstreamMonitor.kt @@ -1,7 +1,7 @@ -package be.mygod.vpnhotspot.net.monitor +package hanson.xyz.vpnhotspotmod.net.monitor import android.content.SharedPreferences -import be.mygod.vpnhotspot.App.Companion.app +import hanson.xyz.vpnhotspotmod.App.Companion.app import kotlinx.coroutines.GlobalScope import kotlinx.coroutines.launch diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/InterfaceMonitor.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/monitor/InterfaceMonitor.kt similarity index 94% rename from mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/InterfaceMonitor.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/monitor/InterfaceMonitor.kt index f2466bf1..402c1e38 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/InterfaceMonitor.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/monitor/InterfaceMonitor.kt @@ -1,12 +1,12 @@ -package be.mygod.vpnhotspot.net.monitor +package hanson.xyz.vpnhotspotmod.net.monitor import android.net.ConnectivityManager import android.net.LinkProperties import android.net.Network import android.net.NetworkCapabilities -import be.mygod.vpnhotspot.util.Services -import be.mygod.vpnhotspot.util.allInterfaceNames -import be.mygod.vpnhotspot.util.globalNetworkRequestBuilder +import hanson.xyz.vpnhotspotmod.util.Services +import hanson.xyz.vpnhotspotmod.util.allInterfaceNames +import hanson.xyz.vpnhotspotmod.util.globalNetworkRequestBuilder import kotlinx.coroutines.GlobalScope import kotlinx.coroutines.launch import timber.log.Timber diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/IpMonitor.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/monitor/IpMonitor.kt similarity index 94% rename from mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/IpMonitor.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/monitor/IpMonitor.kt index aafa1392..88c4831d 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/IpMonitor.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/monitor/IpMonitor.kt @@ -1,17 +1,17 @@ -package be.mygod.vpnhotspot.net.monitor +package hanson.xyz.vpnhotspotmod.net.monitor import android.os.Build import androidx.core.content.edit import be.mygod.librootkotlinx.RootServer import be.mygod.librootkotlinx.isEBADF -import be.mygod.vpnhotspot.App.Companion.app -import be.mygod.vpnhotspot.R -import be.mygod.vpnhotspot.net.Routing -import be.mygod.vpnhotspot.root.ProcessData -import be.mygod.vpnhotspot.root.ProcessListener -import be.mygod.vpnhotspot.root.RootManager -import be.mygod.vpnhotspot.root.RoutingCommands -import be.mygod.vpnhotspot.widget.SmartSnackbar +import hanson.xyz.vpnhotspotmod.App.Companion.app +import hanson.xyz.vpnhotspotmod.R +import hanson.xyz.vpnhotspotmod.net.Routing +import hanson.xyz.vpnhotspotmod.root.ProcessData +import hanson.xyz.vpnhotspotmod.root.ProcessListener +import hanson.xyz.vpnhotspotmod.root.RootManager +import hanson.xyz.vpnhotspotmod.root.RoutingCommands +import hanson.xyz.vpnhotspotmod.widget.SmartSnackbar import kotlinx.coroutines.* import kotlinx.coroutines.channels.ReceiveChannel import kotlinx.coroutines.channels.consumeEach diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/IpNeighbourMonitor.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/monitor/IpNeighbourMonitor.kt similarity index 95% rename from mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/IpNeighbourMonitor.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/monitor/IpNeighbourMonitor.kt index 2b55761b..2bf5b7cf 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/IpNeighbourMonitor.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/monitor/IpNeighbourMonitor.kt @@ -1,7 +1,7 @@ -package be.mygod.vpnhotspot.net.monitor +package hanson.xyz.vpnhotspotmod.net.monitor -import be.mygod.vpnhotspot.net.IpDev -import be.mygod.vpnhotspot.net.IpNeighbour +import hanson.xyz.vpnhotspotmod.net.IpDev +import hanson.xyz.vpnhotspotmod.net.IpNeighbour import kotlinx.collections.immutable.PersistentMap import kotlinx.collections.immutable.persistentMapOf import kotlinx.collections.immutable.toPersistentMap diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/TetherTimeoutMonitor.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/monitor/TetherTimeoutMonitor.kt similarity index 93% rename from mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/TetherTimeoutMonitor.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/monitor/TetherTimeoutMonitor.kt index 7bf794ee..83eb7dc7 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/TetherTimeoutMonitor.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/monitor/TetherTimeoutMonitor.kt @@ -1,13 +1,13 @@ -package be.mygod.vpnhotspot.net.monitor +package hanson.xyz.vpnhotspotmod.net.monitor import android.content.res.Resources import android.os.Build import android.provider.Settings import androidx.annotation.RequiresApi -import be.mygod.vpnhotspot.App.Companion.app -import be.mygod.vpnhotspot.net.wifi.WifiApManager -import be.mygod.vpnhotspot.root.SettingsGlobalPut -import be.mygod.vpnhotspot.util.findIdentifier +import hanson.xyz.vpnhotspotmod.App.Companion.app +import hanson.xyz.vpnhotspotmod.net.wifi.WifiApManager +import hanson.xyz.vpnhotspotmod.root.SettingsGlobalPut +import hanson.xyz.vpnhotspotmod.util.findIdentifier import kotlinx.coroutines.* import timber.log.Timber import kotlin.coroutines.CoroutineContext diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/TrafficRecorder.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/monitor/TrafficRecorder.kt similarity index 93% rename from mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/TrafficRecorder.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/monitor/TrafficRecorder.kt index c37596d5..204cf053 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/TrafficRecorder.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/monitor/TrafficRecorder.kt @@ -1,16 +1,16 @@ -package be.mygod.vpnhotspot.net.monitor +package hanson.xyz.vpnhotspotmod.net.monitor import android.net.MacAddress import androidx.collection.LongSparseArray import androidx.collection.set -import be.mygod.vpnhotspot.net.IpDev -import be.mygod.vpnhotspot.net.Routing.Companion.IPTABLES -import be.mygod.vpnhotspot.room.AppDatabase -import be.mygod.vpnhotspot.room.TrafficRecord -import be.mygod.vpnhotspot.util.Event2 -import be.mygod.vpnhotspot.util.RootSession -import be.mygod.vpnhotspot.util.parseNumericAddress -import be.mygod.vpnhotspot.widget.SmartSnackbar +import hanson.xyz.vpnhotspotmod.net.IpDev +import hanson.xyz.vpnhotspotmod.net.Routing.Companion.IPTABLES +import hanson.xyz.vpnhotspotmod.room.AppDatabase +import hanson.xyz.vpnhotspotmod.room.TrafficRecord +import hanson.xyz.vpnhotspotmod.util.Event2 +import hanson.xyz.vpnhotspotmod.util.RootSession +import hanson.xyz.vpnhotspotmod.util.parseNumericAddress +import hanson.xyz.vpnhotspotmod.widget.SmartSnackbar import kotlinx.coroutines.CancellationException import kotlinx.coroutines.CoroutineStart import kotlinx.coroutines.GlobalScope diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/UpstreamMonitor.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/monitor/UpstreamMonitor.kt similarity index 96% rename from mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/UpstreamMonitor.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/monitor/UpstreamMonitor.kt index 07e54dc4..0a67c767 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/UpstreamMonitor.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/monitor/UpstreamMonitor.kt @@ -1,8 +1,8 @@ -package be.mygod.vpnhotspot.net.monitor +package hanson.xyz.vpnhotspotmod.net.monitor import android.content.SharedPreferences import android.net.LinkProperties -import be.mygod.vpnhotspot.App.Companion.app +import hanson.xyz.vpnhotspotmod.App.Companion.app import kotlinx.coroutines.GlobalScope import kotlinx.coroutines.launch diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/VpnMonitor.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/monitor/VpnMonitor.kt similarity index 94% rename from mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/VpnMonitor.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/monitor/VpnMonitor.kt index 1e3997ca..1f200958 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/net/monitor/VpnMonitor.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/monitor/VpnMonitor.kt @@ -1,11 +1,11 @@ -package be.mygod.vpnhotspot.net.monitor +package hanson.xyz.vpnhotspotmod.net.monitor import android.net.ConnectivityManager import android.net.LinkProperties import android.net.Network import android.net.NetworkCapabilities -import be.mygod.vpnhotspot.util.Services -import be.mygod.vpnhotspot.util.globalNetworkRequestBuilder +import hanson.xyz.vpnhotspotmod.util.Services +import hanson.xyz.vpnhotspotmod.util.globalNetworkRequestBuilder import kotlinx.coroutines.GlobalScope import kotlinx.coroutines.launch import timber.log.Timber diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/net/wifi/P2pSupplicantConfiguration.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/wifi/P2pSupplicantConfiguration.kt similarity index 96% rename from mobile/src/main/java/be/mygod/vpnhotspot/net/wifi/P2pSupplicantConfiguration.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/wifi/P2pSupplicantConfiguration.kt index 8f178127..5e41ba8d 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/net/wifi/P2pSupplicantConfiguration.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/wifi/P2pSupplicantConfiguration.kt @@ -1,11 +1,11 @@ -package be.mygod.vpnhotspot.net.wifi +package hanson.xyz.vpnhotspotmod.net.wifi import android.net.MacAddress import android.net.wifi.p2p.WifiP2pGroup -import be.mygod.vpnhotspot.RepeaterService -import be.mygod.vpnhotspot.net.MacAddressCompat -import be.mygod.vpnhotspot.root.RepeaterCommands -import be.mygod.vpnhotspot.root.RootManager +import hanson.xyz.vpnhotspotmod.RepeaterService +import hanson.xyz.vpnhotspotmod.net.MacAddressCompat +import hanson.xyz.vpnhotspotmod.root.RepeaterCommands +import hanson.xyz.vpnhotspotmod.root.RootManager import com.google.firebase.crashlytics.FirebaseCrashlytics /** diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/net/wifi/SoftApCapability.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/wifi/SoftApCapability.kt similarity index 93% rename from mobile/src/main/java/be/mygod/vpnhotspot/net/wifi/SoftApCapability.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/wifi/SoftApCapability.kt index 556e4bc5..c5d7d51c 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/net/wifi/SoftApCapability.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/wifi/SoftApCapability.kt @@ -1,11 +1,11 @@ -package be.mygod.vpnhotspot.net.wifi +package hanson.xyz.vpnhotspotmod.net.wifi import android.annotation.TargetApi import android.os.Build import android.os.Parcelable import androidx.annotation.RequiresApi -import be.mygod.vpnhotspot.util.LongConstantLookup -import be.mygod.vpnhotspot.util.UnblockCentral +import hanson.xyz.vpnhotspotmod.util.LongConstantLookup +import hanson.xyz.vpnhotspotmod.util.UnblockCentral import timber.log.Timber @JvmInline diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/net/wifi/SoftApConfigurationCompat.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/wifi/SoftApConfigurationCompat.kt similarity index 98% rename from mobile/src/main/java/be/mygod/vpnhotspot/net/wifi/SoftApConfigurationCompat.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/wifi/SoftApConfigurationCompat.kt index 52f189a4..4bcc2147 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/net/wifi/SoftApConfigurationCompat.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/wifi/SoftApConfigurationCompat.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.net.wifi +package hanson.xyz.vpnhotspotmod.net.wifi import android.annotation.SuppressLint import android.annotation.TargetApi @@ -10,12 +10,12 @@ import android.os.Build import android.os.Parcelable import android.util.SparseIntArray import androidx.annotation.RequiresApi -import be.mygod.vpnhotspot.net.monitor.TetherTimeoutMonitor -import be.mygod.vpnhotspot.net.wifi.SoftApConfigurationCompat.Companion.requireSingleBand -import be.mygod.vpnhotspot.net.wifi.SoftApConfigurationCompat.Companion.setChannel -import be.mygod.vpnhotspot.net.wifi.WifiSsidCompat.Companion.toCompat -import be.mygod.vpnhotspot.util.ConstantLookup -import be.mygod.vpnhotspot.util.UnblockCentral +import hanson.xyz.vpnhotspotmod.net.monitor.TetherTimeoutMonitor +import hanson.xyz.vpnhotspotmod.net.wifi.SoftApConfigurationCompat.Companion.requireSingleBand +import hanson.xyz.vpnhotspotmod.net.wifi.SoftApConfigurationCompat.Companion.setChannel +import hanson.xyz.vpnhotspotmod.net.wifi.WifiSsidCompat.Companion.toCompat +import hanson.xyz.vpnhotspotmod.util.ConstantLookup +import hanson.xyz.vpnhotspotmod.util.UnblockCentral import kotlinx.parcelize.Parcelize import timber.log.Timber import java.lang.reflect.InvocationTargetException diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/net/wifi/SoftApInfo.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/wifi/SoftApInfo.kt similarity index 92% rename from mobile/src/main/java/be/mygod/vpnhotspot/net/wifi/SoftApInfo.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/wifi/SoftApInfo.kt index 167534d5..8cb4ff23 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/net/wifi/SoftApInfo.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/wifi/SoftApInfo.kt @@ -1,11 +1,11 @@ -package be.mygod.vpnhotspot.net.wifi +package hanson.xyz.vpnhotspotmod.net.wifi import android.annotation.TargetApi import android.net.MacAddress import android.os.Parcelable import androidx.annotation.RequiresApi -import be.mygod.vpnhotspot.util.ConstantLookup -import be.mygod.vpnhotspot.util.UnblockCentral +import hanson.xyz.vpnhotspotmod.util.ConstantLookup +import hanson.xyz.vpnhotspotmod.util.UnblockCentral import timber.log.Timber @JvmInline diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/net/wifi/VendorElements.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/wifi/VendorElements.kt similarity index 96% rename from mobile/src/main/java/be/mygod/vpnhotspot/net/wifi/VendorElements.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/wifi/VendorElements.kt index 9b527d29..66b105c3 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/net/wifi/VendorElements.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/wifi/VendorElements.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.net.wifi +package hanson.xyz.vpnhotspotmod.net.wifi import android.net.wifi.ScanResult import androidx.annotation.RequiresApi diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/net/wifi/WifiApDialogFragment.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/wifi/WifiApDialogFragment.kt similarity index 97% rename from mobile/src/main/java/be/mygod/vpnhotspot/net/wifi/WifiApDialogFragment.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/wifi/WifiApDialogFragment.kt index bf5664b4..a4e5ad58 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/net/wifi/WifiApDialogFragment.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/wifi/WifiApDialogFragment.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.net.wifi +package hanson.xyz.vpnhotspotmod.net.wifi import android.annotation.SuppressLint import android.content.ClipData @@ -26,17 +26,17 @@ import androidx.core.os.persistableBundleOf import androidx.core.view.isGone import be.mygod.librootkotlinx.toByteArray import be.mygod.librootkotlinx.toParcelable -import be.mygod.vpnhotspot.AlertDialogFragment -import be.mygod.vpnhotspot.App.Companion.app -import be.mygod.vpnhotspot.R -import be.mygod.vpnhotspot.RepeaterService -import be.mygod.vpnhotspot.databinding.DialogWifiApBinding -import be.mygod.vpnhotspot.net.monitor.TetherTimeoutMonitor -import be.mygod.vpnhotspot.util.QRCodeDialog -import be.mygod.vpnhotspot.util.RangeInput -import be.mygod.vpnhotspot.util.Services -import be.mygod.vpnhotspot.util.readableMessage -import be.mygod.vpnhotspot.util.showAllowingStateLoss +import hanson.xyz.vpnhotspotmod.AlertDialogFragment +import hanson.xyz.vpnhotspotmod.App.Companion.app +import hanson.xyz.vpnhotspotmod.R +import hanson.xyz.vpnhotspotmod.RepeaterService +import hanson.xyz.vpnhotspotmod.databinding.DialogWifiApBinding +import hanson.xyz.vpnhotspotmod.net.monitor.TetherTimeoutMonitor +import hanson.xyz.vpnhotspotmod.util.QRCodeDialog +import hanson.xyz.vpnhotspotmod.util.RangeInput +import hanson.xyz.vpnhotspotmod.util.Services +import hanson.xyz.vpnhotspotmod.util.readableMessage +import hanson.xyz.vpnhotspotmod.util.showAllowingStateLoss import com.google.android.material.textfield.TextInputLayout import kotlinx.parcelize.Parcelize import timber.log.Timber diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/net/wifi/WifiApManager.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/wifi/WifiApManager.kt similarity index 99% rename from mobile/src/main/java/be/mygod/vpnhotspot/net/wifi/WifiApManager.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/wifi/WifiApManager.kt index fd0bb428..162c8ed5 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/net/wifi/WifiApManager.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/wifi/WifiApManager.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.net.wifi +package hanson.xyz.vpnhotspotmod.net.wifi import android.annotation.TargetApi import android.content.Intent @@ -11,8 +11,8 @@ import android.os.Build import android.os.Handler import android.os.Parcelable import androidx.annotation.RequiresApi -import be.mygod.vpnhotspot.App.Companion.app -import be.mygod.vpnhotspot.util.* +import hanson.xyz.vpnhotspotmod.App.Companion.app +import hanson.xyz.vpnhotspotmod.util.* import timber.log.Timber import java.lang.reflect.InvocationHandler import java.lang.reflect.Method diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/net/wifi/WifiClient.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/wifi/WifiClient.kt similarity index 89% rename from mobile/src/main/java/be/mygod/vpnhotspot/net/wifi/WifiClient.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/wifi/WifiClient.kt index b106db9d..dc366a4a 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/net/wifi/WifiClient.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/wifi/WifiClient.kt @@ -1,10 +1,10 @@ -package be.mygod.vpnhotspot.net.wifi +package hanson.xyz.vpnhotspotmod.net.wifi import android.annotation.TargetApi import android.net.MacAddress import android.os.Parcelable import androidx.annotation.RequiresApi -import be.mygod.vpnhotspot.util.UnblockCentral +import hanson.xyz.vpnhotspotmod.util.UnblockCentral import timber.log.Timber @JvmInline diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/net/wifi/WifiDoubleLock.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/wifi/WifiDoubleLock.kt similarity index 96% rename from mobile/src/main/java/be/mygod/vpnhotspot/net/wifi/WifiDoubleLock.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/wifi/WifiDoubleLock.kt index fbd0bb5c..994734e7 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/net/wifi/WifiDoubleLock.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/wifi/WifiDoubleLock.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.net.wifi +package hanson.xyz.vpnhotspotmod.net.wifi import android.annotation.SuppressLint import android.content.SharedPreferences @@ -12,8 +12,8 @@ import androidx.core.content.edit import androidx.core.content.getSystemService import androidx.lifecycle.DefaultLifecycleObserver import androidx.lifecycle.LifecycleOwner -import be.mygod.vpnhotspot.App.Companion.app -import be.mygod.vpnhotspot.util.Services +import hanson.xyz.vpnhotspotmod.App.Companion.app +import hanson.xyz.vpnhotspotmod.util.Services /** * This mechanism is used to maximize profit. Source: https://stackoverflow.com/a/29657230/2245107 diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/net/wifi/WifiP2pManagerHelper.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/wifi/WifiP2pManagerHelper.kt similarity index 96% rename from mobile/src/main/java/be/mygod/vpnhotspot/net/wifi/WifiP2pManagerHelper.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/wifi/WifiP2pManagerHelper.kt index 4baa0ad5..fb067aec 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/net/wifi/WifiP2pManagerHelper.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/wifi/WifiP2pManagerHelper.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.net.wifi +package hanson.xyz.vpnhotspotmod.net.wifi import android.annotation.SuppressLint import android.net.MacAddress @@ -8,10 +8,10 @@ import android.net.wifi.p2p.WifiP2pGroup import android.net.wifi.p2p.WifiP2pInfo import android.net.wifi.p2p.WifiP2pManager import androidx.annotation.RequiresApi -import be.mygod.vpnhotspot.App.Companion.app -import be.mygod.vpnhotspot.net.MacAddressCompat -import be.mygod.vpnhotspot.util.callSuper -import be.mygod.vpnhotspot.util.matches +import hanson.xyz.vpnhotspotmod.App.Companion.app +import hanson.xyz.vpnhotspotmod.net.MacAddressCompat +import hanson.xyz.vpnhotspotmod.util.callSuper +import hanson.xyz.vpnhotspotmod.util.matches import kotlinx.coroutines.CompletableDeferred import java.lang.reflect.InvocationHandler import java.lang.reflect.Method diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/net/wifi/WifiSsidCompat.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/wifi/WifiSsidCompat.kt similarity index 98% rename from mobile/src/main/java/be/mygod/vpnhotspot/net/wifi/WifiSsidCompat.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/wifi/WifiSsidCompat.kt index c8fa1e8f..951ee566 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/net/wifi/WifiSsidCompat.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/net/wifi/WifiSsidCompat.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.net.wifi +package hanson.xyz.vpnhotspotmod.net.wifi import android.net.wifi.WifiSsid import android.os.Parcelable diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/preference/AutoCompleteNetworkPreferenceDialogFragment.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/preference/AutoCompleteNetworkPreferenceDialogFragment.kt similarity index 90% rename from mobile/src/main/java/be/mygod/vpnhotspot/preference/AutoCompleteNetworkPreferenceDialogFragment.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/preference/AutoCompleteNetworkPreferenceDialogFragment.kt index 33df6097..f75335b3 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/preference/AutoCompleteNetworkPreferenceDialogFragment.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/preference/AutoCompleteNetworkPreferenceDialogFragment.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.preference +package hanson.xyz.vpnhotspotmod.preference import android.content.Context import android.net.ConnectivityManager @@ -12,11 +12,11 @@ import androidx.core.os.bundleOf import androidx.lifecycle.lifecycleScope import androidx.lifecycle.withStarted import androidx.preference.EditTextPreferenceDialogFragmentCompat -import be.mygod.vpnhotspot.R -import be.mygod.vpnhotspot.util.Services -import be.mygod.vpnhotspot.util.allInterfaceNames -import be.mygod.vpnhotspot.util.globalNetworkRequestBuilder -import be.mygod.vpnhotspot.widget.AlwaysAutoCompleteEditText +import hanson.xyz.vpnhotspotmod.R +import hanson.xyz.vpnhotspotmod.util.Services +import hanson.xyz.vpnhotspotmod.util.allInterfaceNames +import hanson.xyz.vpnhotspotmod.util.globalNetworkRequestBuilder +import hanson.xyz.vpnhotspotmod.widget.AlwaysAutoCompleteEditText import kotlinx.coroutines.launch class AutoCompleteNetworkPreferenceDialogFragment : EditTextPreferenceDialogFragmentCompat() { diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/preference/SharedPreferenceDataStore.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/preference/SharedPreferenceDataStore.kt similarity index 96% rename from mobile/src/main/java/be/mygod/vpnhotspot/preference/SharedPreferenceDataStore.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/preference/SharedPreferenceDataStore.kt index 0dc3d240..c9eb8f4d 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/preference/SharedPreferenceDataStore.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/preference/SharedPreferenceDataStore.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.preference +package hanson.xyz.vpnhotspotmod.preference import android.content.SharedPreferences import androidx.core.content.edit diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/preference/SummaryFallbackProvider.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/preference/SummaryFallbackProvider.kt similarity index 90% rename from mobile/src/main/java/be/mygod/vpnhotspot/preference/SummaryFallbackProvider.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/preference/SummaryFallbackProvider.kt index d52b8320..be19357e 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/preference/SummaryFallbackProvider.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/preference/SummaryFallbackProvider.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.preference +package hanson.xyz.vpnhotspotmod.preference import androidx.preference.EditTextPreference import androidx.preference.Preference diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/preference/UpstreamsPreference.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/preference/UpstreamsPreference.kt similarity index 88% rename from mobile/src/main/java/be/mygod/vpnhotspot/preference/UpstreamsPreference.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/preference/UpstreamsPreference.kt index 46ecf64f..735538eb 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/preference/UpstreamsPreference.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/preference/UpstreamsPreference.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.preference +package hanson.xyz.vpnhotspotmod.preference import android.content.Context import android.graphics.Typeface @@ -10,12 +10,12 @@ import androidx.lifecycle.DefaultLifecycleObserver import androidx.lifecycle.LifecycleOwner import androidx.lifecycle.lifecycleScope import androidx.preference.Preference -import be.mygod.vpnhotspot.R -import be.mygod.vpnhotspot.net.monitor.FallbackUpstreamMonitor -import be.mygod.vpnhotspot.net.monitor.UpstreamMonitor -import be.mygod.vpnhotspot.util.allRoutes -import be.mygod.vpnhotspot.util.format -import be.mygod.vpnhotspot.util.parseNumericAddress +import hanson.xyz.vpnhotspotmod.R +import hanson.xyz.vpnhotspotmod.net.monitor.FallbackUpstreamMonitor +import hanson.xyz.vpnhotspotmod.net.monitor.UpstreamMonitor +import hanson.xyz.vpnhotspotmod.util.allRoutes +import hanson.xyz.vpnhotspotmod.util.format +import hanson.xyz.vpnhotspotmod.util.parseNumericAddress import kotlinx.coroutines.launch import timber.log.Timber diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/room/AppDatabase.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/room/AppDatabase.kt similarity index 92% rename from mobile/src/main/java/be/mygod/vpnhotspot/room/AppDatabase.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/room/AppDatabase.kt index 5a04b9cc..c948d5b3 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/room/AppDatabase.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/room/AppDatabase.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.room +package hanson.xyz.vpnhotspotmod.room import androidx.room.Database import androidx.room.Room @@ -6,7 +6,7 @@ import androidx.room.RoomDatabase import androidx.room.TypeConverters import androidx.room.migration.Migration import androidx.sqlite.db.SupportSQLiteDatabase -import be.mygod.vpnhotspot.App.Companion.app +import hanson.xyz.vpnhotspotmod.App.Companion.app import kotlinx.coroutines.GlobalScope import kotlinx.coroutines.launch diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/room/ClientRecord.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/room/ClientRecord.kt similarity index 93% rename from mobile/src/main/java/be/mygod/vpnhotspot/room/ClientRecord.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/room/ClientRecord.kt index 1fec6f22..c86597c2 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/room/ClientRecord.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/room/ClientRecord.kt @@ -1,10 +1,10 @@ -package be.mygod.vpnhotspot.room +package hanson.xyz.vpnhotspotmod.room import android.net.MacAddress import androidx.lifecycle.LiveData import androidx.lifecycle.map import androidx.room.* -import be.mygod.vpnhotspot.net.MacAddressCompat.Companion.toLong +import hanson.xyz.vpnhotspotmod.net.MacAddressCompat.Companion.toLong @Entity data class ClientRecord(@PrimaryKey diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/room/Converters.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/room/Converters.kt similarity index 88% rename from mobile/src/main/java/be/mygod/vpnhotspot/room/Converters.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/room/Converters.kt index ebfcf246..d0629610 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/room/Converters.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/room/Converters.kt @@ -1,11 +1,11 @@ -package be.mygod.vpnhotspot.room +package hanson.xyz.vpnhotspotmod.room import android.net.MacAddress import android.text.TextUtils import androidx.room.TypeConverter import be.mygod.librootkotlinx.useParcel -import be.mygod.vpnhotspot.net.MacAddressCompat -import be.mygod.vpnhotspot.net.MacAddressCompat.Companion.toLong +import hanson.xyz.vpnhotspotmod.net.MacAddressCompat +import hanson.xyz.vpnhotspotmod.net.MacAddressCompat.Companion.toLong import timber.log.Timber import java.net.InetAddress diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/room/TrafficRecord.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/room/TrafficRecord.kt similarity index 98% rename from mobile/src/main/java/be/mygod/vpnhotspot/room/TrafficRecord.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/room/TrafficRecord.kt index d0b6e315..3b7b2c85 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/room/TrafficRecord.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/room/TrafficRecord.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.room +package hanson.xyz.vpnhotspotmod.room import android.net.MacAddress import android.os.Parcelable diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/root/LocalOnlyHotspotCallbacks.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/root/LocalOnlyHotspotCallbacks.kt similarity index 94% rename from mobile/src/main/java/be/mygod/vpnhotspot/root/LocalOnlyHotspotCallbacks.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/root/LocalOnlyHotspotCallbacks.kt index ef73a04e..c8653e68 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/root/LocalOnlyHotspotCallbacks.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/root/LocalOnlyHotspotCallbacks.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.root +package hanson.xyz.vpnhotspotmod.root import android.net.wifi.SoftApConfiguration import android.os.Parcelable diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/root/MiscCommands.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/root/MiscCommands.kt similarity index 96% rename from mobile/src/main/java/be/mygod/vpnhotspot/root/MiscCommands.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/root/MiscCommands.kt index ea8a17d4..35980019 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/root/MiscCommands.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/root/MiscCommands.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.root +package hanson.xyz.vpnhotspotmod.root import android.content.Context import android.os.Parcelable @@ -6,11 +6,11 @@ import android.os.RemoteException import android.provider.Settings import androidx.annotation.RequiresApi import be.mygod.librootkotlinx.* -import be.mygod.vpnhotspot.App.Companion.app -import be.mygod.vpnhotspot.net.Routing.Companion.IP -import be.mygod.vpnhotspot.net.Routing.Companion.IPTABLES -import be.mygod.vpnhotspot.net.TetheringManager -import be.mygod.vpnhotspot.util.Services +import hanson.xyz.vpnhotspotmod.App.Companion.app +import hanson.xyz.vpnhotspotmod.net.Routing.Companion.IP +import hanson.xyz.vpnhotspotmod.net.Routing.Companion.IPTABLES +import hanson.xyz.vpnhotspotmod.net.TetheringManager +import hanson.xyz.vpnhotspotmod.util.Services import kotlinx.coroutines.* import kotlinx.coroutines.channels.onClosed import kotlinx.coroutines.channels.onFailure diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/root/RepeaterCommands.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/root/RepeaterCommands.kt similarity index 88% rename from mobile/src/main/java/be/mygod/vpnhotspot/root/RepeaterCommands.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/root/RepeaterCommands.kt index 1ead2991..46c2f36e 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/root/RepeaterCommands.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/root/RepeaterCommands.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.root +package hanson.xyz.vpnhotspotmod.root import android.net.MacAddress import android.net.wifi.ScanResult @@ -10,12 +10,12 @@ import android.system.OsConstants import android.text.TextUtils import androidx.annotation.RequiresApi import be.mygod.librootkotlinx.* -import be.mygod.vpnhotspot.net.wifi.WifiP2pManagerHelper.deletePersistentGroup -import be.mygod.vpnhotspot.net.wifi.WifiP2pManagerHelper.requestDeviceAddress -import be.mygod.vpnhotspot.net.wifi.WifiP2pManagerHelper.requestPersistentGroupInfo -import be.mygod.vpnhotspot.net.wifi.WifiP2pManagerHelper.setVendorElements -import be.mygod.vpnhotspot.net.wifi.WifiP2pManagerHelper.setWifiP2pChannels -import be.mygod.vpnhotspot.util.Services +import hanson.xyz.vpnhotspotmod.net.wifi.WifiP2pManagerHelper.deletePersistentGroup +import hanson.xyz.vpnhotspotmod.net.wifi.WifiP2pManagerHelper.requestDeviceAddress +import hanson.xyz.vpnhotspotmod.net.wifi.WifiP2pManagerHelper.requestPersistentGroupInfo +import hanson.xyz.vpnhotspotmod.net.wifi.WifiP2pManagerHelper.setVendorElements +import hanson.xyz.vpnhotspotmod.net.wifi.WifiP2pManagerHelper.setWifiP2pChannels +import hanson.xyz.vpnhotspotmod.util.Services import kotlinx.parcelize.Parcelize import java.io.File import java.io.IOException diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/root/RootManager.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/root/RootManager.kt similarity index 91% rename from mobile/src/main/java/be/mygod/vpnhotspot/root/RootManager.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/root/RootManager.kt index b4f3baa1..9ea94369 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/root/RootManager.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/root/RootManager.kt @@ -1,12 +1,12 @@ -package be.mygod.vpnhotspot.root +package hanson.xyz.vpnhotspotmod.root import android.annotation.SuppressLint import android.os.Parcelable import android.util.Log import be.mygod.librootkotlinx.* -import be.mygod.vpnhotspot.App.Companion.app -import be.mygod.vpnhotspot.util.Services -import be.mygod.vpnhotspot.util.UnblockCentral +import hanson.xyz.vpnhotspotmod.App.Companion.app +import hanson.xyz.vpnhotspotmod.util.Services +import hanson.xyz.vpnhotspotmod.util.UnblockCentral import com.google.firebase.crashlytics.FirebaseCrashlytics import kotlinx.parcelize.Parcelize import timber.log.Timber diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/root/RoutingCommands.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/root/RoutingCommands.kt similarity index 96% rename from mobile/src/main/java/be/mygod/vpnhotspot/root/RoutingCommands.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/root/RoutingCommands.kt index 87b57535..ad523f6c 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/root/RoutingCommands.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/root/RoutingCommands.kt @@ -1,9 +1,9 @@ -package be.mygod.vpnhotspot.root +package hanson.xyz.vpnhotspotmod.root import android.os.Parcelable import be.mygod.librootkotlinx.RootCommand import be.mygod.librootkotlinx.RootCommandNoResult -import be.mygod.vpnhotspot.net.Routing +import hanson.xyz.vpnhotspotmod.net.Routing import kotlinx.coroutines.Dispatchers import kotlinx.coroutines.async import kotlinx.coroutines.coroutineScope diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/root/WifiApCommands.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/root/WifiApCommands.kt similarity index 97% rename from mobile/src/main/java/be/mygod/vpnhotspot/root/WifiApCommands.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/root/WifiApCommands.kt index 318ab08c..831c873e 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/root/WifiApCommands.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/root/WifiApCommands.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.root +package hanson.xyz.vpnhotspotmod.root import android.annotation.TargetApi import android.content.ClipData @@ -10,11 +10,11 @@ import androidx.annotation.RequiresApi import be.mygod.librootkotlinx.ParcelableBoolean import be.mygod.librootkotlinx.RootCommand import be.mygod.librootkotlinx.RootCommandChannel -import be.mygod.vpnhotspot.App.Companion.app -import be.mygod.vpnhotspot.R -import be.mygod.vpnhotspot.net.wifi.WifiApManager -import be.mygod.vpnhotspot.net.wifi.WifiClient -import be.mygod.vpnhotspot.widget.SmartSnackbar +import hanson.xyz.vpnhotspotmod.App.Companion.app +import hanson.xyz.vpnhotspotmod.R +import hanson.xyz.vpnhotspotmod.net.wifi.WifiApManager +import hanson.xyz.vpnhotspotmod.net.wifi.WifiClient +import hanson.xyz.vpnhotspotmod.widget.SmartSnackbar import kotlinx.coroutines.* import kotlinx.coroutines.channels.* import kotlinx.parcelize.Parcelize diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/util/AppUpdate.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/AppUpdate.kt similarity index 90% rename from mobile/src/main/java/be/mygod/vpnhotspot/util/AppUpdate.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/AppUpdate.kt index aacb9fa8..9862454e 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/util/AppUpdate.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/AppUpdate.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.util +package hanson.xyz.vpnhotspotmod.util import android.app.Activity diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/util/ConstantLookup.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/ConstantLookup.kt similarity index 94% rename from mobile/src/main/java/be/mygod/vpnhotspot/util/ConstantLookup.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/ConstantLookup.kt index 422a3ba0..f82b0a20 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/util/ConstantLookup.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/ConstantLookup.kt @@ -1,10 +1,10 @@ -package be.mygod.vpnhotspot.util +package hanson.xyz.vpnhotspotmod.util import android.os.Build import androidx.collection.LongSparseArray import androidx.collection.SparseArrayCompat -import be.mygod.vpnhotspot.App.Companion.app -import be.mygod.vpnhotspot.R +import hanson.xyz.vpnhotspotmod.App.Companion.app +import hanson.xyz.vpnhotspotmod.R import timber.log.Timber class ConstantLookup(private val prefix: String, private val lookup29: Array, diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/util/CustomTabsUrlSpan.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/CustomTabsUrlSpan.kt similarity index 83% rename from mobile/src/main/java/be/mygod/vpnhotspot/util/CustomTabsUrlSpan.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/CustomTabsUrlSpan.kt index ac08bb7c..c8b5b532 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/util/CustomTabsUrlSpan.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/CustomTabsUrlSpan.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.util +package hanson.xyz.vpnhotspotmod.util import android.text.style.URLSpan import android.view.View diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/util/DeviceStorageApp.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/DeviceStorageApp.kt similarity index 92% rename from mobile/src/main/java/be/mygod/vpnhotspot/util/DeviceStorageApp.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/DeviceStorageApp.kt index 2309fba4..6cffb33a 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/util/DeviceStorageApp.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/DeviceStorageApp.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.util +package hanson.xyz.vpnhotspotmod.util import android.annotation.SuppressLint import android.app.Application diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/util/Events.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/Events.kt similarity index 96% rename from mobile/src/main/java/be/mygod/vpnhotspot/util/Events.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/Events.kt index 68f38b7f..b8003825 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/util/Events.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/Events.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.util +package hanson.xyz.vpnhotspotmod.util import java.util.concurrent.ConcurrentHashMap diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/util/KillableTileService.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/KillableTileService.kt similarity index 92% rename from mobile/src/main/java/be/mygod/vpnhotspot/util/KillableTileService.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/KillableTileService.kt index ead7e063..bbe1e1e1 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/util/KillableTileService.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/KillableTileService.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.util +package hanson.xyz.vpnhotspotmod.util import android.content.ComponentName import android.content.Intent @@ -8,7 +8,7 @@ import android.os.DeadObjectException import android.os.IBinder import android.service.quicksettings.Tile import android.service.quicksettings.TileService -import be.mygod.vpnhotspot.BootReceiver +import hanson.xyz.vpnhotspotmod.BootReceiver abstract class KillableTileService : TileService(), ServiceConnection { protected var tapPending = false diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/util/QRCodeDialog.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/QRCodeDialog.kt similarity index 96% rename from mobile/src/main/java/be/mygod/vpnhotspot/util/QRCodeDialog.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/QRCodeDialog.kt index 61d4d27d..051ddbca 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/util/QRCodeDialog.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/QRCodeDialog.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.util +package hanson.xyz.vpnhotspotmod.util import android.graphics.Bitmap import android.graphics.Color @@ -9,7 +9,7 @@ import android.widget.ImageView import android.widget.Toast import androidx.core.os.bundleOf import androidx.fragment.app.DialogFragment -import be.mygod.vpnhotspot.R +import hanson.xyz.vpnhotspotmod.R import com.google.zxing.BarcodeFormat import com.google.zxing.EncodeHintType import com.google.zxing.MultiFormatWriter diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/util/RangeInput.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/RangeInput.kt similarity index 97% rename from mobile/src/main/java/be/mygod/vpnhotspot/util/RangeInput.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/RangeInput.kt index d14ae02d..899e218e 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/util/RangeInput.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/RangeInput.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.util +package hanson.xyz.vpnhotspotmod.util object RangeInput { fun toString(input: IntArray) = StringBuilder().apply { diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/util/RootSession.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/RootSession.kt similarity index 95% rename from mobile/src/main/java/be/mygod/vpnhotspot/util/RootSession.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/RootSession.kt index 8cad8b51..9926f359 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/util/RootSession.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/RootSession.kt @@ -1,8 +1,8 @@ -package be.mygod.vpnhotspot.util +package hanson.xyz.vpnhotspotmod.util import be.mygod.librootkotlinx.RootServer -import be.mygod.vpnhotspot.root.RootManager -import be.mygod.vpnhotspot.root.RoutingCommands +import hanson.xyz.vpnhotspotmod.root.RootManager +import hanson.xyz.vpnhotspotmod.root.RoutingCommands import kotlinx.coroutines.runBlocking import timber.log.Timber import java.util.* diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/util/ServiceForegroundConnector.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/ServiceForegroundConnector.kt similarity index 96% rename from mobile/src/main/java/be/mygod/vpnhotspot/util/ServiceForegroundConnector.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/ServiceForegroundConnector.kt index 03a93f3d..5068e7aa 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/util/ServiceForegroundConnector.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/ServiceForegroundConnector.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.util +package hanson.xyz.vpnhotspotmod.util import android.app.Service import android.content.Context diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/util/Services.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/Services.kt similarity index 96% rename from mobile/src/main/java/be/mygod/vpnhotspot/util/Services.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/Services.kt index 38ae4328..475c3382 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/util/Services.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/Services.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.util +package hanson.xyz.vpnhotspotmod.util import android.content.Context import android.net.ConnectivityManager diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/util/UnblockCentral.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/UnblockCentral.kt similarity index 97% rename from mobile/src/main/java/be/mygod/vpnhotspot/util/UnblockCentral.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/UnblockCentral.kt index b8e4c20b..386dbf2f 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/util/UnblockCentral.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/UnblockCentral.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.util +package hanson.xyz.vpnhotspotmod.util import android.annotation.SuppressLint import android.net.MacAddress diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/util/Utils.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/Utils.kt similarity index 98% rename from mobile/src/main/java/be/mygod/vpnhotspot/util/Utils.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/Utils.kt index a36f9f9a..9facb841 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/util/Utils.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/util/Utils.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.util +package hanson.xyz.vpnhotspotmod.util import android.annotation.SuppressLint import android.annotation.TargetApi @@ -22,9 +22,9 @@ import androidx.core.view.isVisible import androidx.databinding.BindingAdapter import androidx.fragment.app.DialogFragment import androidx.fragment.app.FragmentManager -import be.mygod.vpnhotspot.App.Companion.app -import be.mygod.vpnhotspot.net.MacAddressCompat -import be.mygod.vpnhotspot.widget.SmartSnackbar +import hanson.xyz.vpnhotspotmod.App.Companion.app +import hanson.xyz.vpnhotspotmod.net.MacAddressCompat +import hanson.xyz.vpnhotspotmod.widget.SmartSnackbar import kotlinx.coroutines.CancellationException import kotlinx.coroutines.Dispatchers import kotlinx.coroutines.GlobalScope diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/widget/AlwaysAutoCompleteEditText.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/widget/AlwaysAutoCompleteEditText.kt similarity index 95% rename from mobile/src/main/java/be/mygod/vpnhotspot/widget/AlwaysAutoCompleteEditText.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/widget/AlwaysAutoCompleteEditText.kt index de3e7cef..a3227c23 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/widget/AlwaysAutoCompleteEditText.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/widget/AlwaysAutoCompleteEditText.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.widget +package hanson.xyz.vpnhotspotmod.widget import android.content.Context import android.graphics.Rect diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/widget/AutoCollapseTextView.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/widget/AutoCollapseTextView.kt similarity index 93% rename from mobile/src/main/java/be/mygod/vpnhotspot/widget/AutoCollapseTextView.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/widget/AutoCollapseTextView.kt index ed6bde33..9e732fa5 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/widget/AutoCollapseTextView.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/widget/AutoCollapseTextView.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.widget +package hanson.xyz.vpnhotspotmod.widget import android.content.Context import android.util.AttributeSet diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/widget/LinkTextView.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/widget/LinkTextView.kt similarity index 94% rename from mobile/src/main/java/be/mygod/vpnhotspot/widget/LinkTextView.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/widget/LinkTextView.kt index 54915931..b1b9e856 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/widget/LinkTextView.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/widget/LinkTextView.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.widget +package hanson.xyz.vpnhotspotmod.widget import android.content.Context import android.text.method.LinkMovementMethod diff --git a/mobile/src/main/java/be/mygod/vpnhotspot/widget/SmartSnackbar.kt b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/widget/SmartSnackbar.kt similarity index 93% rename from mobile/src/main/java/be/mygod/vpnhotspot/widget/SmartSnackbar.kt rename to mobile/src/main/java/hanson/xyz/vpnhotspotmod/widget/SmartSnackbar.kt index 950872aa..4caef1dd 100644 --- a/mobile/src/main/java/be/mygod/vpnhotspot/widget/SmartSnackbar.kt +++ b/mobile/src/main/java/hanson/xyz/vpnhotspotmod/widget/SmartSnackbar.kt @@ -1,4 +1,4 @@ -package be.mygod.vpnhotspot.widget +package hanson.xyz.vpnhotspotmod.widget import android.annotation.SuppressLint import android.os.Looper @@ -8,8 +8,8 @@ import androidx.annotation.StringRes import androidx.lifecycle.DefaultLifecycleObserver import androidx.lifecycle.LifecycleOwner import androidx.lifecycle.findViewTreeLifecycleOwner -import be.mygod.vpnhotspot.App.Companion.app -import be.mygod.vpnhotspot.util.readableMessage +import hanson.xyz.vpnhotspotmod.App.Companion.app +import hanson.xyz.vpnhotspotmod.util.readableMessage import com.google.android.material.snackbar.Snackbar import java.util.concurrent.atomic.AtomicReference diff --git a/mobile/src/main/res/drawable/ic_launcher_background.xml b/mobile/src/main/res/drawable/ic_launcher_background.xml old mode 100755 new mode 100644 diff --git a/mobile/src/main/res/drawable/ic_launcher_foreground.xml b/mobile/src/main/res/drawable/ic_launcher_foreground.xml old mode 100755 new mode 100644 diff --git a/mobile/src/main/res/layout/activity_main.xml b/mobile/src/main/res/layout/activity_main.xml index aedb7a28..0c4c7e59 100644 --- a/mobile/src/main/res/layout/activity_main.xml +++ b/mobile/src/main/res/layout/activity_main.xml @@ -6,7 +6,7 @@ android:layout_width="match_parent" android:layout_height="match_parent" android:orientation="vertical" - tools:context="be.mygod.vpnhotspot.MainActivity"> + tools:context="hanson.xyz.vpnhotspotmod.MainActivity"> + type="hanson.xyz.vpnhotspotmod.client.Client"/> + type="hanson.xyz.vpnhotspotmod.client.ClientsFragment.TrafficRate"/> - - - + type="hanson.xyz.vpnhotspotmod.manage.Data"/> - + type="hanson.xyz.vpnhotspotmod.manage.ManageBar.Data"/> - + + type="hanson.xyz.vpnhotspotmod.manage.RepeaterManager.Data"/> - - - VPN Hotspot + VPN Hotspot MOD Repeater Tethering Clients diff --git a/mobile/src/main/res/xml/pref_settings.xml b/mobile/src/main/res/xml/pref_settings.xml index 2f796fbc..f9820314 100644 --- a/mobile/src/main/res/xml/pref_settings.xml +++ b/mobile/src/main/res/xml/pref_settings.xml @@ -7,7 +7,7 @@ app:summary="@string/settings_service_clean_summary"/> -