From 98fbf8a12ecc1657e576a1b62c7952d2a0b1eea3 Mon Sep 17 00:00:00 2001 From: Matthew Nelson <developer@matthewnelson.io> Date: Sun, 18 Oct 2020 07:14:22 -0400 Subject: [PATCH] Prepare 2.0.0 release --- docs/changelog.md | 8 +++++++ docs/get_started.md | 55 ++++++++++++++++++++++++++++++++------------- docs/roadmap.md | 12 +++++----- gradle.properties | 6 +++-- mkdocs.yml | 4 ++-- 5 files changed, 59 insertions(+), 26 deletions(-) diff --git a/docs/changelog.md b/docs/changelog.md index 1ef6d2bc..d9fec2d3 100644 --- a/docs/changelog.md +++ b/docs/changelog.md @@ -1,5 +1,13 @@ # Change Log +## Version 2.0.0 (2020-10-18) + - Adds support for Version 3 Hidden Service Client Authentication + - The `V3ClientAuthManager` class can be obtained from `TorServiceController.getV3ClientAuthManager` + after Builder initialization, which facilitates easily adding private keys to Tor's `ClientAuthDir`. + - Adds better support for multi-module projects by moving `topl-service`'s public + classes/abstractions to a separate module, `topl-service-base`. + - See [Migrations](./migration.md) for details on how to migrate from `1.0.0` to `2.0.0` + ## Version 1.0.0-beta02 (2020-10-08) - Bug Fix: Service re-binding when application sent to background inhibiting call to stopSelf in some instances [a544c73](https://github.com/05nelsonm/TorOnionProxyLibrary-Android/pull/85/commits/a544c73a7c28211c75063df6af30001f2ec1c071) diff --git a/docs/get_started.md b/docs/get_started.md index 1efc1596..8a9470b3 100644 --- a/docs/get_started.md +++ b/docs/get_started.md @@ -19,25 +19,29 @@ Get Started - Your application's `torrc` file gets created for you based on what you have stored in [TorServicePrefs](./topl-service-base/io.matthewnelson.topl_service_base/-tor-service-prefs/index.md). If nothing is in `TorServicePrefs` for that particular setting, then it will fall back on - your static/default [TorSettings](./topl-core-base/io.matthewnelson.topl_core_base/-tor-settings/index.md) + your static/default + [ApplicationDefaultTorSettings](./topl-service-base/io.matthewnelson.topl_service_base/-application-default-tor-settings/index.md) that you supply upon initialization of `TorServiceController.Builder`. - **Tor Binaries**: - I use The GuardianProject's <a href="https://github.com/guardianproject/tor-android" target="_blank">tor-android</a> - project to build binaries, and provided them - <a href="https://github.com/05nelsonm/TOPL-Android-TorBinary" target="_blank">here</a>. The - difference is in how they are packaged as a dependency, and the contents of what you are - importing as a dependency. I package them in the `jniLibs` directory so that the Android OS - will automatically install them into your application's `/data/app/...` directory, and include - no unnecessary classes or resources; just the binaries. Android API 29+ no longer supports - execution of executable files from your application's `/data/data/` directory, and must now be - installed in the `context.applicationInfo.nativeLibraryDir` directory (aka, `/data/app/...`) - to execute. + project to re-package and provide *only* the binaries, as that's all which is needed by + TOPL-Android. As of version 0.4.4.0, the binaries are simply copied instead of being + re-built (prior versions I was building, but build reproducability is problematic...) which can + be verified by checking the sha256sums (see the repo's README for instructions on how to do that). + - They can be found <a href="https://github.com/05nelsonm/TOPL-Android-TorBinary" target="_blank">here</a>. + - The only difference is the contents of what you are importing as a dependency. I package + them in the `jniLibs` directory so that the Android OS will automatically extract them to + your application's `/data/app/...` directory, and include no unnecessary classes or + resources; just the binaries. + - Android API 29+ no longer supports execution of executable files from your application's + `/data/data/` directory, and must now be installed in the + `context.applicationInfo.nativeLibraryDir` directory (aka, `/data/app/...`) to execute. - Nothing more is needed in terms of configuring initialization via the - `TorServiceController.Builder`, as files will be installed in the correct directory, and - named to match what `topl-service` looks for. - - If you wish to use GuardianProject's binaries, see + `TorServiceController.Builder.useCustomTorConfigFiles`, as files will be installed in the + correct directory, and named to match what `topl-service` looks for. + - If you wish to use GuardianProject's dependency, see <a href="https://github.com/guardianproject/tor-android" target="_blank">tor-android</a>. - - You'll need to use their `NativeResouceInstaller` to install the binaries. + - You'll need to use their `NativeResourceInstaller` to install the binaries. - You'll need to also implement `TorServiceController.Builder.useCustomTorConfigFiles` method when initializing `topl-service` and provide it with your own [TorConfigFiles](./topl-core-base/io.matthewnelson.topl_core_base/-tor-config-files/index.md). @@ -59,18 +63,37 @@ Get Started implementation "io.matthewnelson.topl-android:topl-service:{{ topl_android.release }}" ``` - - Create a new class which extends [TorSettings](./topl-core-base/io.matthewnelson.topl_core_base/-tor-settings/index.md) + - Create a new class which extends [ApplicationDefaultTorSettings](./topl-service-base/io.matthewnelson.topl_service_base/-application-default-tor-settings/index.md) and apply your own default settings. - See the SampleApp's - <a href="https://github.com/05nelsonm/TorOnionProxyLibrary-Android/blob/master/sampleapp/src/main/java/io/matthewnelson/sampleapp/topl_android/MyTorSettings.kt" target="_blank">MyTorSettings</a> + <a href="https://github.com/05nelsonm/TorOnionProxyLibrary-Android/blob/master/sampleapp/src/main/java/io/matthewnelson/sampleapp/topl_android/MyTorSettings.kt" target="_blank">MyTorSettings</a> class for help. - Also checkout the documentation in the `TorSettings` class for more of a breakdown and help. + + - Optional: If you wish to receive broadcasts (TorState/NetworkState, Port Information, Logs, etc.), + Create a new class which extends [TorServiceEventBroadcaster](./topl-service-base/io.matthewnelson.topl_service_base/-tor-service-event-broadcaster/index.md) + and implement the abstract methods. + - See the SampleApp's + <a href="https://github.com/05nelsonm/TorOnionProxyLibrary-Android/blob/master/sampleapp/src/main/java/io/matthewnelson/sampleapp/topl_android/MyEventBroadcaster.kt" target="_blank">MyEventBroadcaster</a> + class for help. + - Use the [TorServiceController.Builder.setEventBroadcaster](./topl-service/io.matthewnelson.topl_service/-tor-service-controller/-builder/set-event-broadcaster.md) + and provide your implementation when initializing `topl-service`. - In your Application class' `onCreate` implement, and customize as desired, the [TorServiceController.Builder](./topl-service/io.matthewnelson.topl_service/-tor-service-controller/-builder/index.md) - Call APIs provided from [TorServiceController.Companion](./topl-service/io.matthewnelson.topl_service/-tor-service-controller/index.md) + +### Multi-Module projects + - If you have a `tor` module in your project that extends the api's in `TorServiceController` to centralize + control of `topl-service`, other modules depending on it need only import the `topl-service-base` + module which provides all of the necessary public classes/abstractions. + + - In your `tor` module's `build.gradle` file, add the following to the `dependencies` block: + ```groovy + api "io.matthewnelson.topl-android:topl-service-base:{{ topl_android.release }}" + ``` ### Using the SNAPSHOT version of topl-service diff --git a/docs/roadmap.md b/docs/roadmap.md index 42d376d7..f5654e01 100644 --- a/docs/roadmap.md +++ b/docs/roadmap.md @@ -5,11 +5,11 @@ <!-- Unchecked = :material-checkbox-blank-outline: --> :material-checkbox-marked: Alpha release - :material-checkbox-blank-outline: Pass-through commands to the TorControlConnection - :material-checkbox-blank-outline: Settings/Debug Activity (so devs don't have to create one if they don't wish to) - :material-checkbox-marked: Builder Option to disable stop service on task termination - :material-checkbox-blank-outline: Transport Plugin support - :material-checkbox-blank-outline: v3 Hidden Service Authentication support - :material-checkbox-blank-outline: v3 Hidden Service Creation + :material-checkbox-marked: Builder Option to disable stop service on task termination + :material-checkbox-marked: v3 Hidden Service Client Authentication support + :material-checkbox-blank-outline: Pass-through commands to the TorControlConnection + :material-checkbox-blank-outline: Transport Plugin support + :material-checkbox-blank-outline: v3 Hidden Service Creation + :material-checkbox-blank-outline: Settings/Debug Activity (so devs don't have to create one if they don't wish to) [back](index.md) diff --git a/gradle.properties b/gradle.properties index 3466e966..bcca06d2 100644 --- a/gradle.properties +++ b/gradle.properties @@ -7,6 +7,8 @@ # Specifies the JVM arguments used for the daemon process. # The setting is particularly useful for tweaking memory settings. org.gradle.jvmargs=-Xmx2048m +org.gradle.caching=true + # When configured, Gradle will run in incubating parallel mode. # This option should only be used with decoupled projects. More details, visit # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects @@ -21,13 +23,13 @@ android.enableJetifier=true kotlin.code.style=official GROUP=io.matthewnelson.topl-android -VERSION_NAME=1.1.0-alpha01c-SNAPSHOT +VERSION_NAME=2.0.0 # The trailing 2 digits are for `alpha##` releases. For example: # 4.4.1-alpha02 = 441102 where `102` stands for alpha02 # 4.4.1-beta01 = 441201 where `201` stands for beta01 # 4.4.1-rc01 = 441301 where `301` stands for rc01 -VERSION_CODE=110101 +VERSION_CODE=200000 POM_INCEPTION_YEAR=2020 diff --git a/mkdocs.yml b/mkdocs.yml index 0115146d..3bad2f3e 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -1,7 +1,7 @@ extra: topl_android: - release: '1.0.0-beta02' - next_release: '1.0.0-rc01' + release: '2.0.0' + next_release: '2.0.1' social: - icon: material/earth link: https://matthewnelson.io