├── .github
└── FUNDING.yml
├── .gitignore
├── .gitmodules
├── .metadata
├── LICENSE
├── README.md
├── analysis_options.yaml
├── android
├── .gitignore
├── app
│ ├── build.gradle
│ └── src
│ │ ├── debug
│ │ ├── AndroidManifest.xml
│ │ └── res
│ │ │ ├── mipmap-hdpi
│ │ │ └── ic_launcher.png
│ │ │ ├── mipmap-ldpi
│ │ │ └── ic_launcher.png
│ │ │ ├── mipmap-mdpi
│ │ │ └── ic_launcher.png
│ │ │ ├── mipmap-xhdpi
│ │ │ └── ic_launcher.png
│ │ │ ├── mipmap-xxhdpi
│ │ │ └── ic_launcher.png
│ │ │ └── mipmap-xxxhdpi
│ │ │ └── ic_launcher.png
│ │ ├── main
│ │ ├── AndroidManifest.xml
│ │ ├── jniLibs
│ │ │ ├── arm64-v8a
│ │ │ │ ├── libopenssl.so
│ │ │ │ ├── libpython3.8.so
│ │ │ │ └── libtor.so
│ │ │ ├── armeabi-v7a
│ │ │ │ ├── libopenssl.so
│ │ │ │ ├── libpython3.8.so
│ │ │ │ └── libtor.so
│ │ │ ├── x86
│ │ │ │ ├── libopenssl.so
│ │ │ │ ├── libpython3.8.so
│ │ │ │ └── libtor.so
│ │ │ └── x86_64
│ │ │ │ ├── libopenssl.so
│ │ │ │ ├── libpython3.8.so
│ │ │ │ └── libtor.so
│ │ ├── kotlin
│ │ │ └── in
│ │ │ │ └── canews
│ │ │ │ └── zeronetmobile
│ │ │ │ ├── MainActivity.kt
│ │ │ │ └── MyApplication.kt
│ │ └── res
│ │ │ ├── drawable-anydpi-v24
│ │ │ └── ic_bg_service_small.xml
│ │ │ ├── drawable-hdpi
│ │ │ └── ic_bg_service_small.png
│ │ │ ├── drawable-mdpi
│ │ │ └── ic_bg_service_small.png
│ │ │ ├── drawable-v21
│ │ │ └── launch_background.xml
│ │ │ ├── drawable-xhdpi
│ │ │ └── ic_bg_service_small.png
│ │ │ ├── drawable-xxhdpi
│ │ │ └── ic_bg_service_small.png
│ │ │ ├── drawable
│ │ │ ├── app_icon.png
│ │ │ ├── launch_background.xml
│ │ │ └── logo.png
│ │ │ ├── mipmap-hdpi
│ │ │ └── ic_launcher.png
│ │ │ ├── mipmap-ldpi
│ │ │ └── ic_launcher.png
│ │ │ ├── mipmap-mdpi
│ │ │ └── ic_launcher.png
│ │ │ ├── mipmap-xhdpi
│ │ │ └── ic_launcher.png
│ │ │ ├── mipmap-xxhdpi
│ │ │ └── ic_launcher.png
│ │ │ ├── mipmap-xxxhdpi
│ │ │ └── ic_launcher.png
│ │ │ ├── values-night
│ │ │ └── styles.xml
│ │ │ ├── values
│ │ │ ├── strings.xml
│ │ │ └── styles.xml
│ │ │ └── xml
│ │ │ └── file_provider_paths.xml
│ │ └── profile
│ │ └── AndroidManifest.xml
├── arm
│ ├── .gitignore
│ ├── build.gradle
│ └── src
│ │ └── main
│ │ ├── AndroidManifest.xml
│ │ └── assets
│ │ └── site_packages_arm.zip
├── arm64
│ ├── .gitignore
│ ├── build.gradle
│ └── src
│ │ └── main
│ │ ├── AndroidManifest.xml
│ │ └── assets
│ │ └── site_packages_arm64.zip
├── arm64_tor
│ ├── .gitignore
│ ├── build.gradle
│ └── src
│ │ └── main
│ │ ├── AndroidManifest.xml
│ │ └── assets
│ │ └── tor_arm64.zip
├── arm_tor
│ ├── build.gradle
│ └── src
│ │ └── main
│ │ ├── AndroidManifest.xml
│ │ └── assets
│ │ └── tor_arm.zip
├── build.gradle
├── common
│ ├── .gitignore
│ ├── build.gradle
│ └── src
│ │ └── main
│ │ ├── AndroidManifest.xml
│ │ └── assets
│ │ └── zeronet_py3.zip
├── gradle.properties
├── gradle
│ └── wrapper
│ │ ├── gradle-wrapper.jar
│ │ └── gradle-wrapper.properties
├── gradlew
├── gradlew.bat
├── nativelibs_tor
│ ├── .gitignore
│ ├── build.gradle
│ └── src
│ │ └── main
│ │ ├── AndroidManifest.xml
│ │ └── jniLibs
│ │ ├── arm64-v8a
│ │ └── libtor.so
│ │ ├── armeabi-v7a
│ │ └── libtor.so
│ │ └── x86_64
│ │ └── libtor.so
├── settings.gradle
├── settings_aar.gradle
├── x86
│ ├── .gitignore
│ ├── build.gradle
│ └── src
│ │ └── main
│ │ ├── AndroidManifest.xml
│ │ └── assets
│ │ └── site_packages_x86.zip
├── x86_64
│ ├── .gitignore
│ ├── build.gradle
│ └── src
│ │ └── main
│ │ ├── AndroidManifest.xml
│ │ └── assets
│ │ └── site_packages_x86_64.zip
├── x86_64_tor
│ ├── .gitignore
│ ├── build.gradle
│ └── src
│ │ └── main
│ │ ├── AndroidManifest.xml
│ │ └── assets
│ │ └── tor_x86_64.zip
└── x86_tor
│ ├── .gitignore
│ ├── build.gradle
│ └── src
│ └── main
│ ├── AndroidManifest.xml
│ └── assets
│ └── tor_x86.zip
├── assets
├── app_icon.ico
├── developers
│ ├── canewsin.jpg
│ └── pramukesh.jpg
├── filters
│ ├── filters-tmp.json
│ ├── filters.json
│ ├── sites-miners.json
│ ├── sites-porn.json
│ ├── users-porn.json
│ └── users-spamlist.json
├── icons
│ ├── facebook.png
│ ├── facebook_dark.png
│ ├── github.png
│ ├── github_dark.png
│ ├── twitter.png
│ └── twitter_dark.png
└── logo.png
├── buildapk.bat
├── buildtools
├── compile.bat
└── utils.dart
├── fastlane
└── metadata
│ └── android
│ └── en-US
│ ├── changelogs
│ └── 70.txt
│ ├── full_description.txt
│ ├── images
│ ├── featureGraphic.png
│ ├── icon.png
│ └── phoneScreenshots
│ │ ├── 1.png
│ │ ├── 2.png
│ │ ├── 3.png
│ │ ├── 4.png
│ │ ├── 5.png
│ │ └── 6.png
│ ├── short_description.txt
│ ├── title.txt
│ └── video.txt
├── ios
├── .gitignore
├── Flutter
│ ├── AppFrameworkInfo.plist
│ ├── Debug.xcconfig
│ └── Release.xcconfig
├── Runner.xcodeproj
│ ├── project.pbxproj
│ ├── project.xcworkspace
│ │ ├── contents.xcworkspacedata
│ │ └── xcshareddata
│ │ │ ├── IDEWorkspaceChecks.plist
│ │ │ └── WorkspaceSettings.xcsettings
│ └── xcshareddata
│ │ └── xcschemes
│ │ └── Runner.xcscheme
├── Runner.xcworkspace
│ ├── contents.xcworkspacedata
│ └── xcshareddata
│ │ ├── IDEWorkspaceChecks.plist
│ │ └── WorkspaceSettings.xcsettings
└── Runner
│ ├── AppDelegate.swift
│ ├── Assets.xcassets
│ ├── AppIcon.appiconset
│ │ ├── Contents.json
│ │ ├── Icon-App-1024x1024@1x.png
│ │ ├── Icon-App-20x20@1x.png
│ │ ├── Icon-App-20x20@2x.png
│ │ ├── Icon-App-20x20@3x.png
│ │ ├── Icon-App-29x29@1x.png
│ │ ├── Icon-App-29x29@2x.png
│ │ ├── Icon-App-29x29@3x.png
│ │ ├── Icon-App-40x40@1x.png
│ │ ├── Icon-App-40x40@2x.png
│ │ ├── Icon-App-40x40@3x.png
│ │ ├── Icon-App-60x60@2x.png
│ │ ├── Icon-App-60x60@3x.png
│ │ ├── Icon-App-76x76@1x.png
│ │ ├── Icon-App-76x76@2x.png
│ │ └── Icon-App-83.5x83.5@2x.png
│ └── LaunchImage.imageset
│ │ ├── Contents.json
│ │ ├── LaunchImage.png
│ │ ├── LaunchImage@2x.png
│ │ ├── LaunchImage@3x.png
│ │ └── README.md
│ ├── Base.lproj
│ ├── LaunchScreen.storyboard
│ └── Main.storyboard
│ ├── Info.plist
│ └── Runner-Bridging-Header.h
├── lib
├── controllers
│ ├── strings.dart
│ ├── uicontroller.dart
│ └── varcontroller.dart
├── imports.dart
├── main.dart
├── models
│ ├── enums.dart
│ └── models.dart
├── others
│ ├── common.dart
│ ├── constants.dart
│ ├── extensions.dart
│ ├── native.dart
│ ├── utils.dart
│ ├── zeronet_isolate.dart
│ ├── zeronet_service.dart
│ └── zeronet_utils.dart
└── widgets
│ └── loading_page.dart
├── linux
├── .gitignore
├── CMakeLists.txt
├── flutter
│ ├── CMakeLists.txt
│ ├── generated_plugin_registrant.cc
│ ├── generated_plugin_registrant.h
│ └── generated_plugins.cmake
├── main.cc
├── my_application.cc
└── my_application.h
├── pubspec.yaml
├── shorebird.yaml
├── version.properties
└── windows
├── .gitignore
├── CMakeLists.txt
├── flutter
├── CMakeLists.txt
├── generated_plugin_registrant.cc
├── generated_plugin_registrant.h
└── generated_plugins.cmake
└── runner
├── CMakeLists.txt
├── Runner.rc
├── flutter_window.cpp
├── flutter_window.h
├── main.cpp
├── resource.h
├── resources
└── app_icon.ico
├── runner.exe.manifest
├── utils.cpp
├── utils.h
├── win32_window.cpp
└── win32_window.h
/.github/FUNDING.yml:
--------------------------------------------------------------------------------
1 | # These are supported funding model platforms
2 |
3 | github: canewsin
4 | patreon: # Replace with a single Patreon username e.g., user1
5 | open_collective: # Replace with a single Open Collective username e.g., user1
6 | ko_fi: canewsin
7 | tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
8 | community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
9 | liberapay: canewsin
10 | issuehunt: # Replace with a single IssueHunt username e.g., user1
11 | otechie: # Replace with a single Otechie username e.g., user1
12 | custom: ['https://paypal.me/PramUkesh']
13 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | # Miscellaneous
2 | *.class
3 | *.log
4 | *.pyc
5 | *.swp
6 | .DS_Store
7 | .atom/
8 | .buildlog/
9 | .history
10 | .svn/
11 |
12 | # IntelliJ related
13 | *.iml
14 | *.ipr
15 | *.iws
16 | .idea/
17 |
18 | # The .vscode folder contains launch configuration and tasks you configure in
19 | # VS Code which you may wish to be included in version control, so this line
20 | # is commented out by default.
21 | .vscode/
22 |
23 | # Flutter/Dart/Pub related
24 | **/doc/api/
25 | .dart_tool/
26 | .flutter-plugins
27 | .flutter-plugins-dependencies
28 | .packages
29 | .pub-cache/
30 | .pub/
31 | /build/
32 | libOld/
33 | .project
34 | .classpath
35 | *.prefs
36 | pubspec.lock
37 |
38 | # Web related
39 | lib/generated_plugin_registrant.dart
40 |
41 | # Exceptions to above rules.
42 | !/packages/flutter_tools/test/data/dart_dependencies_test/**/.packages
43 |
44 | # Android related
45 | # **/android/**/gradle-wrapper.jar
46 | **/android/.gradle
47 | **/android/captures/
48 | # **/android/gradlew
49 | # **/android/gradlew.bat
50 | **/android/local.properties
51 | **/android/key.properties
52 | **/android/**/GeneratedPluginRegistrant.java
53 |
54 | # iOS/XCode related
55 | **/ios/**/*.mode1v3
56 | **/ios/**/*.mode2v3
57 | **/ios/**/*.moved-aside
58 | **/ios/**/*.pbxuser
59 | **/ios/**/*.perspectivev3
60 | **/ios/**/*sync/
61 | **/ios/**/.sconsign.dblite
62 | **/ios/**/.tags*
63 | **/ios/**/.vagrant/
64 | **/ios/**/DerivedData/
65 | **/ios/**/Icon?
66 | **/ios/**/Pods/
67 | **/ios/**/.symlinks/
68 | **/ios/**/profile
69 | **/ios/**/xcuserdata
70 | **/ios/.generated/
71 | **/ios/Flutter/App.framework
72 | **/ios/Flutter/Flutter.framework
73 | **/ios/Flutter/Generated.xcconfig
74 | **/ios/Flutter/app.flx
75 | **/ios/Flutter/app.zip
76 | **/ios/Flutter/flutter_assets/
77 | **/ios/ServiceDefinitions.json
78 | **/ios/Runner/GeneratedPluginRegistrant.*
79 | **/macos/Flutter/GeneratedPluginRegistrant.*
80 | **/flutter_export_environment.sh
81 | **/Flutter-Generated.xcconfig
82 |
83 | # Exceptions to above rules.
84 | !**/ios/**/default.mode1v3
85 | !**/ios/**/default.mode2v3
86 | !**/ios/**/default.pbxuser
87 | !**/ios/**/default.perspectivev3
88 | !/packages/flutter_tools/test/data/dart_dependencies_test/**/.packages
89 |
90 |
--------------------------------------------------------------------------------
/.gitmodules:
--------------------------------------------------------------------------------
1 | [submodule "android/common_python"]
2 | path = android/common_python
3 | url = https://github.com/canewsin/common_python.git
4 | [submodule "android/arm_python"]
5 | path = android/arm_python
6 | url = https://github.com/canewsin/arm_python.git
7 | [submodule "android/arm64_python"]
8 | path = android/arm64_python
9 | url = https://github.com/canewsin/arm64_python.git
10 | [submodule "android/x86_64_python"]
11 | path = android/x86_64_python
12 | url = https://github.com/canewsin/x86_64_python.git
13 | [submodule "android/x86_python"]
14 | path = android/x86_python
15 | url = https://github.com/canewsin/x86_python.git
16 | [submodule "lib/dashboard"]
17 | path = lib/dashboard
18 | url = https://github.com/ZeroNetX/Dashboard-Engine.git
19 |
--------------------------------------------------------------------------------
/.metadata:
--------------------------------------------------------------------------------
1 | # This file tracks properties of this Flutter project.
2 | # Used by Flutter tool to assess capabilities and perform upgrades etc.
3 | #
4 | # This file should be version controlled.
5 |
6 | version:
7 | revision: 84a1e904f44f9b0e9c4510138010edcc653163f8
8 | channel: stable
9 |
10 | project_type: app
11 |
12 | # Tracks metadata for the flutter migrate command
13 | migration:
14 | platforms:
15 | - platform: root
16 | create_revision: 84a1e904f44f9b0e9c4510138010edcc653163f8
17 | base_revision: 84a1e904f44f9b0e9c4510138010edcc653163f8
18 | - platform: android
19 | create_revision: 84a1e904f44f9b0e9c4510138010edcc653163f8
20 | base_revision: 84a1e904f44f9b0e9c4510138010edcc653163f8
21 |
22 | # User provided section
23 |
24 | # List of Local paths (relative to this file) that should be
25 | # ignored by the migrate tool.
26 | #
27 | # Files that are not part of the templates will be ignored by default.
28 | unmanaged_files:
29 | - 'lib/main.dart'
30 | - 'ios/Runner.xcodeproj/project.pbxproj'
31 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # ZeroNet Mobile
2 | [](https://codemagic.io/apps/5f755f0647fecf7a4f25751a/5f75609747fecf958ea171b0/latest_build)
3 |
4 | ZeroNet Mobile is an Android Client for [ZeroNet](https://zeronet.dev), a platform for decentralized websites using Bitcoin crypto and the BitTorrent network. you can learn more about ZeroNet at https://zeronet.dev/.
5 |
6 | [
](https://play.google.com/store/apps/details?id=in.canews.zeronetmobile)
9 |
10 | ## Installation
11 |
12 | ### From Google PlayStore :
13 | #### Android (arm, arm64, x86)
14 | - minimum Android version supported 16 (JellyBean).
15 | - Google Play Store Link https://play.google.com/store/apps/details?id=in.canews.zeronetmobile
16 |
17 | #### Compiling Source :
18 |
19 | You need Flutter Framework to compile this App from Source.
20 |
21 | #### Installing Flutter : https://flutter.dev/docs/get-started/install
22 |
23 | ```
24 | git clone https://github.com/canewsin/zeronet_mobile.git
25 | cd zeronet_mobile
26 | flutter packages get
27 | ```
28 |
29 | After that create a file named `key.properties` in `android` directory
30 | and fill the below details, which are in capital letters, with your details.
31 | ```
32 | storeFile=ANDROID_KEY_STORE_FILE_PATH
33 | storePassword=KEY_STORE_PASSWORD
34 | keyAlias=KEY_ALIAS
35 | keyPassword=KEY_PASSWORD
36 | ```
37 |
38 | in root folder
39 |
40 | to build apk
41 | ```
42 | flutter build apk --no-shrink
43 | ```
44 |
45 | to build appbundle
46 | ```
47 | flutter build appbundle --no-shrink
48 | ```
49 |
50 | to run the app in Android Device / Emulator
51 |
52 | ```
53 | flutter run
54 | ```
55 |
56 | ## Donate
57 | BTC(Preferred) :
58 |
59 | `1ZeroNetyV5mKY9JF1gsm82TuBXHpfdLX`
60 |
61 | ETH :
62 |
63 | `0xa81a32dcce8e5bcb9792daa19ae7f964699ee536`
64 |
65 | UPI(Indian Users) :
66 |
67 | `pramukesh@upi`
68 |
69 | Liberapay :
70 |
71 | `https://liberapay.com/canews.in/donate`
72 |
73 | ## Contribute
74 | If you want to support project's further development, you can contribute your time or money, If you want to contribute money you can send bitcoin or other supported crypto currencies to above addresses or buy in-app purchases, if want to contribute translations or code.
75 |
--------------------------------------------------------------------------------
/analysis_options.yaml:
--------------------------------------------------------------------------------
1 | # This file configures the analyzer, which statically analyzes Dart code to
2 | # check for errors, warnings, and lints.
3 | #
4 | # The issues identified by the analyzer are surfaced in the UI of Dart-enabled
5 | # IDEs (https://dart.dev/tools#ides-and-editors). The analyzer can also be
6 | # invoked from the command line by running `flutter analyze`.
7 |
8 | # The following line activates a set of recommended lints for Flutter apps,
9 | # packages, and plugins designed to encourage good coding practices.
10 | #include: package:flutter_lints/flutter.yaml
11 |
12 | #linter:
13 | # The lint rules applied to this project can be customized in the
14 | # section below to disable rules from the `package:flutter_lints/flutter.yaml`
15 | # included above or to enable additional rules. A list of all available lints
16 | # and their documentation is published at
17 | # https://dart-lang.github.io/linter/lints/index.html.
18 | #
19 | # Instead of disabling a lint rule for the entire project in the
20 | # section below, it can also be suppressed for a single line of code
21 | # or a specific dart file by using the `// ignore: name_of_lint` and
22 | # `// ignore_for_file: name_of_lint` syntax on the line or in the file
23 | # producing the lint.
24 | #rules:
25 | # avoid_print: false # Uncomment to disable the `avoid_print` rule
26 | # prefer_single_quotes: true # Uncomment to enable the `prefer_single_quotes` rule
27 |
28 | # Additional information about this file can be found at
29 | # https://dart.dev/guides/language/analysis-options
30 |
--------------------------------------------------------------------------------
/android/.gitignore:
--------------------------------------------------------------------------------
1 | !gradle-wrapper.jar
2 | /.gradle
3 | /captures/
4 | # /gradlew
5 | # /gradlew.bat
6 | /local.properties
7 | GeneratedPluginRegistrant.java
8 | /build/
9 |
--------------------------------------------------------------------------------
/android/app/build.gradle:
--------------------------------------------------------------------------------
1 | def localProperties = new Properties()
2 | def localPropertiesFile = rootProject.file('local.properties')
3 | if (localPropertiesFile.exists()) {
4 | localPropertiesFile.withReader('UTF-8') { reader ->
5 | localProperties.load(reader)
6 | }
7 | }
8 |
9 | def versionProperties = new Properties()
10 | def versionPropertiesFile = rootProject.file('../version.properties')
11 | if (versionPropertiesFile.exists()) {
12 | versionPropertiesFile.withReader('UTF-8') { reader ->
13 | versionProperties.load(reader)
14 | }
15 | }
16 |
17 | def flutterRoot = localProperties.getProperty('flutter.sdk')
18 | if (flutterRoot == null) {
19 | throw new GradleException("Flutter SDK not found. Define location with flutter.sdk in the local.properties file.")
20 | }
21 |
22 | def flutterVersionCode = versionProperties.getProperty('flutter.versionCode')
23 | if (flutterVersionCode == null) {
24 | flutterVersionCode = '1'
25 | }
26 |
27 | def flutterVersionName = versionProperties.getProperty('flutter.versionName')
28 | if (flutterVersionName == null) {
29 | flutterVersionName = '1.0'
30 | }
31 | def keystoreProperties = new Properties()
32 | def keystorePropertiesFile = rootProject.file('key.properties')
33 | if (keystorePropertiesFile.exists()) {
34 | keystoreProperties.load(new FileInputStream(keystorePropertiesFile))
35 | }
36 | apply plugin: 'com.android.application'
37 | apply plugin: 'kotlin-android'
38 | apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle"
39 | apply plugin: 'com.jeppeman.locallydynamic'
40 |
41 | android {
42 | compileSdkVersion 34
43 |
44 | sourceSets {
45 | main.java.srcDirs += 'src/main/kotlin'
46 | }
47 |
48 | lintOptions {
49 | disable 'InvalidPackage'
50 | }
51 |
52 | defaultConfig {
53 | applicationId "in.canews.zeronetmobile"
54 | minSdkVersion 21
55 | targetSdkVersion 34
56 | versionCode flutterVersionCode.toInteger()
57 | versionName flutterVersionName
58 | testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
59 | manifestPlaceholders['foregroundServiceType'] = 'dataSync'
60 | }
61 |
62 | compileOptions {
63 | sourceCompatibility JavaVersion.VERSION_11
64 | targetCompatibility JavaVersion.VERSION_11
65 | }
66 |
67 | signingConfigs {
68 | release {
69 | keyAlias keystoreProperties['keyAlias']
70 | keyPassword keystoreProperties['keyPassword']
71 | storeFile file(keystoreProperties['storeFile'])
72 | storePassword keystoreProperties['storePassword']
73 | }
74 | }
75 |
76 | buildTypes {
77 |
78 | release {
79 | signingConfig signingConfigs.release
80 | minifyEnabled = false
81 | shrinkResources = false
82 | }
83 |
84 | debug {
85 | applicationIdSuffix '.debug'
86 | signingConfig signingConfigs.release
87 | locallyDynamic {
88 | enabled = false
89 | throttleDownloadBy = 1000
90 | }
91 | defaultConfig.ndk.abiFilters 'armeabi-v7a','arm64-v8a','x86_64'
92 | }
93 | }
94 | dynamicFeatures = [":arm64", ":arm", ":common", ":x86", ":x86_64",
95 | ":arm64_python", ":arm_python", ":common_python", ":x86_python", ":x86_64_python",
96 | ":arm64_tor", ":arm_tor", ":x86_tor", ":x86_64_tor"
97 | ]
98 |
99 |
100 | }
101 |
102 | flutter {
103 | source '../..'
104 | }
105 |
106 | dependencies {
107 | // def billing_version = '4.0.0'
108 | // implementation "com.android.billingclient:billing:$billing_version"
109 |
110 | def work_version = "2.7.0"
111 | // Force WorkManager 2.6.0 for transitive dependency
112 | implementation("androidx.work:work-runtime-ktx:$work_version") {
113 | force = true
114 | }
115 |
116 | implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
117 | implementation 'com.google.android.gms:play-services-base:17.6.0'
118 |
119 | //Duplicate Classes Issue https://stackoverflow.com/a/60492942
120 | // implementation 'com.google.guava:listenablefuture:9999.0-empty-to-avoid-conflict-with-guava'
121 |
122 | debugImplementation 'com.jeppeman.locallydynamic:locallydynamic-debug:0.3'
123 | releaseImplementation 'com.jeppeman.locallydynamic:locallydynamic:0.3'
124 |
125 | // testImplementation 'junit:junit:4.12'
126 | // androidTestImplementation 'androidx.test:runner:1.2.0'
127 | // androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0'
128 | }
129 |
--------------------------------------------------------------------------------
/android/app/src/debug/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
3 |
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/android/app/src/debug/res/mipmap-hdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/app/src/debug/res/mipmap-hdpi/ic_launcher.png
--------------------------------------------------------------------------------
/android/app/src/debug/res/mipmap-ldpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/app/src/debug/res/mipmap-ldpi/ic_launcher.png
--------------------------------------------------------------------------------
/android/app/src/debug/res/mipmap-mdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/app/src/debug/res/mipmap-mdpi/ic_launcher.png
--------------------------------------------------------------------------------
/android/app/src/debug/res/mipmap-xhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/app/src/debug/res/mipmap-xhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/android/app/src/debug/res/mipmap-xxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/app/src/debug/res/mipmap-xxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/android/app/src/debug/res/mipmap-xxxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/app/src/debug/res/mipmap-xxxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/android/app/src/main/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
5 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
27 |
35 |
36 |
37 |
38 |
39 |
40 |
43 |
45 |
48 |
51 |
56 |
57 |
61 |
62 |
63 |
64 |
65 |
--------------------------------------------------------------------------------
/android/app/src/main/jniLibs/arm64-v8a/libopenssl.so:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/app/src/main/jniLibs/arm64-v8a/libopenssl.so
--------------------------------------------------------------------------------
/android/app/src/main/jniLibs/arm64-v8a/libpython3.8.so:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/app/src/main/jniLibs/arm64-v8a/libpython3.8.so
--------------------------------------------------------------------------------
/android/app/src/main/jniLibs/arm64-v8a/libtor.so:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/app/src/main/jniLibs/arm64-v8a/libtor.so
--------------------------------------------------------------------------------
/android/app/src/main/jniLibs/armeabi-v7a/libopenssl.so:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/app/src/main/jniLibs/armeabi-v7a/libopenssl.so
--------------------------------------------------------------------------------
/android/app/src/main/jniLibs/armeabi-v7a/libpython3.8.so:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/app/src/main/jniLibs/armeabi-v7a/libpython3.8.so
--------------------------------------------------------------------------------
/android/app/src/main/jniLibs/armeabi-v7a/libtor.so:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/app/src/main/jniLibs/armeabi-v7a/libtor.so
--------------------------------------------------------------------------------
/android/app/src/main/jniLibs/x86/libopenssl.so:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/app/src/main/jniLibs/x86/libopenssl.so
--------------------------------------------------------------------------------
/android/app/src/main/jniLibs/x86/libpython3.8.so:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/app/src/main/jniLibs/x86/libpython3.8.so
--------------------------------------------------------------------------------
/android/app/src/main/jniLibs/x86/libtor.so:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/app/src/main/jniLibs/x86/libtor.so
--------------------------------------------------------------------------------
/android/app/src/main/jniLibs/x86_64/libopenssl.so:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/app/src/main/jniLibs/x86_64/libopenssl.so
--------------------------------------------------------------------------------
/android/app/src/main/jniLibs/x86_64/libpython3.8.so:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/app/src/main/jniLibs/x86_64/libpython3.8.so
--------------------------------------------------------------------------------
/android/app/src/main/jniLibs/x86_64/libtor.so:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/app/src/main/jniLibs/x86_64/libtor.so
--------------------------------------------------------------------------------
/android/app/src/main/kotlin/in/canews/zeronetmobile/MyApplication.kt:
--------------------------------------------------------------------------------
1 | package `in`.canews.zeronetmobile
2 |
3 | import android.app.Activity
4 | import android.content.Context
5 | import com.google.android.play.core.splitcompat.SplitCompat
6 | import com.google.android.play.core.splitcompat.SplitCompatApplication
7 | import io.flutter.FlutterInjector
8 |
9 |
10 | internal class MyApplication : SplitCompatApplication() {
11 |
12 | override fun onCreate() {
13 | super.onCreate()
14 | FlutterInjector.instance().flutterLoader().startInitialization(this)
15 | }
16 |
17 | private var mCurrentActivity: Activity? = null
18 |
19 | fun getCurrentActivity(): Activity? {
20 | return mCurrentActivity
21 | }
22 |
23 | fun setCurrentActivity(mCurrentActivity: Activity?) {
24 | this.mCurrentActivity = mCurrentActivity
25 | }
26 |
27 | override fun attachBaseContext(base: Context?) {
28 | super.attachBaseContext(base)
29 | SplitCompat.install(base!!)
30 | }
31 | }
32 |
--------------------------------------------------------------------------------
/android/app/src/main/res/drawable-anydpi-v24/ic_bg_service_small.xml:
--------------------------------------------------------------------------------
1 |
3 |
4 |
5 |
7 |
9 |
11 |
12 |
13 |
14 |
--------------------------------------------------------------------------------
/android/app/src/main/res/drawable-hdpi/ic_bg_service_small.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/app/src/main/res/drawable-hdpi/ic_bg_service_small.png
--------------------------------------------------------------------------------
/android/app/src/main/res/drawable-mdpi/ic_bg_service_small.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/app/src/main/res/drawable-mdpi/ic_bg_service_small.png
--------------------------------------------------------------------------------
/android/app/src/main/res/drawable-v21/launch_background.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | -
9 |
10 |
11 |
14 |
15 |
--------------------------------------------------------------------------------
/android/app/src/main/res/drawable-xhdpi/ic_bg_service_small.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/app/src/main/res/drawable-xhdpi/ic_bg_service_small.png
--------------------------------------------------------------------------------
/android/app/src/main/res/drawable-xxhdpi/ic_bg_service_small.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/app/src/main/res/drawable-xxhdpi/ic_bg_service_small.png
--------------------------------------------------------------------------------
/android/app/src/main/res/drawable/app_icon.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/app/src/main/res/drawable/app_icon.png
--------------------------------------------------------------------------------
/android/app/src/main/res/drawable/launch_background.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 | -
13 |
14 |
16 |
19 |
20 |
21 |
--------------------------------------------------------------------------------
/android/app/src/main/res/drawable/logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/app/src/main/res/drawable/logo.png
--------------------------------------------------------------------------------
/android/app/src/main/res/mipmap-hdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/app/src/main/res/mipmap-hdpi/ic_launcher.png
--------------------------------------------------------------------------------
/android/app/src/main/res/mipmap-ldpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/app/src/main/res/mipmap-ldpi/ic_launcher.png
--------------------------------------------------------------------------------
/android/app/src/main/res/mipmap-mdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/app/src/main/res/mipmap-mdpi/ic_launcher.png
--------------------------------------------------------------------------------
/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/android/app/src/main/res/values-night/styles.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
9 |
15 |
18 |
19 |
--------------------------------------------------------------------------------
/android/app/src/main/res/values/strings.xml:
--------------------------------------------------------------------------------
1 |
2 | Arm64 Binaries
3 | Arm Binaries
4 | Common Binaries
5 | x86 Binaries
6 | x86_64 Binaries
7 |
8 |
--------------------------------------------------------------------------------
/android/app/src/main/res/values/styles.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
8 |
9 |
--------------------------------------------------------------------------------
/android/app/src/main/res/xml/file_provider_paths.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
--------------------------------------------------------------------------------
/android/app/src/profile/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
3 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/android/arm/.gitignore:
--------------------------------------------------------------------------------
1 | /build
2 |
--------------------------------------------------------------------------------
/android/arm/build.gradle:
--------------------------------------------------------------------------------
1 | apply plugin: 'com.android.dynamic-feature'
2 |
3 | android {
4 | compileSdkVersion 31
5 |
6 |
7 | defaultConfig {
8 | minSdkVersion 21
9 |
10 | }
11 |
12 | compileOptions {
13 | sourceCompatibility JavaVersion.VERSION_11
14 | targetCompatibility JavaVersion.VERSION_11
15 | }
16 |
17 | }
18 |
19 | dependencies {
20 | implementation fileTree(dir: 'libs', include: ['*.jar'])
21 | implementation project(':app')
22 | }
23 |
--------------------------------------------------------------------------------
/android/arm/src/main/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
4 |
5 |
7 |
8 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/android/arm/src/main/assets/site_packages_arm.zip:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/arm/src/main/assets/site_packages_arm.zip
--------------------------------------------------------------------------------
/android/arm64/.gitignore:
--------------------------------------------------------------------------------
1 | /build
2 |
--------------------------------------------------------------------------------
/android/arm64/build.gradle:
--------------------------------------------------------------------------------
1 | apply plugin: 'com.android.dynamic-feature'
2 |
3 | android {
4 | compileSdkVersion 31
5 |
6 |
7 | defaultConfig {
8 | minSdkVersion 21
9 |
10 | }
11 |
12 | compileOptions {
13 | sourceCompatibility JavaVersion.VERSION_11
14 | targetCompatibility JavaVersion.VERSION_11
15 | }
16 |
17 | }
18 |
19 | dependencies {
20 | implementation fileTree(dir: 'libs', include: ['*.jar'])
21 | implementation project(':app')
22 | }
23 |
--------------------------------------------------------------------------------
/android/arm64/src/main/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
4 |
5 |
7 |
8 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/android/arm64/src/main/assets/site_packages_arm64.zip:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/arm64/src/main/assets/site_packages_arm64.zip
--------------------------------------------------------------------------------
/android/arm64_tor/.gitignore:
--------------------------------------------------------------------------------
1 | /build
2 |
--------------------------------------------------------------------------------
/android/arm64_tor/build.gradle:
--------------------------------------------------------------------------------
1 | apply plugin: 'com.android.dynamic-feature'
2 |
3 | android {
4 | compileSdkVersion 31
5 |
6 |
7 | defaultConfig {
8 | minSdkVersion 21
9 |
10 | }
11 |
12 | compileOptions {
13 | sourceCompatibility JavaVersion.VERSION_11
14 | targetCompatibility JavaVersion.VERSION_11
15 | }
16 |
17 | }
18 |
19 | dependencies {
20 | implementation fileTree(dir: 'libs', include: ['*.jar'])
21 | implementation project(':app')
22 | }
23 |
--------------------------------------------------------------------------------
/android/arm64_tor/src/main/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
4 |
5 |
7 |
8 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/android/arm64_tor/src/main/assets/tor_arm64.zip:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/arm64_tor/src/main/assets/tor_arm64.zip
--------------------------------------------------------------------------------
/android/arm_tor/build.gradle:
--------------------------------------------------------------------------------
1 | apply plugin: 'com.android.dynamic-feature'
2 |
3 | android {
4 | compileSdkVersion 31
5 |
6 |
7 | defaultConfig {
8 | minSdkVersion 21
9 |
10 | }
11 |
12 | compileOptions {
13 | sourceCompatibility JavaVersion.VERSION_11
14 | targetCompatibility JavaVersion.VERSION_11
15 | }
16 |
17 | }
18 |
19 | dependencies {
20 | implementation fileTree(dir: 'libs', include: ['*.jar'])
21 | implementation project(':app')
22 | }
23 |
--------------------------------------------------------------------------------
/android/arm_tor/src/main/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
4 |
5 |
7 |
8 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/android/arm_tor/src/main/assets/tor_arm.zip:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/arm_tor/src/main/assets/tor_arm.zip
--------------------------------------------------------------------------------
/android/build.gradle:
--------------------------------------------------------------------------------
1 | buildscript {
2 | ext.kotlin_version = '1.8.10'
3 | ext.gradle_version = '7.4.2'
4 | repositories {
5 | google()
6 | maven {
7 | url "https://plugins.gradle.org/m2"
8 | }
9 | }
10 |
11 | dependencies {
12 | classpath "com.android.tools.build:gradle:$gradle_version"
13 | classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
14 | classpath "com.jeppeman.locallydynamic.gradle:plugin:0.2"
15 | }
16 | }
17 |
18 | allprojects {
19 | repositories {
20 | google()
21 | }
22 | }
23 |
24 | rootProject.buildDir = '../build'
25 | subprojects {
26 | project.buildDir = "${rootProject.buildDir}/${project.name}"
27 | }
28 | subprojects {
29 | project.evaluationDependsOn(':app')
30 | }
31 |
32 | tasks.register("clean", Delete) {
33 | delete rootProject.buildDir
34 | }
35 |
--------------------------------------------------------------------------------
/android/common/.gitignore:
--------------------------------------------------------------------------------
1 | /build
2 |
--------------------------------------------------------------------------------
/android/common/build.gradle:
--------------------------------------------------------------------------------
1 | apply plugin: 'com.android.dynamic-feature'
2 |
3 | android {
4 | compileSdkVersion 31
5 |
6 |
7 | defaultConfig {
8 | minSdkVersion 21
9 |
10 | }
11 |
12 | compileOptions {
13 | sourceCompatibility JavaVersion.VERSION_11
14 | targetCompatibility JavaVersion.VERSION_11
15 | }
16 |
17 | }
18 |
19 | dependencies {
20 | implementation fileTree(dir: 'libs', include: ['*.jar'])
21 | implementation project(':app')
22 | }
23 |
--------------------------------------------------------------------------------
/android/common/src/main/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
4 |
5 |
7 |
8 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/android/common/src/main/assets/zeronet_py3.zip:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/common/src/main/assets/zeronet_py3.zip
--------------------------------------------------------------------------------
/android/gradle.properties:
--------------------------------------------------------------------------------
1 | org.gradle.jvmargs=-Xmx4096M
2 | # TODO : Once Binaries are compiled with new NDK than NDK 21 RC1
3 | # we can remove below uncompressed property
4 | # https://stackoverflow.com/a/55969995
5 | android.bundle.enableUncompressedNativeLibs=false
6 | android.experimental.enableNewResourceShrinker=true
7 | android.enableR8=true
8 | android.useAndroidX=true
9 | android.enableJetifier=true
10 |
--------------------------------------------------------------------------------
/android/gradle/wrapper/gradle-wrapper.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/gradle/wrapper/gradle-wrapper.jar
--------------------------------------------------------------------------------
/android/gradle/wrapper/gradle-wrapper.properties:
--------------------------------------------------------------------------------
1 | distributionBase=GRADLE_USER_HOME
2 | distributionPath=wrapper/dists
3 | zipStoreBase=GRADLE_USER_HOME
4 | zipStorePath=wrapper/dists
5 | distributionUrl=https\://services.gradle.org/distributions/gradle-7.5-all.zip
6 |
--------------------------------------------------------------------------------
/android/gradlew:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env bash
2 |
3 | ##############################################################################
4 | ##
5 | ## Gradle start up script for UN*X
6 | ##
7 | ##############################################################################
8 |
9 | # Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
10 | DEFAULT_JVM_OPTS=""
11 |
12 | APP_NAME="Gradle"
13 | APP_BASE_NAME=`basename "$0"`
14 |
15 | # Use the maximum available, or set MAX_FD != -1 to use that value.
16 | MAX_FD="maximum"
17 |
18 | warn ( ) {
19 | echo "$*"
20 | }
21 |
22 | die ( ) {
23 | echo
24 | echo "$*"
25 | echo
26 | exit 1
27 | }
28 |
29 | # OS specific support (must be 'true' or 'false').
30 | cygwin=false
31 | msys=false
32 | darwin=false
33 | case "`uname`" in
34 | CYGWIN* )
35 | cygwin=true
36 | ;;
37 | Darwin* )
38 | darwin=true
39 | ;;
40 | MINGW* )
41 | msys=true
42 | ;;
43 | esac
44 |
45 | # Attempt to set APP_HOME
46 | # Resolve links: $0 may be a link
47 | PRG="$0"
48 | # Need this for relative symlinks.
49 | while [ -h "$PRG" ] ; do
50 | ls=`ls -ld "$PRG"`
51 | link=`expr "$ls" : '.*-> \(.*\)$'`
52 | if expr "$link" : '/.*' > /dev/null; then
53 | PRG="$link"
54 | else
55 | PRG=`dirname "$PRG"`"/$link"
56 | fi
57 | done
58 | SAVED="`pwd`"
59 | cd "`dirname \"$PRG\"`/" >/dev/null
60 | APP_HOME="`pwd -P`"
61 | cd "$SAVED" >/dev/null
62 |
63 | CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
64 |
65 | # Determine the Java command to use to start the JVM.
66 | if [ -n "$JAVA_HOME" ] ; then
67 | if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
68 | # IBM's JDK on AIX uses strange locations for the executables
69 | JAVACMD="$JAVA_HOME/jre/sh/java"
70 | else
71 | JAVACMD="$JAVA_HOME/bin/java"
72 | fi
73 | if [ ! -x "$JAVACMD" ] ; then
74 | die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME
75 |
76 | Please set the JAVA_HOME variable in your environment to match the
77 | location of your Java installation."
78 | fi
79 | else
80 | JAVACMD="java"
81 | which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
82 |
83 | Please set the JAVA_HOME variable in your environment to match the
84 | location of your Java installation."
85 | fi
86 |
87 | # Increase the maximum file descriptors if we can.
88 | if [ "$cygwin" = "false" -a "$darwin" = "false" ] ; then
89 | MAX_FD_LIMIT=`ulimit -H -n`
90 | if [ $? -eq 0 ] ; then
91 | if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then
92 | MAX_FD="$MAX_FD_LIMIT"
93 | fi
94 | ulimit -n $MAX_FD
95 | if [ $? -ne 0 ] ; then
96 | warn "Could not set maximum file descriptor limit: $MAX_FD"
97 | fi
98 | else
99 | warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT"
100 | fi
101 | fi
102 |
103 | # For Darwin, add options to specify how the application appears in the dock
104 | if $darwin; then
105 | GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\""
106 | fi
107 |
108 | # For Cygwin, switch paths to Windows format before running java
109 | if $cygwin ; then
110 | APP_HOME=`cygpath --path --mixed "$APP_HOME"`
111 | CLASSPATH=`cygpath --path --mixed "$CLASSPATH"`
112 | JAVACMD=`cygpath --unix "$JAVACMD"`
113 |
114 | # We build the pattern for arguments to be converted via cygpath
115 | ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null`
116 | SEP=""
117 | for dir in $ROOTDIRSRAW ; do
118 | ROOTDIRS="$ROOTDIRS$SEP$dir"
119 | SEP="|"
120 | done
121 | OURCYGPATTERN="(^($ROOTDIRS))"
122 | # Add a user-defined pattern to the cygpath arguments
123 | if [ "$GRADLE_CYGPATTERN" != "" ] ; then
124 | OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)"
125 | fi
126 | # Now convert the arguments - kludge to limit ourselves to /bin/sh
127 | i=0
128 | for arg in "$@" ; do
129 | CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -`
130 | CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option
131 |
132 | if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition
133 | eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"`
134 | else
135 | eval `echo args$i`="\"$arg\""
136 | fi
137 | i=$((i+1))
138 | done
139 | case $i in
140 | (0) set -- ;;
141 | (1) set -- "$args0" ;;
142 | (2) set -- "$args0" "$args1" ;;
143 | (3) set -- "$args0" "$args1" "$args2" ;;
144 | (4) set -- "$args0" "$args1" "$args2" "$args3" ;;
145 | (5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;;
146 | (6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;;
147 | (7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;;
148 | (8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;;
149 | (9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;;
150 | esac
151 | fi
152 |
153 | # Split up the JVM_OPTS And GRADLE_OPTS values into an array, following the shell quoting and substitution rules
154 | function splitJvmOpts() {
155 | JVM_OPTS=("$@")
156 | }
157 | eval splitJvmOpts $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS
158 | JVM_OPTS[${#JVM_OPTS[*]}]="-Dorg.gradle.appname=$APP_BASE_NAME"
159 |
160 | exec "$JAVACMD" "${JVM_OPTS[@]}" -classpath "$CLASSPATH" org.gradle.wrapper.GradleWrapperMain "$@"
161 |
--------------------------------------------------------------------------------
/android/gradlew.bat:
--------------------------------------------------------------------------------
1 | @if "%DEBUG%" == "" @echo off
2 | @rem ##########################################################################
3 | @rem
4 | @rem Gradle startup script for Windows
5 | @rem
6 | @rem ##########################################################################
7 |
8 | @rem Set local scope for the variables with windows NT shell
9 | if "%OS%"=="Windows_NT" setlocal
10 |
11 | @rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
12 | set DEFAULT_JVM_OPTS=
13 |
14 | set DIRNAME=%~dp0
15 | if "%DIRNAME%" == "" set DIRNAME=.
16 | set APP_BASE_NAME=%~n0
17 | set APP_HOME=%DIRNAME%
18 |
19 | @rem Find java.exe
20 | if defined JAVA_HOME goto findJavaFromJavaHome
21 |
22 | set JAVA_EXE=java.exe
23 | %JAVA_EXE% -version >NUL 2>&1
24 | if "%ERRORLEVEL%" == "0" goto init
25 |
26 | echo.
27 | echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
28 | echo.
29 | echo Please set the JAVA_HOME variable in your environment to match the
30 | echo location of your Java installation.
31 |
32 | goto fail
33 |
34 | :findJavaFromJavaHome
35 | set JAVA_HOME=%JAVA_HOME:"=%
36 | set JAVA_EXE=%JAVA_HOME%/bin/java.exe
37 |
38 | if exist "%JAVA_EXE%" goto init
39 |
40 | echo.
41 | echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
42 | echo.
43 | echo Please set the JAVA_HOME variable in your environment to match the
44 | echo location of your Java installation.
45 |
46 | goto fail
47 |
48 | :init
49 | @rem Get command-line arguments, handling Windowz variants
50 |
51 | if not "%OS%" == "Windows_NT" goto win9xME_args
52 | if "%@eval[2+2]" == "4" goto 4NT_args
53 |
54 | :win9xME_args
55 | @rem Slurp the command line arguments.
56 | set CMD_LINE_ARGS=
57 | set _SKIP=2
58 |
59 | :win9xME_args_slurp
60 | if "x%~1" == "x" goto execute
61 |
62 | set CMD_LINE_ARGS=%*
63 | goto execute
64 |
65 | :4NT_args
66 | @rem Get arguments from the 4NT Shell from JP Software
67 | set CMD_LINE_ARGS=%$
68 |
69 | :execute
70 | @rem Setup the command line
71 |
72 | set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
73 |
74 | @rem Execute Gradle
75 | "%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS%
76 |
77 | :end
78 | @rem End local scope for the variables with windows NT shell
79 | if "%ERRORLEVEL%"=="0" goto mainEnd
80 |
81 | :fail
82 | rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
83 | rem the _cmd.exe /c_ return code!
84 | if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1
85 | exit /b 1
86 |
87 | :mainEnd
88 | if "%OS%"=="Windows_NT" endlocal
89 |
90 | :omega
91 |
--------------------------------------------------------------------------------
/android/nativelibs_tor/.gitignore:
--------------------------------------------------------------------------------
1 | /build
2 |
--------------------------------------------------------------------------------
/android/nativelibs_tor/build.gradle:
--------------------------------------------------------------------------------
1 | apply plugin: 'com.android.dynamic-feature'
2 |
3 | android {
4 | compileSdkVersion 29
5 |
6 |
7 | defaultConfig {
8 | minSdkVersion 21
9 |
10 | }
11 |
12 | compileOptions {
13 | sourceCompatibility JavaVersion.VERSION_11
14 | targetCompatibility JavaVersion.VERSION_11
15 | }
16 |
17 | }
18 |
19 | dependencies {
20 | implementation fileTree(dir: 'libs', include: ['*.jar'])
21 | implementation project(':app')
22 | }
23 |
--------------------------------------------------------------------------------
/android/nativelibs_tor/src/main/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
4 |
5 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
--------------------------------------------------------------------------------
/android/nativelibs_tor/src/main/jniLibs/arm64-v8a/libtor.so:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/nativelibs_tor/src/main/jniLibs/arm64-v8a/libtor.so
--------------------------------------------------------------------------------
/android/nativelibs_tor/src/main/jniLibs/armeabi-v7a/libtor.so:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/nativelibs_tor/src/main/jniLibs/armeabi-v7a/libtor.so
--------------------------------------------------------------------------------
/android/nativelibs_tor/src/main/jniLibs/x86_64/libtor.so:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/nativelibs_tor/src/main/jniLibs/x86_64/libtor.so
--------------------------------------------------------------------------------
/android/settings.gradle:
--------------------------------------------------------------------------------
1 | include ':app'
2 | include ':common'
3 | include ':arm64'
4 | include ':arm'
5 | include ':x86'
6 | include ':x86_64'
7 | include ':common_python'
8 | include ':arm64_python'
9 | include ':arm_python'
10 | include ':x86_python'
11 | include ':x86_64_python'
12 | include ':arm64_tor'
13 | include ':arm_tor'
14 | include ':x86_tor'
15 | include ':x86_64_tor'
16 |
17 | def flutterProjectRoot = rootProject.projectDir.parentFile.toPath()
18 |
19 | def plugins = new Properties()
20 | def pluginsFile = new File(flutterProjectRoot.toFile(), '.flutter-plugins')
21 | if (pluginsFile.exists()) {
22 | pluginsFile.withReader('UTF-8') { reader -> plugins.load(reader) }
23 | }
24 |
25 | plugins.each { name, path ->
26 | def pluginDirectory = flutterProjectRoot.resolve(path).resolve('android').toFile()
27 | include ":$name"
28 | project(":$name").projectDir = pluginDirectory
29 | }
30 |
--------------------------------------------------------------------------------
/android/settings_aar.gradle:
--------------------------------------------------------------------------------
1 | include ':app'
2 |
--------------------------------------------------------------------------------
/android/x86/.gitignore:
--------------------------------------------------------------------------------
1 | /build
2 |
--------------------------------------------------------------------------------
/android/x86/build.gradle:
--------------------------------------------------------------------------------
1 | apply plugin: 'com.android.dynamic-feature'
2 |
3 | android {
4 | compileSdkVersion 31
5 |
6 |
7 | defaultConfig {
8 | minSdkVersion 21
9 |
10 | }
11 |
12 | compileOptions {
13 | sourceCompatibility JavaVersion.VERSION_11
14 | targetCompatibility JavaVersion.VERSION_11
15 | }
16 |
17 | }
18 |
19 | dependencies {
20 | implementation fileTree(dir: 'libs', include: ['*.jar'])
21 | implementation project(':app')
22 | }
23 |
--------------------------------------------------------------------------------
/android/x86/src/main/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
4 |
5 |
7 |
8 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/android/x86/src/main/assets/site_packages_x86.zip:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/x86/src/main/assets/site_packages_x86.zip
--------------------------------------------------------------------------------
/android/x86_64/.gitignore:
--------------------------------------------------------------------------------
1 | /build
2 |
--------------------------------------------------------------------------------
/android/x86_64/build.gradle:
--------------------------------------------------------------------------------
1 | apply plugin: 'com.android.dynamic-feature'
2 |
3 | android {
4 | compileSdkVersion 31
5 |
6 |
7 | defaultConfig {
8 | minSdkVersion 21
9 |
10 | }
11 |
12 | compileOptions {
13 | sourceCompatibility JavaVersion.VERSION_11
14 | targetCompatibility JavaVersion.VERSION_11
15 | }
16 |
17 | }
18 |
19 | dependencies {
20 | implementation fileTree(dir: 'libs', include: ['*.jar'])
21 | implementation project(':app')
22 | }
23 |
--------------------------------------------------------------------------------
/android/x86_64/src/main/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
4 |
5 |
7 |
8 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/android/x86_64/src/main/assets/site_packages_x86_64.zip:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/x86_64/src/main/assets/site_packages_x86_64.zip
--------------------------------------------------------------------------------
/android/x86_64_tor/.gitignore:
--------------------------------------------------------------------------------
1 | /build
2 |
--------------------------------------------------------------------------------
/android/x86_64_tor/build.gradle:
--------------------------------------------------------------------------------
1 | apply plugin: 'com.android.dynamic-feature'
2 |
3 | android {
4 | compileSdkVersion 31
5 |
6 |
7 | defaultConfig {
8 | minSdkVersion 21
9 |
10 | }
11 |
12 | compileOptions {
13 | sourceCompatibility JavaVersion.VERSION_11
14 | targetCompatibility JavaVersion.VERSION_11
15 | }
16 |
17 | }
18 |
19 | dependencies {
20 | implementation fileTree(dir: 'libs', include: ['*.jar'])
21 | implementation project(':app')
22 | }
23 |
--------------------------------------------------------------------------------
/android/x86_64_tor/src/main/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
4 |
5 |
7 |
8 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/android/x86_64_tor/src/main/assets/tor_x86_64.zip:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/x86_64_tor/src/main/assets/tor_x86_64.zip
--------------------------------------------------------------------------------
/android/x86_tor/.gitignore:
--------------------------------------------------------------------------------
1 | /build
2 |
--------------------------------------------------------------------------------
/android/x86_tor/build.gradle:
--------------------------------------------------------------------------------
1 | apply plugin: 'com.android.dynamic-feature'
2 |
3 | android {
4 | compileSdkVersion 31
5 |
6 |
7 | defaultConfig {
8 | minSdkVersion 21
9 |
10 | }
11 |
12 | compileOptions {
13 | sourceCompatibility JavaVersion.VERSION_11
14 | targetCompatibility JavaVersion.VERSION_11
15 | }
16 |
17 | }
18 |
19 | dependencies {
20 | implementation fileTree(dir: 'libs', include: ['*.jar'])
21 | implementation project(':app')
22 | }
23 |
--------------------------------------------------------------------------------
/android/x86_tor/src/main/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
4 |
5 |
7 |
8 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/android/x86_tor/src/main/assets/tor_x86.zip:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/android/x86_tor/src/main/assets/tor_x86.zip
--------------------------------------------------------------------------------
/assets/app_icon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/assets/app_icon.ico
--------------------------------------------------------------------------------
/assets/developers/canewsin.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/assets/developers/canewsin.jpg
--------------------------------------------------------------------------------
/assets/developers/pramukesh.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/assets/developers/pramukesh.jpg
--------------------------------------------------------------------------------
/assets/filters/filters-tmp.json:
--------------------------------------------------------------------------------
1 | {
2 | "includes": {
3 | "tmp/filters/sites-porn.json": {
4 | "address": "tmp",
5 | "date_added": 1604971003.9685245,
6 | "description": "Porn Sites",
7 | "inner_path": "filters/sites-porn.json"
8 | },
9 | "tmp/filters/sites-miners.json": {
10 | "address": "tmp",
11 | "date_added": 1604972074.2051556,
12 | "description": "Crypto Miner Sites",
13 | "inner_path": "filters/sites-miners.json"
14 | },
15 | "tmp/filters/users-porn.json": {
16 | "address": "tmp",
17 | "date_added": 1604970823.2421556,
18 | "description": "Users Who Post Porn on Social Media",
19 | "inner_path": "filters/users-porn.json"
20 | },
21 | "tmp/filters/users-spamlist.json": {
22 | "address": "tmp",
23 | "date_added": 1604971226.4319663,
24 | "description": "Users Who Post Spam",
25 | "inner_path": "filters/users-spamlist.json"
26 | }
27 | },
28 | "mutes": {},
29 | "siteblocks": {}
30 | }
--------------------------------------------------------------------------------
/assets/filters/filters.json:
--------------------------------------------------------------------------------
1 | {
2 | "includes": {
3 | "15UYrA7aXr2Nto1Gg4yWXpY3EAJwafMTNk/filters/sites-porn.json": {
4 | "address": "15UYrA7aXr2Nto1Gg4yWXpY3EAJwafMTNk",
5 | "date_added": 1604971003.9685245,
6 | "description": "Porn Sites",
7 | "inner_path": "filters/sites-porn.json"
8 | },
9 | "15UYrA7aXr2Nto1Gg4yWXpY3EAJwafMTNk/filters/sites-miners.json": {
10 | "address": "15UYrA7aXr2Nto1Gg4yWXpY3EAJwafMTNk",
11 | "date_added": 1604972074.2051556,
12 | "description": "Crypto Miner Sites",
13 | "inner_path": "filters/sites-miners.json"
14 | },
15 | "15UYrA7aXr2Nto1Gg4yWXpY3EAJwafMTNk/filters/users-porn.json": {
16 | "address": "15UYrA7aXr2Nto1Gg4yWXpY3EAJwafMTNk",
17 | "date_added": 1604970823.2421556,
18 | "description": "Users Who Post Porn on Social Media",
19 | "inner_path": "filters/users-porn.json"
20 | },
21 | "15UYrA7aXr2Nto1Gg4yWXpY3EAJwafMTNk/filters/users-spamlist.json": {
22 | "address": "15UYrA7aXr2Nto1Gg4yWXpY3EAJwafMTNk",
23 | "date_added": 1604971226.4319663,
24 | "description": "Users Who Post Spam",
25 | "inner_path": "filters/users-spamlist.json"
26 | }
27 | },
28 | "mutes": {},
29 | "siteblocks": {}
30 | }
--------------------------------------------------------------------------------
/assets/filters/sites-miners.json:
--------------------------------------------------------------------------------
1 | {
2 | "siteblocks": {
3 | "13eFkhbXXQcJqd729zRLL9tMxxhz9d4UA6": {
4 | "date_added": 1530012785,
5 | "name": "EulerFinder",
6 | "reason": "Includes calls to online coinhive script(with option to disable but sets to 50% on refresh)"
7 | },
8 | "1PXUne5szFdu4di5EV4gy9Qo7p8tP5p1VX": {
9 | "date_added": 1530012785,
10 | "name": "The Pedophile/Rapist Hitlist",
11 | "reason": "Includes an offline script(/js/coinhive.min.js)"
12 | },
13 | "1JArw6Qb7cG6NuZBqvBSprURr2aaZdCFq9": {
14 | "date_added": 1541928660,
15 | "name": "C&P Zite Index",
16 | "reason": "Includes an online coinhive script and anti adblock(BlockAdBlock)"
17 | },
18 | "1CS9y8BCXC7iXTqDMaYnwN9br8WaRbUeJV": {
19 | "date_added": 1541928660,
20 | "name": "C&P Video Share",
21 | "reason": "Includes an online coinhive script and anti adblock(BlockAdBlock)"
22 | },
23 | "13WfLQv2nWXYBNUEL3PkWwGUe3H7qkTF5Y": {
24 | "date_added": 1541928660,
25 | "name": "C&P Forum",
26 | "reason": "Includes an online coinhive script and anti adblock(BlockAdBlock)"
27 | },
28 | "14YK7V93HNLJb94PFrKj4aQMxPVkrbZ3oL": {
29 | "date_added": 1541928660,
30 | "name": "C&P File Share",
31 | "reason": "Includes an online coinhive script and anti adblock(BlockAdBlock)"
32 | },
33 | "1RuLFAr8pJMdwMWaLfp5X5ousDZHXv8K4": {
34 | "date_added": 1541928660,
35 | "name": "The Chlorates and Perchlorates",
36 | "reason": "Includes an online coinhive script and anti adblock(BlockAdBlock)"
37 | },
38 | "16AzWR6xfhVvrmvQCm4mt7rN17CWZTCJYS": {
39 | "date_added": 1541928660,
40 | "name": "Receptek Sufnipirotechnikusoknak",
41 | "reason": "Includes an online coinhive script"
42 | },
43 | "1CpAXQVfedrNVKSLJMKEtrWNvU8KMXJzAt": {
44 | "date_added": 1541928660,
45 | "name": "PyroMaster minden ami érdekes",
46 | "reason": "Includes anti adblock(BlockAdBlock) suspiciously no coinhive (note to self: check and remove latter)"
47 | },
48 | "16WRGSqD26sfYiVBsBQg6y1Sd3YJP6Q3SF": {
49 | "date_added": 1542661064,
50 | "name": "PyroData & PyroGuide",
51 | "reason": "Includes an online coinhive script and anti adblock(BlockAdBlock)"
52 | },
53 | "1KjLxJ6TfeRvrPX1LkUtkFLfTp4en7j9uf": {
54 | "date_added": 1541928660,
55 | "name": "???",
56 | "reason": "[sourced by tips of others](todo actually check it when it loads)Includes an online coinhive script"
57 | }
58 | }
59 | }
--------------------------------------------------------------------------------
/assets/filters/users-porn.json:
--------------------------------------------------------------------------------
1 | {
2 | "mutes": {
3 | "17TFi7VtcyxehZB8JUN43trfr5hkjnoHsc": {
4 | "cert_user_id": "foxtrot@zeroid.bit",
5 | "date_added": 1,
6 | "reason": "Pornography content poster on ZeroMe",
7 | "source": "ZeroMe"
8 | },
9 | "1DCJkxufYgBd8pj8VnkVXaGUCBJiq8g9ai": {
10 | "cert_user_id": "kheyflix@zeroid.bit",
11 | "date_added": 1,
12 | "reason": "Pornography content poster on ZeroMe",
13 | "source": "ZeroMe"
14 | },
15 | "1HSJXS26WAFxab3etLidavpj5zki3bC1Pm": {
16 | "cert_user_id": "tumbleweed@zeroid.bit",
17 | "date_added": 1,
18 | "source": "ZeroMe",
19 | "reason": "Long term pornography content poster on ZeroMe site. Unsure about his activities on other sites."
20 | },
21 | "1AXWniok4qHQTGgP9szgQuQfXe9VxZXLwi": {
22 | "cert_user_id": "colkurtz@zeroid.bit",
23 | "date_added": 1,
24 | "source": "ZeroMe",
25 | "reason": "Long term pornography content poster on ZeroMe site. Unsure about his activities on other sites."
26 | },
27 | "1FzppM7Wv3LTgRLqApEBaSkr51QDJki8nJ": {
28 | "cert_user_id": "bite@zeroid.bit",
29 | "date_added": 1,
30 | "source": "ZeroMe",
31 | "reason": "Pornography content poster on ZeroMe site. Unsure about his activities on other sites, seen no other content from him."
32 | },
33 | "13qMquPdWJ59qDHa4e9oJK2kpnHDe1HYV1": {
34 | "cert_user_id": "3dporno@zeroid.bit",
35 | "date_added": 1,
36 | "source": "ZeroMe",
37 | "reason": "Long term pornography content poster on ZeroMe site. Unsure about his activities on other sites."
38 | },
39 | "17k3PvQS8X85js1PBuna6w8e6XjotCiT5L": {
40 | "cert_user_id": "alfao@zeroid.bit",
41 | "date_added": 1,
42 | "source": "ZeroMe",
43 | "reason": "Posting child pornography into general (non pornography targetted) site/s."
44 | },
45 | "13KYifCo93L2rptejRHcT7oM4qXpqL5u5G": {
46 | "cert_user_id": "woow@zeroid.bit",
47 | "date_added": 1,
48 | "source": "ZeroMe",
49 | "reason": "Posting child pornography into general (non pornography targetted) site/s."
50 | },
51 | "1JYfgs2tiLHFyWta6eRZnaUTNHiKDGYzNU": {
52 | "cert_user_id": "asukah@zeroid.bit",
53 | "date_added": 1,
54 | "source": "ZeroMe",
55 | "reason": "Posting child pornography into ZeroMe site. Marks himself as a pedo."
56 | },
57 | "1L4Ev3e99ZaMRqaTPUc5ZwHkWa62oGuFUU": {
58 | "cert_user_id": "jimmyruly@zeroid.bit",
59 | "date_added": 1,
60 | "source": "ZeroMe",
61 | "reason": "Long term pornography content poster on ZeroMe site. Unsure about his activities on other sites."
62 | },
63 | "1FHN4oukAG7zFUpiC9L2iz7QpQVTuT3xkz": {
64 | "cert_user_id": "nekocross@zeroid.bit",
65 | "date_added": 1,
66 | "source": "KopyKate",
67 | "reason": "Pornography content poster on KopyKate site. Unsure about his activities on other sites."
68 | },
69 | "17TFi7VtcyxehZB8JUN43trfr5hkjnoHsc": {
70 | "cert_user_id": "foxtrot@zeroid.bit",
71 | "date_added": 1,
72 | "reason": "Pornography content poster",
73 | "source": "ZeroMe"
74 | },
75 | "1DCJkxufYgBd8pj8VnkVXaGUCBJiq8g9ai": {
76 | "cert_user_id": "kheyflix@zeroid.bit",
77 | "date_added": 1,
78 | "reason": "Pornography content poster",
79 | "source": "ZeroMe"
80 | }
81 | }
82 | }
--------------------------------------------------------------------------------
/assets/filters/users-spamlist.json:
--------------------------------------------------------------------------------
1 | {
2 | "mutes" : {
3 | "16LErDGxiEQgmerLmwT2sBrtBeg2PBH3jN": {
4 | "cert_user_id": "zaranet@zeroid.bit",
5 | "date_added": 1549505685.860143,
6 | "reason": "Posting spam about crypto mining sites",
7 | "source": "15UYrA7aXr2Nto1Gg4yWXpY3EAJwafMTNk"
8 | },
9 | "12fkBZP8Pt6WPujhx1Xc8Rqve8rDKmHoBk": {
10 | "cert_user_id": "lkgskhg@zeroid.bit",
11 | "date_added": 1549505685.860143,
12 | "reason": "Chinese spammer",
13 | "source": "1MeFqFfFFGQfa1J3gJyYYUvb5Lksczq7nH"
14 | },
15 | "14fdwxPt83nTw5vFaXTCR7KQkAxkXuGbAR": {
16 | "cert_user_id": "doom1b@zeroid.bit",
17 | "date_added": 1495182803.383208,
18 | "reason": "Spammer",
19 | "source": "1MeFqFfFFGQfa1J3gJyYYUvb5Lksczq7nH"
20 | },
21 | "18EuCdX79X4qbLEFBDLiaTSbkXU1ojM9A2": {
22 | "cert_user_id": "miter@zeroid.bit",
23 | "date_added": 1549506339.578346,
24 | "reason": "Chinese spammer",
25 | "source": "1MeFqFfFFGQfa1J3gJyYYUvb5Lksczq7nH"
26 | },
27 | "1Abwpgjt1RmxDhhMzCKDsePVUUDSruW4cT": {
28 | "cert_user_id": "zeronetisashi@zeroid.bit",
29 | "date_added": 1549500655.330371,
30 | "reason": "Chinese spammer",
31 | "source": "1MeFqFfFFGQfa1J3gJyYYUvb5Lksczq7nH"
32 | },
33 | "1BKYZXxnwD1Ci92XE4VNkQmWy5HjCC51Lh": {
34 | "cert_user_id": "kasjslg@zeroid.bit",
35 | "date_added": 1549505927.418664,
36 | "reason": "Chinese spammer",
37 | "source": "1MeFqFfFFGQfa1J3gJyYYUvb5Lksczq7nH"
38 | },
39 | "1D4B7XbRYY5p9kx79NtKr3qiShR5Tcpnvo": {
40 | "cert_user_id": "doom1@zeroid.bit",
41 | "date_added": 1495182789.474986,
42 | "reason": "Spammer",
43 | "source": "1MeFqFfFFGQfa1J3gJyYYUvb5Lksczq7nH"
44 | },
45 | "1FCtdTcT4Y1LimfEpRhaHsGKKYiAGjtMaZ": {
46 | "cert_user_id": "goodone@zeroid.bit",
47 | "date_added": 1549489420.202482,
48 | "reason": "Chinese spammer",
49 | "source": "1MeFqFfFFGQfa1J3gJyYYUvb5Lksczq7nH"
50 | },
51 | "1MRSDFESsBXDGvNoZ5ifztA89XfEahA5ka": {
52 | "cert_user_id": "bbxxx@zeroid.bit",
53 | "date_added": 1495183369.513695,
54 | "reason": "Spammer",
55 | "source": "1MeFqFfFFGQfa1J3gJyYYUvb5Lksczq7nH"
56 | },
57 | "1EFPRZRhijiQv6MvhJQLgV2SdPtHR6tJZ": {
58 | "cert_user_id": "immortal0000@zeroid.bit",
59 | "date_added": 1495183624.231652,
60 | "reason": "Spammer",
61 | "source": "1MeFqFfFFGQfa1J3gJyYYUvb5Lksczq7nH"
62 | },
63 | "1GXJzsEWCBdesJY5BtKgJXFQLuMoVPD6ed": {
64 | "cert_user_id": "abnah@zeroid.bit",
65 | "date_added": 1549528840.535473,
66 | "reason": "Chinese spammer",
67 | "source": "1MeFqFfFFGQfa1J3gJyYYUvb5Lksczq7nH"
68 | },
69 | "1QYERLpyBWwtprzJNTtyaNpjgq4aq2kfB": {
70 | "cert_user_id": "afjzvmh@zeroid.bit",
71 | "date_added": 1549536521.766814,
72 | "reason": "Chinese spammer",
73 | "source": "1MeFqFfFFGQfa1J3gJyYYUvb5Lksczq7nH"
74 | },
75 | "1HQsX5fubepwWtHnf4SqNcFVEMa4t8N1jP": {
76 | "cert_user_id": "afnaui@zeroid.bit",
77 | "date_added": 1549538136.695098,
78 | "reason": "Chinese spammer",
79 | "source": "1MeFqFfFFGQfa1J3gJyYYUvb5Lksczq7nH"
80 | },
81 | "1QYERLpyBWwtprzJNTtyaNpjgq4aq2kfB": {
82 | "cert_user_id": "afjzvmh@zeroid.bit",
83 | "date_added": 1549539112.699984,
84 | "reason": "Chinese spammer",
85 | "source": "1MeFqFfFFGQfa1J3gJyYYUvb5Lksczq7nH"
86 | },
87 | "18KRHZjWh7HjvoRLAbVygq94waeWU69SSH": {
88 | "cert_user_id": "ajgaho@zeroid.bit",
89 | "date_added": 1549539909.840917,
90 | "reason": "Chinese spammer",
91 | "source": "1MeFqFfFFGQfa1J3gJyYYUvb5Lksczq7nH"
92 | },
93 | "1Fi7HAnhZ1iu3kuG4oEZPhkiGCqp9WcMaG": {
94 | "cert_user_id": "ajgalfj@zeroid.bit",
95 | "date_added": 1549540102.139871,
96 | "reason": "Chinese spammer",
97 | "source": "1MeFqFfFFGQfa1J3gJyYYUvb5Lksczq7nH"
98 | },
99 | "17VS3A2eHFeMuoRsQX5YofXuCRetQsHVJX": {
100 | "cert_user_id": "17VS3A2eHFeMuoR@millchan",
101 | "date_added": 1550169460.500,
102 | "reason": "Spammer on millchan /jessicanigri/",
103 | "source": "1ADQAHsqsie5PBeQhQgjcKmUu3qdPFg6aA"
104 | },
105 | "16u5SZKMv9gnxLKQfFE8hYPB9UhFGn5FJw": {
106 | "cert_user_id": "16u5SZKMv9gnxLK@millchan",
107 | "date_added": 1550169460.500,
108 | "reason": "Spammer on millchan /jessicanigri/",
109 | "source": "1ADQAHsqsie5PBeQhQgjcKmUu3qdPFg6aA"
110 | },
111 | "1QJj8o4h2zgcuozSecB2WqmL6FBeQS1XSB": {
112 | "cert_user_id": "1QJj8o4h2zgcuoz@millchan",
113 | "date_added": 1550169460.500,
114 | "reason": "Spammer on millchan /jessicanigri/",
115 | "source": "1ADQAHsqsie5PBeQhQgjcKmUu3qdPFg6aA"
116 | },
117 | "15wTgdNkMoX4keYro96QiefAwXtf8FvxYY": {
118 | "cert_user_id": "15wTgdNkMoX4keY@millchan",
119 | "date_added": 1550169460.500,
120 | "reason": "Spammer on millchan /jessicanigri/",
121 | "source": "1ADQAHsqsie5PBeQhQgjcKmUu3qdPFg6aA"
122 | },
123 | "19eXGqVBwGmKWSfw7MjWknbX5kG5VEwML2": {
124 | "cert_user_id": "19eXGqVBwGmKWSf@millchan",
125 | "date_added": 1550169460.500,
126 | "reason": "Spammer on millchan /jessicanigri/",
127 | "source": "1ADQAHsqsie5PBeQhQgjcKmUu3qdPFg6aA"
128 | },
129 | "14JRUax64emMFVVxN2ikjz5J74CjqoJtFr": {
130 | "cert_user_id": "yeahyi@zeroid.bit",
131 | "date_added": 1550206131.422221,
132 | "reason": "Spammer",
133 | "source": "1iD5ZQJMNXu43w1qLB8sfdHVKppVMduGz"
134 | },
135 | "14Y1Vbo7Mz2efjpMnc4t5iSEYixVQhqQpL": {
136 | "cert_user_id": "goody@zeroid.bit",
137 | "date_added": 1550717228.894357,
138 | "reason": "Spammed ZeroTalk threads",
139 | "source": "1iD5ZQJMNXu43w1qLB8sfdHVKppVMduGz"
140 | },
141 | "13wJrWgzjwKU1zgXJMDCGhkSjsaUvYjZM2": {
142 | "cert_user_id": "duende@zeroid.bit",
143 | "date_added": 1555902803.067858,
144 | "reason": "Pedo who's encouraging me to suicide and spamming his bullshit.",
145 | "source": "1MeFqFfFFGQfa1J3gJyYYUvb5Lksczq7nH"
146 | },
147 | "17AMQVbBa12XB3xFWKDnP2dCEx92TaiY7X": {
148 | "cert_user_id": "anonymouslogin@zeroid.bit",
149 | "date_added": 1564403461.560763,
150 | "reason": "Public cert, spamming kill yourself messages",
151 | "source": "1MeFqFfFFGQfa1J3gJyYYUvb5Lksczq7nH"
152 | },
153 | "1A1JcKDgksT5pQJoSo7g1P1cC9kAKvG93m": {
154 | "cert_user_id": "publicid@zeroid.bit",
155 | "date_added": 1564403486.731043,
156 | "reason": "Public cert, spamming kill yourself messages",
157 | "source": "1MeFqFfFFGQfa1J3gJyYYUvb5Lksczq7nH"
158 | },
159 | "18oN5jkSiB1SLb4Jywb4ZnKiwXqtQN5Fau": {
160 | "cert_user_id": "qqqqqqqqqqqqqqqq@zeroid.bit",
161 | "date_added": 1568807655.9091918,
162 | "reason": "spammer",
163 | "source": "1TaLkFrMwvbNsooF4ioKAY9EuxTBTjipT"
164 | },
165 | "1JrUPjJmdTq5UsiKefuGTkNMd8MUNvP8Ss": {
166 | "cert_user_id": "tedreamraffle@zeroid.bit",
167 | "date_added": 1574046190.8304808,
168 | "reason": "Spam raffles/lotto",
169 | "source": "1TaLkFrMwvbNsooF4ioKAY9EuxTBTjipT"
170 | },
171 | "12ShAsoQVkbEgqfjS2JmXt7cXBSbf8ifuS": {
172 | "cert_user_id": "caropc2@zeroid.bit",
173 | "date_added": 1574420510.623536,
174 | "reason": "Spamming kopykate clone",
175 | "source": "1TaLkFrMwvbNsooF4ioKAY9EuxTBTjipT"
176 | },
177 | "1D5iCU5XE1D25ce2fV2XZqH95jGRtRaKZL": {
178 | "cert_user_id": "caropc10@zeroid.bit",
179 | "date_added": 1574420502.4061,
180 | "reason": "spamming kopykate clone",
181 | "source": "1TaLkFrMwvbNsooF4ioKAY9EuxTBTjipT"
182 | },
183 | "13EafRdDw5sZF42dTn68uDdcssTWKbdauJ": {
184 | "cert_user_id": "deepnude@zeroid.bit",
185 | "date_added": 1583066012.629051,
186 | "reason": "harmful user",
187 | "source": "1TaLkFrMwvbNsooF4ioKAY9EuxTBTjipT"
188 | },
189 | "1EZTWytasXcKdiUFnN4KHqAfvg1nwkTkKv": {
190 | "cert_user_id": "kai0@zeroid.bit",
191 | "date_added": 1530012685,
192 | "source": "ZeroTalk",
193 | "reason": "Spammer"
194 | },
195 | "14ytAKDfNjArMTqGecTi7ginG3aZTsRAum": {
196 | "cert_user_id": "polar2@zeroid.bit",
197 | "date_added": 1530012685,
198 | "source": "ZeroTalk",
199 | "reason": "Spammer"
200 | },
201 | "1JMXM9eSCpGAocrYxkfUmwiXeqcJw637vC": {
202 | "cert_user_id": "mrc@zeroid.bit",
203 | "date_added": 1530012685,
204 | "source": "ZeroTalk",
205 | "reason": "Spammer"
206 | }
207 | }
208 | }
--------------------------------------------------------------------------------
/assets/icons/facebook.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/assets/icons/facebook.png
--------------------------------------------------------------------------------
/assets/icons/facebook_dark.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/assets/icons/facebook_dark.png
--------------------------------------------------------------------------------
/assets/icons/github.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/assets/icons/github.png
--------------------------------------------------------------------------------
/assets/icons/github_dark.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/assets/icons/github_dark.png
--------------------------------------------------------------------------------
/assets/icons/twitter.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/assets/icons/twitter.png
--------------------------------------------------------------------------------
/assets/icons/twitter_dark.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/assets/icons/twitter_dark.png
--------------------------------------------------------------------------------
/assets/logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/assets/logo.png
--------------------------------------------------------------------------------
/buildapk.bat:
--------------------------------------------------------------------------------
1 | dart buildtools\utils.dart compile
--------------------------------------------------------------------------------
/buildtools/compile.bat:
--------------------------------------------------------------------------------
1 | flutter build apk
--------------------------------------------------------------------------------
/buildtools/utils.dart:
--------------------------------------------------------------------------------
1 | import 'dart:convert';
2 | import 'dart:io';
3 |
4 | main(List args) {
5 | String arg = (args.isEmpty) ? '' : args[0];
6 | switch (arg) {
7 | case 'modules':
8 | modules();
9 | break;
10 | case 'nonpy':
11 | removeNonPy();
12 | break;
13 | case 'compile':
14 | compile();
15 | break;
16 | case 'update':
17 | updateZeroNetCode();
18 | break;
19 | default:
20 | compile();
21 | }
22 | }
23 |
24 | updateZeroNetCode() {
25 | var zeronetPath = Directory.current.path + '/build/ZeroNet-py3';
26 | if (Directory(zeronetPath).existsSync()) {
27 | print('Deleting ZeroNet Git Repo');
28 | Directory(zeronetPath).deleteSync(recursive: true);
29 | }
30 | var process = Process.runSync('git', [
31 | 'clone',
32 | 'https://github.com/HelloZeroNet/ZeroNet.git',
33 | '--depth=1',
34 | zeronetPath,
35 | ]);
36 | if (process.exitCode == 0) {
37 | print('Successfully downloaded Zeronet Repo');
38 |
39 | print('Deleting git history');
40 | Directory(zeronetPath + '/.git').deleteSync(recursive: true);
41 |
42 | Process.runSync('cd', ['build']);
43 | Process.runSync('7z', ['a', '-tzip', 'zeronet_py3.zip', 'ZeroNet']);
44 | }
45 | }
46 |
47 | compile() {
48 | String versionProp = '';
49 | var content = File('android/version.properties').readAsStringSync();
50 | versionProp =
51 | content.split('\n')[0].replaceAll('flutter.versionName=', '').trim();
52 | var result = Process.runSync('git', [
53 | 'log',
54 | '-1',
55 | '--pretty=%B',
56 | ]);
57 | var ver = (result.stdout as String).split('\n')[0].trim();
58 | if (ver.contains(versionProp)) {
59 | print('Repo is Clear to Compile APK For Release...');
60 | print('Compiling APK For Release...');
61 | Process.start('buildtools\\compile.bat', []).then((Process result) {
62 | result.stdout.listen((onData) {
63 | // print('Output : ');
64 | print(utf8.decode(onData));
65 | });
66 | result.stderr.listen((onData) {
67 | // print('Error : ');
68 | print(utf8.decode(onData));
69 | });
70 | });
71 | } else
72 | throw "Update version.properties";
73 | }
74 |
75 | var totalFilesList = [];
76 | var nonPyFiles = [];
77 | var pyFiles = [];
78 | var pyLibDir = '\\lib\\python3.8';
79 | removeNonPy() {
80 | Directory dir = Directory.current;
81 | //Here
82 | recursiveHelper(Directory(dir.path + pyLibDir));
83 | String nonPy = '';
84 | nonPyFiles.forEach((f) => nonPy = nonPy + f + '\n');
85 |
86 | File f = File('files-nonpy');
87 | if (f.existsSync()) f.deleteSync();
88 | f.createSync();
89 | f.writeAsStringSync(nonPy);
90 |
91 | print(totalFilesList.length);
92 | print(pyFiles.length);
93 | print(nonPyFiles.length);
94 | }
95 |
96 | List ls = [
97 | 'config-3.8',
98 | 'test',
99 | 'tests',
100 | 'ensurepip',
101 | 'idle_test',
102 | ];
103 |
104 | recursiveHelper(Directory dir) {
105 | for (var file in dir.listSync()) {
106 | if (file is File) {
107 | var filePath = file.path.replaceAll(dir.path + '\\', '');
108 | totalFilesList.add(filePath);
109 | if (filePath.endsWith('.py') || filePath.endsWith('.so')) {
110 | print('Python file $filePath');
111 | pyFiles.add(filePath);
112 | } else {
113 | print('Non Python file $filePath');
114 | if (filePath.endsWith('.exe') ||
115 | filePath.endsWith('.bat') ||
116 | filePath.endsWith('.ps1')) {
117 | print("Deleting File at:" + filePath);
118 | nonPyFiles.add(filePath);
119 | file.deleteSync(recursive: true);
120 | } else {
121 | print("Orphan File at " + filePath);
122 | }
123 | }
124 | } else {
125 | for (var item in ls) {
126 | if (file.path.endsWith('\\$item')) {
127 | file.deleteSync(recursive: true);
128 | } else {
129 | recursiveHelper(file as Directory);
130 | }
131 | }
132 | }
133 | }
134 | }
135 |
136 | modules() {
137 | Directory dir = Directory.current;
138 | File module = File('modules');
139 | String modules = module.readAsStringSync();
140 | List validModules = [];
141 | modules.split('\n').forEach((f) {
142 | if (f.contains('usr/')) {
143 | var i = f.indexOf('usr/');
144 | validModules.add(f.substring(i + 4).replaceAll('/', '\\'));
145 | }
146 | });
147 | var totalFilesList = [];
148 | var deletedFilesList = [];
149 | var pyLibDir = '\\lib\\python3.8';
150 | for (var file in Directory(dir.path + pyLibDir).listSync(recursive: true)) {
151 | if (file is File) {
152 | var filePath = file.path.replaceAll(dir.path + '\\', '');
153 | totalFilesList.add(filePath);
154 | if (validModules.indexOf(filePath) == -1) {
155 | print('deleting ${file.path}');
156 | deletedFilesList.add(filePath);
157 | file.deleteSync(recursive: false);
158 | }
159 | }
160 | }
161 | String deleted = '';
162 | deletedFilesList.forEach((f) => deleted = deleted + f + '\n');
163 |
164 | File f = File('modules-deleted');
165 | if (f.existsSync()) f.deleteSync();
166 | f.createSync();
167 | f.writeAsStringSync(deleted);
168 |
169 | deleteEmptyDirs(dir, pyLibDir);
170 | deleteEmptyDirs(dir, pyLibDir);
171 | print(totalFilesList.length);
172 | // print(totalFilesList[0]);
173 | print(validModules.length);
174 | // print(validModules[0]);
175 | print(deletedFilesList.length);
176 | // print(deletedFilesList[0]);
177 | }
178 |
179 | deleteEmptyDirs(Directory dir, String pyLibDir) {
180 | print('Deleting Empty Dirs');
181 | for (var file in Directory(dir.path + pyLibDir).listSync(recursive: true)) {
182 | if (file is Directory) {
183 | if (file.listSync(recursive: true).length == 0) {
184 | file.deleteSync(recursive: true);
185 | }
186 | }
187 | }
188 | }
189 |
--------------------------------------------------------------------------------
/fastlane/metadata/android/en-US/changelogs/70.txt:
--------------------------------------------------------------------------------
1 | v 0.7.0
2 |
3 | - Major UI Changes with Modern UI 😍😍.
4 | - Faster Startup of ZeroNet 😁😁.
5 | - Individual Site Details for Popular Sites with Stats and useful functions 😘😘.
6 | - Update Minimum Android Support Version to API 21 (Android 5.0 Lollipop).
7 | - Add Site Shortcut to HomeScreen.
8 | - Added In-App Review so that you can give your feedback quickly.
9 | - Several Bug Fixes and Improvements.
--------------------------------------------------------------------------------
/fastlane/metadata/android/en-US/full_description.txt:
--------------------------------------------------------------------------------
1 | ZeroNet - Open, free and uncensorable websites, using Bitcoin cryptography and BitTorrent network.
2 |
3 | TLDR(Short and Simple) Version
4 | Slides : http://bit.ly/howzeronetworks
5 |
6 | PEER-TO-PEER
7 | - Your content distributed directly to other visitors without any central server.
8 |
9 | Unstopable
10 | - It's nowhere because it's everywhere!
11 | - No hosting costs
12 | - Sites are served by visitors.
13 | - Always accessible
14 | - No single point of failure.
15 |
16 | SIMPLE
17 | - No configuration needed:
18 | - Download, unpack and start using it.
19 |
20 | .BIT DOMAINS
21 | - Decentralized domains using Namecoin cryptocurrency.
22 |
23 | NO PASSWORDS
24 | - Your account is protected by the same cryptography as your Bitcoin wallet.
25 |
26 | FAST
27 | - Page response time is not limited by your connection speed.
28 |
29 | DYNAMIC CONTENT
30 | - Real-time updated, multi-user websites.
31 |
32 | WORKS EVERYWHERE
33 | - Supports any modern browser on
34 | - Windows, Linux or Mac and Android platforms.
35 |
36 | ANONYMITY
37 | - You can easily hide your IP address using the Tor network.
38 |
39 | OFFLINE
40 | - Browse the sites you're seeding even if your internet connection is down.
41 |
42 | OPEN SOURCE
43 | - Developed by the community for the community.
44 |
45 | We believe in
46 | open, free, and uncensored
47 | network and communication.
48 |
49 | About Mobile Client
50 | ZeroNet Mobile is an Android Client for ZeroNet, Project uses flutter framework for runner and is Open Sourced at https://github.com/canewsin/zeronet_mobile, you can contribute to the app by forking the project.
51 |
52 | Contribute
53 | If you want to support project's further development, you can contribute your time or money, If you want to contribute money you can send bitcoin or other supported crypto currencies to above addresses or buy in-app purchases, if want to contribute translations or code, visit official GitHub repo.
54 |
55 | Links :
56 | Facebook https://www.facebook.com/HelloZeroNet
57 | Twitter https://twitter.com/HelloZeroNet
58 | Reddit https://www.reddit.com/r/zeronet/
59 | Github https://github.com/HelloZeroNet/ZeroNet
--------------------------------------------------------------------------------
/fastlane/metadata/android/en-US/images/featureGraphic.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/fastlane/metadata/android/en-US/images/featureGraphic.png
--------------------------------------------------------------------------------
/fastlane/metadata/android/en-US/images/icon.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/fastlane/metadata/android/en-US/images/icon.png
--------------------------------------------------------------------------------
/fastlane/metadata/android/en-US/images/phoneScreenshots/1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/fastlane/metadata/android/en-US/images/phoneScreenshots/1.png
--------------------------------------------------------------------------------
/fastlane/metadata/android/en-US/images/phoneScreenshots/2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/fastlane/metadata/android/en-US/images/phoneScreenshots/2.png
--------------------------------------------------------------------------------
/fastlane/metadata/android/en-US/images/phoneScreenshots/3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/fastlane/metadata/android/en-US/images/phoneScreenshots/3.png
--------------------------------------------------------------------------------
/fastlane/metadata/android/en-US/images/phoneScreenshots/4.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/fastlane/metadata/android/en-US/images/phoneScreenshots/4.png
--------------------------------------------------------------------------------
/fastlane/metadata/android/en-US/images/phoneScreenshots/5.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/fastlane/metadata/android/en-US/images/phoneScreenshots/5.png
--------------------------------------------------------------------------------
/fastlane/metadata/android/en-US/images/phoneScreenshots/6.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/fastlane/metadata/android/en-US/images/phoneScreenshots/6.png
--------------------------------------------------------------------------------
/fastlane/metadata/android/en-US/short_description.txt:
--------------------------------------------------------------------------------
1 | ZeroNet - Open, Free Speech, Uncensored platform for modern & decentralized web.
--------------------------------------------------------------------------------
/fastlane/metadata/android/en-US/title.txt:
--------------------------------------------------------------------------------
1 | ZeroNet Mobile - Open, Free and Uncensorable Sites
--------------------------------------------------------------------------------
/fastlane/metadata/android/en-US/video.txt:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/fastlane/metadata/android/en-US/video.txt
--------------------------------------------------------------------------------
/ios/.gitignore:
--------------------------------------------------------------------------------
1 | *.mode1v3
2 | *.mode2v3
3 | *.moved-aside
4 | *.pbxuser
5 | *.perspectivev3
6 | **/*sync/
7 | .sconsign.dblite
8 | .tags*
9 | **/.vagrant/
10 | **/DerivedData/
11 | Icon?
12 | **/Pods/
13 | **/.symlinks/
14 | profile
15 | xcuserdata
16 | **/.generated/
17 | Flutter/App.framework
18 | Flutter/Flutter.framework
19 | Flutter/Flutter.podspec
20 | Flutter/Generated.xcconfig
21 | Flutter/app.flx
22 | Flutter/app.zip
23 | Flutter/flutter_assets/
24 | Flutter/flutter_export_environment.sh
25 | ServiceDefinitions.json
26 | Runner/GeneratedPluginRegistrant.*
27 |
28 | # Exceptions to above rules.
29 | !default.mode1v3
30 | !default.mode2v3
31 | !default.pbxuser
32 | !default.perspectivev3
33 |
--------------------------------------------------------------------------------
/ios/Flutter/AppFrameworkInfo.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | $(DEVELOPMENT_LANGUAGE)
7 | CFBundleExecutable
8 | App
9 | CFBundleIdentifier
10 | io.flutter.flutter.app
11 | CFBundleInfoDictionaryVersion
12 | 6.0
13 | CFBundleName
14 | App
15 | CFBundlePackageType
16 | FMWK
17 | CFBundleShortVersionString
18 | 1.0
19 | CFBundleSignature
20 | ????
21 | CFBundleVersion
22 | 1.0
23 | MinimumOSVersion
24 | 8.0
25 |
26 |
27 |
--------------------------------------------------------------------------------
/ios/Flutter/Debug.xcconfig:
--------------------------------------------------------------------------------
1 | #include "Generated.xcconfig"
2 |
--------------------------------------------------------------------------------
/ios/Flutter/Release.xcconfig:
--------------------------------------------------------------------------------
1 | #include "Generated.xcconfig"
2 |
--------------------------------------------------------------------------------
/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata:
--------------------------------------------------------------------------------
1 |
2 |
4 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | IDEDidComputeMac32BitWarning
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | PreviewsEnabled
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme:
--------------------------------------------------------------------------------
1 |
2 |
5 |
8 |
9 |
15 |
21 |
22 |
23 |
24 |
25 |
30 |
31 |
32 |
33 |
39 |
40 |
41 |
42 |
43 |
44 |
54 |
56 |
62 |
63 |
64 |
65 |
66 |
67 |
73 |
75 |
81 |
82 |
83 |
84 |
86 |
87 |
90 |
91 |
92 |
--------------------------------------------------------------------------------
/ios/Runner.xcworkspace/contents.xcworkspacedata:
--------------------------------------------------------------------------------
1 |
2 |
4 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | IDEDidComputeMac32BitWarning
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/ios/Runner.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | PreviewsEnabled
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/ios/Runner/AppDelegate.swift:
--------------------------------------------------------------------------------
1 | import UIKit
2 | import Flutter
3 |
4 | @UIApplicationMain
5 | @objc class AppDelegate: FlutterAppDelegate {
6 | override func application(
7 | _ application: UIApplication,
8 | didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?
9 | ) -> Bool {
10 | GeneratedPluginRegistrant.register(with: self)
11 | return super.application(application, didFinishLaunchingWithOptions: launchOptions)
12 | }
13 | }
14 |
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json:
--------------------------------------------------------------------------------
1 | {
2 | "images" : [
3 | {
4 | "size" : "20x20",
5 | "idiom" : "iphone",
6 | "filename" : "Icon-App-20x20@2x.png",
7 | "scale" : "2x"
8 | },
9 | {
10 | "size" : "20x20",
11 | "idiom" : "iphone",
12 | "filename" : "Icon-App-20x20@3x.png",
13 | "scale" : "3x"
14 | },
15 | {
16 | "size" : "29x29",
17 | "idiom" : "iphone",
18 | "filename" : "Icon-App-29x29@1x.png",
19 | "scale" : "1x"
20 | },
21 | {
22 | "size" : "29x29",
23 | "idiom" : "iphone",
24 | "filename" : "Icon-App-29x29@2x.png",
25 | "scale" : "2x"
26 | },
27 | {
28 | "size" : "29x29",
29 | "idiom" : "iphone",
30 | "filename" : "Icon-App-29x29@3x.png",
31 | "scale" : "3x"
32 | },
33 | {
34 | "size" : "40x40",
35 | "idiom" : "iphone",
36 | "filename" : "Icon-App-40x40@2x.png",
37 | "scale" : "2x"
38 | },
39 | {
40 | "size" : "40x40",
41 | "idiom" : "iphone",
42 | "filename" : "Icon-App-40x40@3x.png",
43 | "scale" : "3x"
44 | },
45 | {
46 | "size" : "60x60",
47 | "idiom" : "iphone",
48 | "filename" : "Icon-App-60x60@2x.png",
49 | "scale" : "2x"
50 | },
51 | {
52 | "size" : "60x60",
53 | "idiom" : "iphone",
54 | "filename" : "Icon-App-60x60@3x.png",
55 | "scale" : "3x"
56 | },
57 | {
58 | "size" : "20x20",
59 | "idiom" : "ipad",
60 | "filename" : "Icon-App-20x20@1x.png",
61 | "scale" : "1x"
62 | },
63 | {
64 | "size" : "20x20",
65 | "idiom" : "ipad",
66 | "filename" : "Icon-App-20x20@2x.png",
67 | "scale" : "2x"
68 | },
69 | {
70 | "size" : "29x29",
71 | "idiom" : "ipad",
72 | "filename" : "Icon-App-29x29@1x.png",
73 | "scale" : "1x"
74 | },
75 | {
76 | "size" : "29x29",
77 | "idiom" : "ipad",
78 | "filename" : "Icon-App-29x29@2x.png",
79 | "scale" : "2x"
80 | },
81 | {
82 | "size" : "40x40",
83 | "idiom" : "ipad",
84 | "filename" : "Icon-App-40x40@1x.png",
85 | "scale" : "1x"
86 | },
87 | {
88 | "size" : "40x40",
89 | "idiom" : "ipad",
90 | "filename" : "Icon-App-40x40@2x.png",
91 | "scale" : "2x"
92 | },
93 | {
94 | "size" : "76x76",
95 | "idiom" : "ipad",
96 | "filename" : "Icon-App-76x76@1x.png",
97 | "scale" : "1x"
98 | },
99 | {
100 | "size" : "76x76",
101 | "idiom" : "ipad",
102 | "filename" : "Icon-App-76x76@2x.png",
103 | "scale" : "2x"
104 | },
105 | {
106 | "size" : "83.5x83.5",
107 | "idiom" : "ipad",
108 | "filename" : "Icon-App-83.5x83.5@2x.png",
109 | "scale" : "2x"
110 | },
111 | {
112 | "size" : "1024x1024",
113 | "idiom" : "ios-marketing",
114 | "filename" : "Icon-App-1024x1024@1x.png",
115 | "scale" : "1x"
116 | }
117 | ],
118 | "info" : {
119 | "version" : 1,
120 | "author" : "xcode"
121 | }
122 | }
123 |
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json:
--------------------------------------------------------------------------------
1 | {
2 | "images" : [
3 | {
4 | "idiom" : "universal",
5 | "filename" : "LaunchImage.png",
6 | "scale" : "1x"
7 | },
8 | {
9 | "idiom" : "universal",
10 | "filename" : "LaunchImage@2x.png",
11 | "scale" : "2x"
12 | },
13 | {
14 | "idiom" : "universal",
15 | "filename" : "LaunchImage@3x.png",
16 | "scale" : "3x"
17 | }
18 | ],
19 | "info" : {
20 | "version" : 1,
21 | "author" : "xcode"
22 | }
23 | }
24 |
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/ZeroNetX/zeronet_mobile/1cf141a1697d78ba41c52122a5858dd148056b1c/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md:
--------------------------------------------------------------------------------
1 | # Launch Screen Assets
2 |
3 | You can customize the launch screen with your own desired assets by replacing the image files in this directory.
4 |
5 | You can also do it by opening your Flutter project's Xcode project with `open ios/Runner.xcworkspace`, selecting `Runner/Assets.xcassets` in the Project Navigator and dropping in the desired images.
--------------------------------------------------------------------------------
/ios/Runner/Base.lproj/LaunchScreen.storyboard:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
--------------------------------------------------------------------------------
/ios/Runner/Base.lproj/Main.storyboard:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
--------------------------------------------------------------------------------
/ios/Runner/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | $(DEVELOPMENT_LANGUAGE)
7 | CFBundleExecutable
8 | $(EXECUTABLE_NAME)
9 | CFBundleIdentifier
10 | $(PRODUCT_BUNDLE_IDENTIFIER)
11 | CFBundleInfoDictionaryVersion
12 | 6.0
13 | CFBundleName
14 | zeronet
15 | CFBundlePackageType
16 | APPL
17 | CFBundleShortVersionString
18 | $(FLUTTER_BUILD_NAME)
19 | CFBundleSignature
20 | ????
21 | CFBundleVersion
22 | $(FLUTTER_BUILD_NUMBER)
23 | LSRequiresIPhoneOS
24 |
25 | UILaunchStoryboardName
26 | LaunchScreen
27 | UIMainStoryboardFile
28 | Main
29 | UISupportedInterfaceOrientations
30 |
31 | UIInterfaceOrientationPortrait
32 | UIInterfaceOrientationLandscapeLeft
33 | UIInterfaceOrientationLandscapeRight
34 |
35 | UISupportedInterfaceOrientations~ipad
36 |
37 | UIInterfaceOrientationPortrait
38 | UIInterfaceOrientationPortraitUpsideDown
39 | UIInterfaceOrientationLandscapeLeft
40 | UIInterfaceOrientationLandscapeRight
41 |
42 | UIViewControllerBasedStatusBarAppearance
43 |
44 |
45 |
46 |
--------------------------------------------------------------------------------
/ios/Runner/Runner-Bridging-Header.h:
--------------------------------------------------------------------------------
1 | #import "GeneratedPluginRegistrant.h"
--------------------------------------------------------------------------------
/lib/controllers/strings.dart:
--------------------------------------------------------------------------------
1 | import '../imports.dart';
2 |
3 | final strController = Get.put(StringController());
4 |
5 | class StringController extends GetxController {
6 | final statusNotRunningStr = 'Not Running'.obs;
7 | final statusInitializingStr = 'Initializing..'.obs;
8 | final statusStartingStr = 'Starting'.obs;
9 | final statusRunningStr = 'Running'.obs;
10 | final statusRunningWithTorStr = 'Running with Tor'.obs;
11 | final statusErrorStr = 'Error'.obs;
12 | final loadingPageWarningStr = """
13 | Please Wait! This may take a while, happens
14 | only first time, Don't Press Back button.
15 | If You Accidentally Pressed Back,
16 | Clean App Storage in Settings or
17 | Uninstall and Reinstall The App.
18 | """
19 | .obs;
20 | final startStr = 'Start'.obs;
21 | final pleaseWaitStr = 'Please Wait..!'.obs;
22 | final loadingStr = 'Loading'.obs;
23 | final stopStr = 'Stop'.obs;
24 | final viewLogStr = 'View Log'.obs;
25 | final updateStr = 'Update'.obs;
26 | final downloadingStr = 'Downloading'.obs;
27 | final downloadedStr = 'Downloaded'.obs;
28 | final installingStr = 'Installing'.obs;
29 | final installationCompletedStr = 'Installation Completed'.obs;
30 | final notAvaliableStr = 'Not Available'.obs;
31 |
32 | void updateloadingPageWarningStr(String str) =>
33 | loadingPageWarningStr.value = str;
34 | void updatestatusNotRunningStr(String str) => statusNotRunningStr.value = str;
35 | void updatestatusInitializingStr(String str) =>
36 | statusInitializingStr.value = str;
37 | void updatestatusStartingStr(String str) => statusStartingStr.value = str;
38 | void updatestatusRunningStr(String str) => statusRunningStr.value = str;
39 | void updatestatusRunningWithTorStr(String str) =>
40 | statusRunningStr.value = str;
41 | void updatestatusErrorStr(String str) => statusErrorStr.value = str;
42 | void updatestartStr(String str) => startStr.value = str;
43 | void updatepleaseWaitStr(String str) => pleaseWaitStr.value = str;
44 | void updatestopStr(String str) => stopStr.value = str;
45 | void updateviewLogStr(String str) => viewLogStr.value = str;
46 | void updateupdateStr(String str) => updateStr.value = str;
47 | void updatedownloadingStr(String str) => downloadingStr.value = str;
48 | void updatedownloadedStr(String str) => downloadedStr.value = str;
49 | void updateinstallingStr(String str) => installingStr.value = str;
50 | void updateinstallationCompletedStr(String str) =>
51 | installationCompletedStr.value = str;
52 | void updatenotAvaliableStr(String str) => notAvaliableStr.value = str;
53 |
54 | void loadTranslationsFromFile(String path) {
55 | File translationsFile = File(path);
56 | String readAsStringSync = '';
57 | try {
58 | readAsStringSync = translationsFile.readAsStringSync();
59 | } catch (e) {
60 | if (e is FileSystemException) return;
61 | }
62 | Map map = json.decode(readAsStringSync);
63 | updateloadingPageWarningStr(map['loadingPageWarningStr']);
64 | updatestatusNotRunningStr(map['statusNotRunningStr']);
65 | updatestartStr(map['startStr']);
66 | updatestatusInitializingStr(map['statusInitializingStr']);
67 | updatestatusStartingStr(map['statusStartingStr']);
68 | updatestatusRunningStr(map['statusRunningStr']);
69 | updatestatusRunningWithTorStr(map['statusRunningWithTorStr']);
70 | updatestatusErrorStr(map['statusErrorStr']);
71 | updatepleaseWaitStr(map['pleaseWaitStr']);
72 | updatestopStr(map['stopStr']);
73 | updateviewLogStr(map['viewLogStr']);
74 | updateupdateStr(map['updateStr']);
75 | updatedownloadingStr(map['downloadingStr']);
76 | updatedownloadedStr(map['downloadedStr']);
77 | updateinstallingStr(map['installingStr']);
78 | updateinstallationCompletedStr(map['installationCompletedStr']);
79 | updatenotAvaliableStr(map['notAvaliableStr']);
80 | }
81 | }
82 |
--------------------------------------------------------------------------------
/lib/controllers/uicontroller.dart:
--------------------------------------------------------------------------------
1 | import '../imports.dart';
2 |
3 | final uiStore = Get.put(UiController());
4 |
5 | class UiController extends GetxController {
6 | late PersistentBottomSheetController currentBottomSheetController;
7 | final isWindowVisible = false.obs;
8 |
9 | Rx appUpdate = AppUpdate.NOT_AVAILABLE.obs;
10 |
11 | void updateInAppUpdateAvailable(AppUpdate available) =>
12 | appUpdate.value = available;
13 |
14 | var showSnackReply = false.obs;
15 |
16 | void updateShowSnackReply(bool show) {
17 | showSnackReply.value = show;
18 | }
19 |
20 | var reload = 0.obs;
21 |
22 | void updateReload(int i) {
23 | reload.value = i;
24 | }
25 |
26 | Rx zeroNetStatus = ZeroNetStatus.NOT_RUNNING.obs;
27 |
28 | void setZeroNetStatus(ZeroNetStatus status) {
29 | zeroNetStatus.value = status;
30 | }
31 | }
32 |
--------------------------------------------------------------------------------
/lib/controllers/varcontroller.dart:
--------------------------------------------------------------------------------
1 | import '../imports.dart';
2 |
3 | final varStore = Get.put(VarController());
4 |
5 | class VarController extends GetxController {
6 | var zeroNetWrapperKey = '';
7 | Rx event = ObservableEvent.none.obs;
8 | var zeroNetLog = 'ZeroNetX'.obs;
9 | RxString zeroNetStatus = strController.statusNotRunningStr;
10 | var zeroNetInstalled = false.obs;
11 | var zeroNetDownloaded = false.obs;
12 | RxString loadingStatus = strController.loadingStr;
13 | var loadingPercent = 0.obs;
14 |
15 | void setObservableEvent(ObservableEvent eve) {
16 | event.value = eve;
17 | }
18 |
19 | void setZeroNetLog(String status) {
20 | zeroNetLog.value = status;
21 | }
22 |
23 | void setZeroNetStatus(String status) {
24 | zeroNetStatus.value = status;
25 | }
26 |
27 | void isZeroNetInstalled(bool installed) {
28 | zeroNetInstalled.value = installed;
29 | }
30 |
31 | void isZeroNetDownloaded(bool downloaded) {
32 | zeroNetDownloaded.value = downloaded;
33 | }
34 |
35 | void setLoadingStatus(String status) {
36 | loadingStatus.value = status;
37 | }
38 |
39 | void setLoadingPercent(int percent) {
40 | loadingPercent.value = percent;
41 | }
42 | }
43 |
44 | enum ObservableEvent {
45 | none,
46 | downloding,
47 | downloaded,
48 | installing,
49 | installed,
50 | }
51 |
--------------------------------------------------------------------------------
/lib/imports.dart:
--------------------------------------------------------------------------------
1 | export 'dart:async';
2 | export 'dart:convert';
3 | export 'dart:io';
4 | export 'dart:isolate';
5 | export 'dart:typed_data';
6 |
7 | export 'package:flutter/foundation.dart';
8 | export 'package:flutter/material.dart';
9 | export 'package:flutter/services.dart';
10 |
11 | export 'package:bitsdojo_window/bitsdojo_window.dart';
12 | export 'package:crypto/crypto.dart';
13 | export 'package:device_info_plus/device_info_plus.dart';
14 | export 'package:diff_match_patch/diff_match_patch.dart';
15 | export 'package:equatable/equatable.dart';
16 | export 'package:file_picker/file_picker.dart';
17 | // export 'package:flutter_absolute_path/flutter_absolute_path.dart';
18 | export 'package:flutter_background_service/flutter_background_service.dart';
19 | export 'package:flutter_downloader/flutter_downloader.dart';
20 | export 'package:get/get.dart' hide HeaderValue, MultipartFile, Response;
21 | export 'package:http/http.dart';
22 | export 'package:in_app_update/in_app_update.dart';
23 | export 'package:internet_file/internet_file.dart';
24 | export 'package:internet_file/storage_io.dart';
25 | export 'package:package_info_plus/package_info_plus.dart';
26 | export 'package:path_provider/path_provider.dart';
27 | export 'package:random_string/random_string.dart';
28 | export 'package:system_tray/system_tray.dart';
29 | export 'package:zeronet_ws/zeronet_ws.dart';
30 |
31 | export 'controllers/varcontroller.dart';
32 | export 'controllers/uicontroller.dart';
33 | export 'controllers/strings.dart';
34 | export 'models/enums.dart';
35 | export 'models/models.dart';
36 | export 'others/common.dart';
37 | export 'others/constants.dart';
38 | export 'others/extensions.dart';
39 | export 'others/native.dart';
40 | export 'others/utils.dart';
41 | export 'others/zeronet_utils.dart';
42 | export 'others/zeronet_service.dart';
43 | export 'others/zeronet_isolate.dart';
44 | export 'widgets/loading_page.dart';
45 |
--------------------------------------------------------------------------------
/lib/main.dart:
--------------------------------------------------------------------------------
1 | import 'package:zeronet/dashboard/app.dart';
2 | import 'dashboard/imports.dart';
3 |
4 | import 'others/common.dart' as common;
5 |
6 | import 'imports.dart' hide init;
7 | import 'others/common.dart';
8 |
9 | //TODO:Remainder: Removed Half baked x86 bins, add them when we support x86 platform
10 | Future main() async {
11 | WidgetsFlutterBinding.ensureInitialized();
12 | await common.init();
13 | runApp(MyApp());
14 | if (PlatformExt.isDesktop) {
15 | doWhenWindowReady(() {
16 | final win = appWindow;
17 | // const initialSize = Size(600, 450);
18 | // win.minSize = initialSize;
19 | // win.size = initialSize;
20 | // win.position = const Offset(250, 250);
21 | win.title = "ZeroNetX";
22 | win.show();
23 | });
24 | }
25 | }
26 |
27 | class MyApp extends StatelessWidget {
28 | @override
29 | Widget build(BuildContext context) {
30 | if (PlatformExt.isDesktop) initSystemTray();
31 | return GetMaterialApp(
32 | title: 'ZeroNet Mobile',
33 | theme: ThemeData(
34 | primarySwatch: Colors.indigo,
35 | visualDensity: VisualDensity.adaptivePlatformDensity,
36 | ),
37 | debugShowCheckedModeBanner: false,
38 | home: Scaffold(
39 | body: Obx(
40 | () {
41 | var child = (PlatformExt.isDesktop)
42 | ? Obx(
43 | () => Column(
44 | children: [
45 | WindowTitleBarBox(
46 | child: Container(
47 | color: siteUiController
48 | .currentTheme.value.titleBarColor,
49 | child: Row(
50 | mainAxisAlignment: MainAxisAlignment.spaceBetween,
51 | children: [
52 | Expanded(
53 | child: MoveWindow(
54 | child: Container(
55 | color: siteUiController
56 | .currentTheme.value.primaryColor,
57 | ),
58 | ),
59 | ),
60 | Row(
61 | children: [
62 | MinimizeWindowButton(
63 | onPressed: () {
64 | appWindow.minimize();
65 | uiStore.isWindowVisible.value = false;
66 | },
67 | colors: WindowButtonColors(
68 | normal: siteUiController
69 | .currentTheme.value.cardBgColor,
70 | mouseOver: Colors.blueAccent,
71 | mouseDown: Colors.blue,
72 | ),
73 | ),
74 | MaximizeWindowButton(
75 | onPressed: () {
76 | appWindow.maximize();
77 | uiStore.isWindowVisible.value = true;
78 | },
79 | colors: WindowButtonColors(
80 | normal: siteUiController
81 | .currentTheme.value.cardBgColor,
82 | mouseOver: Colors.greenAccent,
83 | mouseDown: Colors.green,
84 | ),
85 | ),
86 | CloseWindowButton(
87 | onPressed: () {
88 | appWindow.hide();
89 | uiStore.isWindowVisible.value = false;
90 | },
91 | colors: WindowButtonColors(
92 | normal: siteUiController
93 | .currentTheme.value.cardBgColor,
94 | mouseOver: Colors.redAccent,
95 | mouseDown: Color(0xFFF44336),
96 | ),
97 | ),
98 | ],
99 | )
100 | ],
101 | ),
102 | ),
103 | ),
104 | Expanded(child: appContent()),
105 | ],
106 | ),
107 | )
108 | : appContent();
109 | if (siteUiController.currentTheme.value == AppTheme.Light) {
110 | return Theme(
111 | data: ThemeData.light(useMaterial3: false),
112 | child: child,
113 | );
114 | } else {
115 | return Theme(
116 | data: ThemeData.dark(useMaterial3: false),
117 | child: child,
118 | );
119 | }
120 | },
121 | ),
122 | ),
123 | );
124 | }
125 |
126 | Obx appContent() {
127 | return Obx(
128 | () {
129 | setSystemUiTheme();
130 | if (varStore.zeroNetInstalled.value) {
131 | init();
132 | return DashboardApp();
133 | } else
134 | return Loading();
135 | },
136 | );
137 | }
138 | }
139 |
--------------------------------------------------------------------------------
/lib/models/enums.dart:
--------------------------------------------------------------------------------
1 | import '../imports.dart';
2 |
3 | enum ZeroNetStatus {
4 | NOT_RUNNING,
5 | INITIALISING,
6 | RUNNING,
7 | RUNNING_WITH_TOR,
8 | ERROR,
9 | }
10 |
11 | enum AppUpdate {
12 | NOT_AVAILABLE,
13 | AVAILABLE,
14 | DOWNLOADING,
15 | DOWNLOADED,
16 | INSTALLING,
17 | }
18 |
19 | extension AppUpdateExt on AppUpdate {
20 | get text {
21 | switch (uiStore.appUpdate.value) {
22 | case AppUpdate.AVAILABLE:
23 | return strController.updateStr.value;
24 | case AppUpdate.DOWNLOADING:
25 | return strController.downloadingStr.value;
26 | case AppUpdate.DOWNLOADED:
27 | return strController.downloadedStr.value;
28 | case AppUpdate.INSTALLING:
29 | return strController.installingStr.value;
30 | default:
31 | return strController.notAvaliableStr.value;
32 | }
33 | }
34 |
35 | void action() {
36 | switch (uiStore.appUpdate.value) {
37 | case AppUpdate.AVAILABLE:
38 | {
39 | // InAppUpdate.performImmediateUpdate().then((value) =>
40 | // uiStore.updateInAppUpdateAvailable(AppUpdate.NOT_AVAILABLE));
41 | InAppUpdate.startFlexibleUpdate().then((value) =>
42 | uiStore.updateInAppUpdateAvailable(AppUpdate.DOWNLOADED));
43 | uiStore.updateInAppUpdateAvailable(AppUpdate.DOWNLOADING);
44 | }
45 | break;
46 | case AppUpdate.DOWNLOADED:
47 | {
48 | InAppUpdate.completeFlexibleUpdate().then((value) =>
49 | uiStore.updateInAppUpdateAvailable(AppUpdate.NOT_AVAILABLE));
50 | uiStore.updateInAppUpdateAvailable(AppUpdate.INSTALLING);
51 | }
52 | break;
53 | default:
54 | }
55 | }
56 | }
57 |
--------------------------------------------------------------------------------
/lib/models/models.dart:
--------------------------------------------------------------------------------
1 | import '../imports.dart';
2 |
3 | class UnzipParams {
4 | String item;
5 | Uint8List bytes;
6 | String dest;
7 | UnzipParams(
8 | this.item,
9 | this.bytes, {
10 | this.dest = '',
11 | });
12 | }
13 |
14 | enum ZNBinaryState {
15 | NOT_DOWNLOADED,
16 | DOWNLOADING,
17 | NOT_INSTALLED,
18 | INSTALLING,
19 | MAKING_AS_EXEC,
20 | READY,
21 | RUNNING,
22 | NONE,
23 | }
24 |
--------------------------------------------------------------------------------
/lib/others/constants.dart:
--------------------------------------------------------------------------------
1 | import '../imports.dart';
2 |
3 | // export 'constants/platform_constants.dart';
4 |
5 | /// [Platform] specific implementation of PathSeparator.
6 | final sep = Platform.pathSeparator;
7 | final exeDir = Directory(Platform.resolvedExecutable).parent.path;
8 | final String pkgName = Directory(
9 | Platform.isAndroid
10 | ? 'in.canews.zeronetmobile${kDebugMode ? '.debug' : ''}'
11 | : exeDir + sep + 'data' + sep + 'app',
12 | ).path;
13 | final String dataDir = Directory(
14 | Platform.isAndroid
15 | ? "${sep}data${sep}data${sep}$pkgName${sep}files"
16 | : pkgName,
17 | ).path;
18 | final String zeroNetDir =
19 | dataDir + sep + (Platform.isWindows ? 'ZeroNet-win' : 'ZeroNet-py3');
20 | final String bin = '$dataDir${sep}usr${sep}bin';
21 | final String python = '$bin${sep}python';
22 | final String libDir = '$dataDir${sep}usr${sep}lib';
23 | final String libDir64 = '$dataDir${sep}usr${sep}lib64';
24 | final String zeronetDir = zeroNetDir;
25 | final String zeronet = '$zeronetDir${sep}zeronet.py';
26 | const String defZeroNetUrl = 'http://127.0.0.1:43110/';
27 | const String downloading = 'Downloading Files';
28 | const String installing = 'Installing ZeroNet Files';
29 | const String facebookLink = 'https://facebook.com';
30 | const String twitterLink = 'https://twitter.com';
31 | const String githubLink = 'https://github.com';
32 | const String rawGithubLink = 'https://raw.githubusercontent.com';
33 | const String canewsInRepo = '/canewsin/ZeroNet';
34 | const String zeromobileRepo = '/canewsin/zeronet_mobile';
35 | const String releases = '$githubLink$canewsInRepo/releases/download/';
36 | const String md5hashLink = '$rawGithubLink$canewsInRepo/py3-patches/md5.hashes';
37 | const String zpatches = '$githubLink$zeromobileRepo/releases/download/patches';
38 | const String zeroNetNotiId = 'zeroNetNetiId';
39 | const String zeroNetChannelName = 'ZeroNet Mobile';
40 | const String zeroNetChannelDes =
41 | 'Shows ZeroNet Notification to Persist from closing.';
42 | const String notificationCategory = 'ZERONET_RUNNING';
43 | const String isolateUnZipPort = 'unzip_send_port';
44 | const String isolateDownloadPort = 'downloader_send_port';
45 | const String zeronetStartUpError = 'Startup error: ';
46 | const String zeronetAlreadyRunningError =
47 | zeronetStartUpError + 'Can\'t open lock file';
48 | const bool kEnableDynamicModules = !kDebugMode;
49 |
50 | const List binDirs = [
51 | 'usr',
52 | 'site-packages',
53 | 'ZeroNet-py3',
54 | ];
55 | const List soDirs = [
56 | 'usr/bin',
57 | 'usr/lib',
58 | 'usr/lib/python3.8/lib-dynload',
59 | 'usr/lib/python3.8/site-packages',
60 | ];
61 |
62 | const List filterFileNames = [
63 | 'sites-miners.json',
64 | 'sites-porn.json',
65 | 'users-porn.json',
66 | 'users-spamlist.json',
67 | ];
68 |
--------------------------------------------------------------------------------
/lib/others/extensions.dart:
--------------------------------------------------------------------------------
1 | import 'package:zeronet/imports.dart';
2 |
3 | extension FileSystemExtension on FileSystemEntity {
4 | String get name => this.path.replaceFirst(this.parent.path + '/', '');
5 | }
6 |
7 | extension CapExtension on String {
8 | String get inCaps => '${this[0].toUpperCase()}${this.substring(1)}';
9 | String get allInCaps => this.toUpperCase();
10 | String get capitalizeFirstofEach =>
11 | this.split(" ").map((str) => str.inCaps).join(" ");
12 | String get zeroNetDataPath => getZeroNetDataDir().path + '/' + this + '/';
13 | }
14 |
15 | extension DynamicExt on dynamic {
16 | int? toInt() {
17 | if (this is num) {
18 | if (this is double) return this.toInt();
19 | if (this is int) return this;
20 | }
21 | return -1;
22 | }
23 | }
24 |
25 | extension PlatformExt on Platform {
26 | static get isDesktop =>
27 | (Platform.isWindows || Platform.isLinux || Platform.isMacOS);
28 | static get isMobile => (Platform.isAndroid || Platform.isIOS);
29 |
30 | static get isSupportedDesktop => (Platform.isWindows);
31 | static get isSupportedMobile => (Platform.isAndroid);
32 |
33 | static get isSupported => (isSupportedDesktop || isSupportedMobile);
34 | }
35 |
36 | extension DownloadTaskkExt on int {
37 | /// Creates a new [DownloadTaskStatus] from an [int].
38 | DownloadTaskStatus get intoDownloadTaskStatus {
39 | switch (this) {
40 | case 0:
41 | return DownloadTaskStatus.undefined;
42 | case 1:
43 | return DownloadTaskStatus.enqueued;
44 | case 2:
45 | return DownloadTaskStatus.running;
46 | case 3:
47 | return DownloadTaskStatus.complete;
48 | case 4:
49 | return DownloadTaskStatus.failed;
50 | case 5:
51 | return DownloadTaskStatus.canceled;
52 | case 6:
53 | return DownloadTaskStatus.paused;
54 | default:
55 | throw ArgumentError('Invalid value: $this');
56 | }
57 | }
58 | }
59 |
--------------------------------------------------------------------------------
/lib/others/native.dart:
--------------------------------------------------------------------------------
1 | import '../imports.dart';
2 |
3 | const MethodChannel _channel = const MethodChannel('in.canews.zeronetmobile');
4 | const EventChannel _events_channel =
5 | const EventChannel('in.canews.zeronetmobile/installModules');
6 |
7 | Future addToHomeScreen(
8 | String title,
9 | String? url,
10 | String logoPath,
11 | ) async =>
12 | await _channel.invokeMethod('addToHomeScreen', {
13 | 'title': title,
14 | 'url': url,
15 | 'logoPath': logoPath,
16 | });
17 |
18 | Future launchZiteUrl() async =>
19 | await _channel.invokeMethod('launchZiteUrl');
20 |
21 | Future askBatteryOptimisation() async =>
22 | await _channel.invokeMethod('batteryOptimisations');
23 |
24 | Future isPlayStoreInstall() async =>
25 | await _channel.invokeMethod('isPlayStoreInstall');
26 |
27 | Future isBatteryOptimised() async =>
28 | await _channel.invokeMethod('isBatteryOptimized');
29 |
30 | Future saveUserJsonFile(String path) async =>
31 | await _channel.invokeMethod('saveUserJsonFile', path);
32 |
33 | Future moveTaskToBack() async =>
34 | await _channel.invokeMethod('moveTaskToBack');
35 |
36 | Future isModuleInstallSupported() async =>
37 | await _channel.invokeMethod('isModuleInstallSupported');
38 |
39 | Future isRequiredModulesInstalled() async =>
40 | await _channel.invokeMethod('isRequiredModulesInstalled');
41 |
42 | Future copyAssetsToCache() async =>
43 | await _channel.invokeMethod('copyAssetsToCache');
44 |
45 | Future getAppInstallTime() async =>
46 | await _channel.invokeMethod('getAppInstallTime');
47 |
48 | Future getAppLastUpdateTime() async =>
49 | await _channel.invokeMethod('getAppLastUpdateTime');
50 |
51 | Future initSplitInstall() async =>
52 | await _channel.invokeMethod('initSplitInstall');
53 |
54 | void uninstallModules() async =>
55 | await _channel.invokeMethod('uninstallModules');
56 |
57 | void nativePrint(String log) => _channel.invokeMethod('nativePrint', log);
58 |
59 | getNativeDir() async => await _channel.invokeMethod('nativeDir');
60 |
61 | void handleModuleDownloadStatus() {
62 | _events_channel.receiveBroadcastStream().listen((onData) {
63 | Map data = json.decode(onData);
64 | final status = data['status'];
65 | if (status == 2) {
66 | final downloaded = data['downloaded'];
67 | final total = data['total'];
68 | double percentage = downloaded / total;
69 | varStore.setLoadingPercent(percentage.toInt());
70 | }
71 | printOut(onData, lineBreaks: 2, isNative: true);
72 | if (status == 5) check();
73 | });
74 | }
75 |
76 | String? filePath = '';
77 | Future getUserJsonFile() async {
78 | String? uri;
79 | try {
80 | if (deviceInfo!.version.sdkInt > 28) {
81 | uri = await _channel.invokeMethod('openJsonFile');
82 | //!TODO Fix This await FlutterAbsolutePath.getAbsolutePath(uri!);
83 | filePath = uri;
84 | } else {
85 | uri = (await pickUserJsonFile())!.path;
86 | filePath = uri;
87 | }
88 | String path = await (_channel.invokeMethod(
89 | 'readJsonFromUri',
90 | uri,
91 | ));
92 | return File(path);
93 | } catch (e) {
94 | if (e is PlatformException && e.code == '526') {
95 | return null;
96 | }
97 | return null;
98 | }
99 | }
100 |
101 | Future getPluginZipFile() async {
102 | String? uri;
103 | if (deviceInfo!.version.sdkInt > 28) {
104 | try {
105 | uri = await _channel.invokeMethod('openZipFile');
106 | //TODO! Fix this filePath = await FlutterAbsolutePath.getAbsolutePath(uri!);
107 | filePath = uri;
108 | } catch (e) {
109 | if (e is PlatformException) {
110 | if (e.code == '527') {
111 | return null;
112 | }
113 | }
114 | }
115 | } else {
116 | uri = (await pickPluginZipFile())!.path;
117 | filePath = uri;
118 | }
119 | String path = await (_channel.invokeMethod(
120 | 'readZipFromUri',
121 | uri,
122 | ) as FutureOr);
123 | return File(path);
124 | }
125 |
126 | getArch() async {
127 | if (!PlatformExt.isMobile) {
128 | return 'x86_64';
129 | }
130 | if (deviceInfo == null) deviceInfo = await DeviceInfoPlugin().androidInfo;
131 | String archL = deviceInfo!.supportedAbis[0];
132 | if (archL.contains('arm64'))
133 | arch = 'arm64';
134 | else if (archL.contains('armeabi'))
135 | arch = 'arm';
136 | else if (archL.contains('x86_64'))
137 | arch = 'x86_64';
138 | else if (archL.contains('x86')) arch = 'x86';
139 | }
140 |
--------------------------------------------------------------------------------
/lib/others/zeronet_service.dart:
--------------------------------------------------------------------------------
1 | import 'package:flutter_background_service_android/flutter_background_service_android.dart';
2 | import 'package:zeronet/imports.dart';
3 |
4 | class ZeroNetService {
5 | late FlutterBackgroundService _service;
6 | late StreamController