- Fixes
TorListeners.Manager
not clearing old address references in some cases whenAction.RestartDaemon
is executed [#549]
- Complete codebase refactor starting with PR [#308] to [#546]
- Migrated all publication coordinates to start with
io.matthewnelson.kmp-tor
- e.g.
io.matthewnelson.kmp-tor:runtime:2.0.0-alpha01
- e.g.
- Added
dokka
documentation athttps://kmp-tor.matthewnelson.io
- Added Java9
module-info.java
support for all publications - Added support for targets:
js
(Node.js
)linuxArm64
linuxX64
iosArm64
iosSimulatorArm64
iosX64
macosArm64
macosX64
- Decoupled
kmp-tor
fromtor
compilation dependency in order to support split release cycles.kmp-tor
is now a "runtime" that "loads"tor
resources via thekmp-tor-common
repository's abstraction forResourceLoader
. - Added ability for API consumers to choose how to run tor (executable process, or natively).
- Rebuilt
TorService
for Android for better optionality and customization via theruntime-service
andruntime-service-ui
feature modules. - Updated all dependencies for Kotlin
1.9.24
compatibility. - Reworked event
Listener
API to be single purposed; they are now calledObservers
that are subscribed/unsubscribed. - Reworked all APIs to support Callback, Async (coroutines), and Sync (Android/Jvm/Native) functionality.
- Reworked tor control spec APIs to be single interface with multiple sealed data types
to better support future expansion/features (i.e. the
TorCmd
types). - Reworked error handling via
UncaughtException.Handler
APIs and callbacks. - Everything (mostly) uses a Builder pattern and has a DSL.
- Tons more.
- Add deprecation notice to
TorManager
in preparation for2.0.0
release. - Disable non-Android & non-Jvm targets
- Updates dependencies
kmp-tor-binary
->4.8.10-0
- Updates dependencies
atomicfu
->0.21.0
coroutines
->1.7.3
kotlin
->1.9.10
jnr-unix-socket
->0.38.21
kmp-tor-binary
->4.8.6-0
- Fixes start failure when
UnixSocket
path length exceeded 105 characters [#304] - Removed gradle.property
kotlin.mpp.enableCompatibilityMetadataVariant
- Updates dependencies
atomicfu
->0.20.2
coroutines
->1.7.1
encoding
->2.0.0
kotlin
->1.8.21
jnr-unix-socket
->0.38.20
- Fixes JPMS split package errors attributed to encoding library
- Updates KmpTorBinary
4.7.13-3
->4.7.13-4
- Actually fixes issue with Java 9 modularization not being able to extract resources. [kmp-tor-binary-#76]
- Fixes an issue with coroutine dispatcher threads executing in userspace
instead of application JVM whereby closing of the application was inhibited
if
TorManager.destroy
was not called. [#294]
- Updates KmpTorBinary
4.7.13-2
->4.7.13-3
- Fixed an issue with Java 9 modularization and not being able to load resources. [kmp-tor-binary-#75]
- Moves process id retrieval to call-site in
kmp-tor
module and removes its dependency onkmp-tor-internal
module. [#289]- The
kmp-tor-internal
dependency will still be published as to not break anyone's project if they had it as a dependency, but it will cease to be published on next major version release (2.0.0
) and should be removed.
- The
- Updates KmpTorBinary
4.7.13-1
->4.7.13-2
- Intermediate fix for JVM
macOS aarch64
binaries failing to execute - More information can be found in [#285] and [kmp-tor-binary-#66]
- Intermediate fix for JVM
- Update Kotlin
1.8.0
->1.8.10
- Update AtomicFu
0.19.0
->0.20.0
- Adds ability for library consumers to package and load their own Tor binary resources (Jvm/JS) [#284]
- Refactors gradle build system to use composite builds [#283]
- Removes submodule
kotlin-components
- Removes submodule
- Fixes
Destroyeable.onDestroy
invocation ofonCompletion
lambda only being invoked ifTorManager
was not yet destroyed. NowonCompletion
is always invoked, regardless of whetherTorManager
is already destroyed. - Updates KmpTorBinary
4.7.12-2
->4.7.13-0
- Updates
kotlin-components
submodule- Encoding
1.1.5
->1.2.1
- Updates deprecated encoding APIs
- Publication improvements
- Encoding
- Adds caching to CI
- Updates
kotlin-components
submodule- Kotlin
1.6.21
->1.8.0
- Android Gradle Plugin
7.0.4
->7.3.1
- AtomicFu
0.17.3
->0.19.0
- Coroutines
1.6.3
->1.6.4
- KmpTorBinary
4.7.12-0
->4.7.12-2
- Encoding
1.1.3
->1.1.5
- Parcelize
0.1.0
->0.1.2
- JnrUnixSocket
0.38.17
->0.38.19
- Kotlin
- Android
- Increases
compileSdk
from32
->33
- Updates internally utilized APIs that have been deprecated
- Internal code clean up
- Increases
- Enables support for using Unix Domain Sockets on darwin
- Adds JDK 16+ support for Unix Domain Sockets
- Extension
kmp-tor-ext-unix-socket
is now only needed when running JDK 15 and below if you want to use Unix Domain Sockets.
- Extension
- Bumps
kmp-tor-binary
from4.7.11-0
->4.7.12-0
- Bumps
kmp-tor-binary
from4.7.10-1
->4.7.11-0
- Updates
kotlin-components
submodule to latest commit- Documentation + publishing improvements
- Bumps
kmp-tor-binary
from0.4.7.10
->4.7.10-1
- Tor version stayed the same but was a sub-release of
kmp-tor-binary
which contained improvements and changes for supporting Kotlin/JS in the near future
- Tor version stayed the same but was a sub-release of
- Adds support for
macOS arm64
forJava
projects- See the
kmp-tor-binary
projectREADME
'sJava
section
- See the
- Reworks internals for extracting binary/geoip files to use new method
provided by
kmp-tor-binary
sub-release - Changes the project's version scheme to be compliant with
npmjs
publication so support in the very near future can be had- Ex:
4.7.10 - 1 - 1.3.1
tor
version0.4.7.10
kmp-tor-binary
sub-release1
kmp-tor
release1.3.1
- Ex:
- Bumps
kotlin-components
submodule to latest commit- Build + publishing improvements
- Bumps Tor from
0.4.7.8
->0.4.7.10
- Refactors Android instantiation of
TorController
when using unix domain sockets (i.e.LocalSocket
).- Allows for
minSdk
to be reduced from19
->16
for moduleskmp-tor-controller
kmp-tor-manager
kmp-tor-ext-callback-controller
kmp-tor-ext-callback-manager
- Allows for
-
kmp-tor-common
module:- Adds base
Address
interface for all*Address
classes to inherit from.OnionAddress
now implementsAddress
.
- Adds
IPAddress
,IPAddressV4
, andIPAddressV6
to support modeling of IP addresses. - Refactors
ProxyAddress
to now useIPAddress
as a constructor argument instead ofString
. - Refactors
ProxyAddress
toclass
instead ofdata class
. - Improves URL parsing when using
fromString
methods for*Address
classes. - DEPRECATIONS:
OnionAddress.valueDotOnion
in favor ofcanonicalHostname()
ProxyAddress.component1()
in favor ofaddress.value
ProxyAddress.component2()
in favor ofport
ProxyAddress.ipAddress
in favor ofaddress.value
ProxyAddress
constructor which takesipAddress: String
in favor of constructor which takesaddress: IPAddress
.ProxyAddress.copy
which usesipAddress: String
in favor ofcopy()
,copy(address: IPAddress)
, andcopy(port: Port)
methods.Server.Fingerprint.valueWithPrefix
in favor ofcanonicalName()
OnionUrl
class is now deprecatedScheme
enum is now deprecated
- Adds base
-
kmp-tor-controller-common
module:- Adds
TorConfig.KeyWord.VirtualAddrNetworkIPv4
- Adds
TorConfig.Setting.VirtualAddrNetworkIPv4
to configure non-default IPv4 network ranges when mapping addresses. - Adds
TorConfig.Setting.VirtualAddrNetworkIPv6
to configure non-default IPv6 network ranges when mapping addresses. - Implements
TorControlMapAddress.mapAddress
- Implements
TorControlResolve.resolve
- Adds
-
kmp-tor-ext-callback-controller-common
module:- Implements
CallbackTorControlMapAddress.mapAddress
- Implements
CallbackTorControlResolve.resolve
- Implements
- Fixes
-android
publication for*-common
modules
- Adds
-android
variants to all*-common
modules - Adds dependency on
io.matthewnelson.kotlin-components:parcelize
- Implements
android.os.Parcelable
for wrapper classes within thekmp-tor-common
module. - Build improvements
-
Optimized
TorEvent.Listener
-
Adds remaining
TorConfig.KeyWord
s- DEPRECATIONS:
TorConfig.KeyWord.GeoIpV4File
was deprecated in favor ofTorConfig.KeyWord.GeoIPFile
TorConfig.KeyWord.OwningControllerProcess
was deprecated in favor ofTorConfig.KeyWord.__OwningControllerProcess
TorConfig.Setting.GeoIpV4File
was deprecated in favor ofTorConfig.Setting.GeoIPFile
TorConfig.Setting.OwningControllerProcess
was deprecated in favor ofTorConfig.Setting.__OwningControllerProcess
- DEPRECATIONS:
-
Adds ability to pass
HiddenService.UnixSocket
when adding aHiddenService
via the control port.- BREAKING CHANGE (Minor):
TorControlOnionAdd
interface methods were changed to acceptSet<HiddenService.VirtualPort>
, whereas before they accepted onlySet<HiddenService.Ports>
.HiddenService.Ports
andHiddenService.UnixSocket
both extendHiddenService.VirtualPort
.
- BREAKING CHANGE (Minor):
-
Refactored/cleaned up internals
-
CI/Build improvements
- Updates
atomicfu
dependency from0.17.2
->0.17.3
- Updates
coroutines
dependency from1.6.1
->1.6.3
- Updates
encoding
dependency from1.1.2
->1.1.3
- Updates
kmp-tor-binary
dependency from0.4.7.7
->0.4.7.8
- Re-enable compiler flag
kotlin.mpp.enableCompatibilityMetadataVariant=true
to support non-hierarchical projects. (sorry...) - Adds
android
source set tokmp-tor-controller
andkmp-tor-ext-callback-controller
modules - Increases
minSdk
from16
->19
onandroid
source sets forkmp-tor-controller
,kmp-tor-ext-callback-controller
,kmp-tor-manager
, andkmp-tor-ext-callback-tor-manager
modules - Optimizes internal coroutine usage
- Adds use of atomics to
TorConfig.Setting
classes- See BREAKING CHANGES
- Adds
TorManager.KeyWord
classes to decouple them from needing aTorConfig.Setting
to use- See BREAKING CHANGES
- Adds Unix Domain Socket support on Linux (and Android) for:
ControlPort
viaTorConfig.Setting.UnixSockets.Control
SocksPort
viaTorConfig.Setting.UnixSockets.Socks
HiddenServicePort
viaTorConfig.Setting.HiddenService.UnixSocket
- Adds
TorManagerEvent.AddressInfo.unixSocks
argument specifically for when configuring aSocksPort
as a unix domain socket - Adds new common code apis to instantiate a TorController connection using:
- a
Path
(for a Unix Domain Socket) - a
ProxyAddress
(for a TCP connection)
- a
- Fixes
TorManager
's internal comparison of disconnectedTorController
to held reference when shutting down. - Fixes setting multiple virtual ports of the same value for a
TorConfig.Setting.HiddenService
- Fixes
TorConfig.Builder.build
where an improperly configured setting that was not written toTorConfig.text
was still being added to theTorConfig.settings
- Fixes issue on Windows when adding a
TorConfig.Setting.HiddenService
viaTorController
, where the path was not properly escaped - Fixes
Path.toString()
. Now returns thevalue
instead ofPath(value=/some/path)
- Fixes
TorManager
startup operations by callingsetEvents
afterconfigLoad
to mitigate unnecessary dispatching ofCONF_CHANGED
events - Fixes a bug on android where API < 26 where, for some
TorService
configurations resulted in a notification not being removed when the service was stopped while task was removed. - Removes default overloads from
TorControl*
use case interfaces- See BREAKING CHANGES
- Modified
TorControlConfigGet
andTorControlConfigReset
to useTorConfig.KeyWord
s- See BREAKING CHANGES
BREAKING CHANGES
KmpTorLoader
- Note that these changes will only affect library consumers if they
had their own implementations of
KmpTorLoader
and were not using those provided via thekmp-tor
dependency. KmpTorLoader.io
constructor argument was removedKmpTorLoader.setHiddenServiceDirPermissions
method name was changed tosetUnixDirPermissions
KmpTorLoader.excludeSettings
type was changed fromSet<TorConfig.Setting<*>>
toSet<TorConfig.KeyWord>
- Note that these changes will only affect library consumers if they
had their own implementations of
TorConfig
TorConfig.keyword
type was changed fromString
toTorConfig.KeyWord
TorConfig.Setting.HiddenService.ports
type was changed fromTorConfig.Setting.HiddenService.Ports
toTorConfig.Setting.HiddenService.VirtualPort
ControllerUtils
was renamed toPlatformUtil
- Note that all methods were annotated with
InternalTorApi
(and still are)
- Note that all methods were annotated with
TorControlConfigGet.configGet()
was changed from accepting aTorConfig.Setting<*>
, to accepting aTorConfig.KeyWord
TorControlConfigReset.configReset()
was changed from accepting aTorConfig.Setting<*>
to accepting aTorConfig.KeyWord
CallbackTorControlConfigGet.configGet()
was changed from accepting aTorConfig.Setting<*>
, to accepting aTorConfig.KeyWord
CallbackTorControlConfigReset.configReset()
was changed from accepting aTorConfig.Setting<*>
to accepting aTorConfig.KeyWord
TorControlConfigSave.configSave
overloads were removedTorControlOnionAdd.onionAdd
overloads were removedTorControlOnionAdd.onionAddNew
overloads were removedTorControlSetEvents.setEvents
argumentextended
was removed (obsoleted by Tor)CallbackTorControlConfigSave.configSave
overloads were removedCallbackTorControlOnionAdd.onionAdd
overloads were removedCallbackTorControlOnionAdd.onionAddNew
overloads were removed- Java only users:
AddressInfo.isNull()
method changed toisNull
propertyTorConfig.Setting.value
method changed fromgetValue()
tovalue()
TorConfig.Setting.isMutable
method changed fromgetIsMutable()
toisMutable()
TorConfig.Setting.default
method changed fromgetDefault()
to propertydefault
TorConfig.Setting.isDefault
method changed fromgetIsDefault()
toisDefault()
TorConfig.Setting.HiddenService.ports
method changed fromgetPorts()
toports()
TorConfig.Setting.HiddenService.maxStreams
method changed fromgetMaxStreams()
tomaxStreams()
TorConfig.Setting.HiddenService.maxStreamsCloseCircuit
method changed fromgetMaxStreamsCloseCircuit()
tomaxStreamsCloseCircuit()
TorConfig.Setting.Ports.Dns.isolationFlags
method changed fromgetIsolationFlags()
toisolationFlags()
TorConfig.Setting.Ports.HttpTunnel.isolationFlags
method changed fromgetIsolationFlags()
toisolationFlags()
TorConfig.Setting.Ports.Socks.flags
method changed fromgetFlags()
toflags()
TorConfig.Setting.Ports.Socks.isolationFlags
method changed fromgetIsolationFlags()
toisolationFlags()
TorConfig.Setting.Ports.Trans.isolationFlags
method changed fromgetIsolationFlags()
toisolationFlags()
- Implements Controller use case for
HSFETCH
- Fixes
TorController
's mapping of multi-line responses to single-line- Prior versions used a space instead of new line character
- WARNING: This is potentially a breaking change
- Fixes
TorControlConfigGet.configGet
return type- Now returns a
List<String>
instead of aString
- Method that took a single
TorConfig.Setting
previously returned a singleString
. This was incorrect because the setting could potentially be expressed multiple times (i.e. SOCKSPort, HiddenServiceDir, etc.) - WARNING: This is potentially a breaking change.
- Now returns a
- Fixes
configGet
,configSet
, andconfigReset
functionality.- Previously, only the
TorConfig.Setting.value
was being taken into account where someTorConfig.Setting
s has additional parameters (such as Flags) that weren't being passed to the controller. TorConfig.Setting.HiddenService
onlyHiddenServiceDir
keyword was being queried (configGet
) or set (configSet
,configReset
).- WARNING: This is potentially a breaking change.
- Previously, only the
- Fixes
kmp-tor
module'sminSdk
for Android- Tor version
0.4.7.7
for Android no longer works for sdks16-20
like prior versions did. - WARNING: This is potentially a breaking change.
- Tor version
- Adds
JvmField
annotations toTorConfigProvider.ValidatedTorConfig
arguments- WARNING: This is potentially a breaking change for Java users.
- Fixes
TorControlConfigLoad.configLoad
functionality- Previously, the passed config would be loaded but Tor would
not honor the settings if they were used at initial startup.
Starting Tor now only uses the minimum required arguments from
the provided config and then immediately calls
LOADCONF
to load remaining ones. Future calls toconfigLoad
now reset Tor to the initial arguments it was started with, and then will load the additional settings.
- Previously, the passed config would be loaded but Tor would
not honor the settings if they were used at initial startup.
Starting Tor now only uses the minimum required arguments from
the provided config and then immediately calls
- Updates Kotlin-Components
- Bumps
component-encoding
from1.1.1
->1.1.2
- Support new targets for
*-common
modules:iosArm32
iosSimulatorArm64
tvosSimulatorArm64
watchosx86
watchosSimulatorArm64
- Bumps
- Updates Kotlin-Components
kotlin
from1.6.10
->1.6.21
atomicfu
from0.7.1
->0.7.2
coroutines
from1.6.0
->1.6.1
tor-bianry
from0.4.6.10
->0.4.7.7
component-encoding
from1.1.0
->1.1.1
- Significant improvements for Java users (library is now usable from Java land):
- Removes from public APIs all use of
JvmInline
value classes by use of sealed interfaces (ie.SealedValueClass
) w/o disrupting existing APIs. - Adds new
SealedValueClass
annotation as anExperimentalTorApi
. - Adds New
Callback
extension libraries for wrappingTorManager
andTorController
implementations in callbacks (for non-coroutine users). - Sample improvements.
- Fixes all usage of
JvmName
,JvmField
,JvmStatic
annotations.
- Removes from public APIs all use of
- Fixes
PlatformInstaller
whenInstallOption.CleanInstallFirstStartOnly
was elected for while re-using thePlatformInstaller
across multiple instances ofTorManager
. - Disables not yet implemented multiplatform targets for non-common modules.
- Updates Kotlin-Components (publishing tool updates).
- Improvements to Multi-instance performance
- Makes
NetworkObserver
reusable with multiple instances - Adds
decode
method toOnionAddress
interface for obtaining the address in raw bytes - Improves Java compatibility by adding
JvmField
andJvmName
annotations where applicable - Fixes dispatching of bootstrap completion events
- Fixes error returned for
AddOnion
if flagDiscardPK
was not passed
- Added to Jvm and Js the ability to manage multiple instances of
TorManager
- See new
TorMultiInstanceManager
class injvmJsCommonMain
source set.
- See new
- Added to Android's TorServiceConfig the option to call
exitProcess
for Foreground Service operations in the eventTorManager.destroy
completes and the application Task has been removed (user swiped the app from recent app's tray) - Added to
TorStateManager
interface theaddressInfo
property getter, so attached listeners do not always need to store the value locally once dispatched. - Fixes localhost ip address resolution (may not be
127.0.0.1
on some machines) - Fixes
HiddenService.Ports
equals/hashCode to only take into account thevirtualPort
argument as to disallow multiple virtual ports of the same value to be expressed. - Internal code clean up
- Added ability to declare HiddenServices via the
TorConfig.Builder
and theTorController
. - Added new
TorManagerEvent.StartUpCompleteForTorInstance
that is dispatched to registered listeners in order to proc 1 time startup events. - Added new
PortUtil
helper class for checking/finding port availability - Internal performance tweaks to
TorController
andTorManager
- Fixes how
TorController
parsesConfChanged
events. - Fixes
TorControlOnionClientAuthDelete
unescaped command string that caused the controller to endlessly loop. - Fixes
TorController
result failures for25x
status coded replies from Tor- Status Code
250
was previously the only accepted success case, but Tor replies with251
,252
, ... in some instances where there was success, but some additional event occurred.
- Status Code
- Fixes
Port
class' required Int range- Changed from
1024..65535
->0..65535
- NOTE: This was a breaking change as it introduced the
PortProxy
class to be used in theTorConfig
when declaring values for dns/http/socks/trans proxies.
- Changed from
- Fixes for Android Foreground Service:
- Notification not showing immediately on Android API 31+
- Now uses
startForegroundService
on API 26+ ifenableForeground
is true
- Documentation improvements
- Bumps dependencies
- Bumps Tor to version 0.4.6.10
- Fixes geoip6 file extraction when newer geoip/geoip6 files are available
- Adds support for
OwningControllerProcess
- Adds
TorController.disconnect
method as an additional assurance to shut down Tor - Cleans up internal functionality
- Adds reading of Tor Process error/input stream and pipes output to listeners
- Fixes Jvm loader for Windows and macOS by excluding Transparent Proxy Port if present
- Adds arguments to
Destroyable.destroy
method for:- Callback invocation upon destruction completion
- Boolean value to stop cleanly via signaling SHUTDOWN, or stopping immediately by coroutine cancellation + Process destruction
- Logging improvements
- Refactors
TorManagerEvent
warn/error/debug to live under theLog
subclass hierarchy - Adds the
Log.Info
value class type
- Refactors
- Refactors
TorConfig
to:- Use
Set
instead ofMap
TorConfig.Setting
are now allclone
ableTorConfig.Setting
now contain anisMutable
flag to inhibit modification onceTorConfig
is built.- Adds ability to set multiple Ports of differing values
- Use
- Tweaks Android
TorServiceConfig
so thatstop_service_on_task_removed
can now be configured regardless of whetherenable_foreground
is set to true or not.
- Improves
Destroyable.destroy
method functionality - Adds sample project for JavaFx
- Improves Android sample project
- Initial
alpha
release