Skip to content

topl-service-base / io.matthewnelson.topl_service_base / BaseServiceTorSettings

BaseServiceTorSettings

abstract class BaseServiceTorSettings :TorSettings (source)

This class enables the querying of TorServicePrefs to obtain values potentially set by the User such that they are preferred over static/default values you may have set in your ApplicationDefaultTorSettings.

It enables the updating of settings in a standardized manner so library users can simply instantiate TorServicePrefs, modify settings, and then call restartTor from the topl-service::TorServiceController to have them applied to the Tor Process. It also makes designing of a settings screen much easier for your application.

Parameters

servicePrefs - TorServicePrefs to query/save values to shared preferences

defaultTorSettings - Default values to fall back on if nothing is returned from TorServicePrefs

Constructors

Name Summary
<init> This class enables the querying of TorServicePrefs to obtain values potentially set by the User such that they are preferred over static/default values you may have set in your ApplicationDefaultTorSettings.BaseServiceTorSettings(servicePrefs:TorServicePrefs, defaultTorSettings:ApplicationDefaultTorSettings)

Properties

Name Summary
connectionPadding open val connectionPadding:String
customTorrc open val customTorrc:String?
defaultTorSettings Default values to fall back on if nothing is returned from TorServicePrefsval defaultTorSettings:ApplicationDefaultTorSettings
disableNetwork open val disableNetwork:Boolean
dnsPort open val dnsPort:String
dnsPortIsolationFlags open val dnsPortIsolationFlags:List<String>?
dormantClientTimeout open val dormantClientTimeout:Int?
entryNodes open val entryNodes:String?
excludeNodes open val excludeNodes:String?
exitNodes open val exitNodes:String?
hasBridges open val hasBridges:Boolean
hasCookieAuthentication open val hasCookieAuthentication:Boolean
hasDebugLogs open val hasDebugLogs:Boolean
hasDormantCanceledByStartup open val hasDormantCanceledByStartup:Boolean
hasOpenProxyOnAllInterfaces open val hasOpenProxyOnAllInterfaces:Boolean
hasReachableAddress open val hasReachableAddress:Boolean
hasReducedConnectionPadding open val hasReducedConnectionPadding:Boolean
hasSafeSocks open val hasSafeSocks:Boolean
hasStrictNodes open val hasStrictNodes:Boolean
hasTestSocks open val hasTestSocks:Boolean
httpTunnelPort open val httpTunnelPort:String
httpTunnelPortIsolationFlags open val httpTunnelPortIsolationFlags:List<String>?
isAutoMapHostsOnResolve open val isAutoMapHostsOnResolve:Boolean
isRelay open val isRelay:Boolean
listOfSupportedBridges open val listOfSupportedBridges:List<String>
proxyHost open val proxyHost:String?
proxyPassword open val proxyPassword:String?
proxyPort open val proxyPort:Int?
proxySocks5Host open val proxySocks5Host:String?
proxySocks5ServerPort open val proxySocks5ServerPort:Int?
proxyType open val proxyType:String
proxyUser open val proxyUser:String?
reachableAddressPorts open val reachableAddressPorts:String
relayNickname open val relayNickname:String?
relayPort open val relayPort:String
runAsDaemon open val runAsDaemon:Boolean
servicePrefs TorServicePrefs to query/save values to shared preferencesval servicePrefs:TorServicePrefs
socksPort open val socksPort:String
socksPortIsolationFlags open val socksPortIsolationFlags:List<String>?
transPort open val transPort:String
transPortIsolationFlags open val transPortIsolationFlags:List<String>?
useSocks5 open val useSocks5:Boolean
virtualAddressNetwork open val virtualAddressNetwork:String?

Functions

Name Summary
connectionPaddingSave Saves the value for connectionPadding to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun connectionPaddingSave(connectionPadding:String):Unit
customTorrcSave Saves the value for customTorrc to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun customTorrcSave(customTorrc:String?):Unit
disableNetworkSave Saves the value for disableNetwork to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun disableNetworkSave(boolean:Boolean):Unit
dnsPortIsolationFlagsSave Saves the value for isolationFlags to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun dnsPortIsolationFlagsSave(isolationFlags:List<String>):Unit
dnsPortSave Saves the value for dnsPort to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun dnsPortSave(dnsPort:String):Unit
dormantClientTimeoutSave abstract fun dormantClientTimeoutSave(minutes:Int?):Unit
entryNodesSave Saves the value for entryNodes to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun entryNodesSave(entryNodes:String?):Unit
excludeNodesSave Saves the value for excludeNodes to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun excludeNodesSave(excludeNodes:String?):Unit
exitNodesSave Saves the value for exitNodes to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun exitNodesSave(exitNodes:String?):Unit
hasBridgesSave Saves the value for hasBridges to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun hasBridgesSave(boolean:Boolean):Unit
hasCookieAuthenticationSave Saves the value for hasCookieAuthentication to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun hasCookieAuthenticationSave(boolean:Boolean):Unit
hasDebugLogsSave Saves the value for hasDebugLogs to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun hasDebugLogsSave(boolean:Boolean):Unit
hasDormantCanceledByStartupSave Saves the value for hasDormantCanceledByStartup to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun hasDormantCanceledByStartupSave(boolean:Boolean):Unit
hasOpenProxyOnAllInterfacesSave Saves the value for hasOpenProxyOnAllInterfaces to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun hasOpenProxyOnAllInterfacesSave(boolean:Boolean):Unit
hasReachableAddressSave Saves the value for hasReachableAddress to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun hasReachableAddressSave(boolean:Boolean):Unit
hasReducedConnectionPaddingSave Saves the value for hasReducedConnectionPadding to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun hasReducedConnectionPaddingSave(boolean:Boolean):Unit
hasSafeSocksSave Saves the value for hasSafeSocks to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun hasSafeSocksSave(boolean:Boolean):Unit
hasStrictNodesSave Saves the value for hasStrictNodes to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun hasStrictNodesSave(boolean:Boolean):Unit
hasTestSocksSave Saves the value for hasTestSocks to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun hasTestSocksSave(boolean:Boolean):Unit
httpPortIsolationFlagsSave Saves the value for isolationFlags to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun httpPortIsolationFlagsSave(isolationFlags:List<String>):Unit
httpTunnelPortSave Saves the value for httpPort to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun httpTunnelPortSave(httpPort:String):Unit
isAutoMapHostsOnResolveSave Saves the value for isAutoMapHostsOnResolve to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun isAutoMapHostsOnResolveSave(boolean:Boolean):Unit
isRelaySave Saves the value for isRelay to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun isRelaySave(boolean:Boolean):Unit
proxyHostSave Saves the value for proxyHost to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun proxyHostSave(proxyHost:String?):Unit
proxyPasswordSave Saves the value for proxyPassword to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun proxyPasswordSave(proxyPassword:String?):Unit
proxyPortSave Saves the value for proxyPort to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun proxyPortSave(proxyPort:Int?):Unit
proxySocks5HostSave Saves the value for proxySocks5Host to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun proxySocks5HostSave(proxySocks5Host:String?):Unit
proxySocks5ServerPortSave Saves the value for proxySocks5ServerPort to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun proxySocks5ServerPortSave(proxySocks5ServerPort:Int?):Unit
proxyTypeSave Saves the value for proxyType to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun proxyTypeSave(proxyType:String):Unit
proxyUserSave Saves the value for proxyUser to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun proxyUserSave(proxyUser:String?):Unit
reachableAddressPortsSave Saves the value for reachableAddressPorts to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun reachableAddressPortsSave(reachableAddressPorts:String):Unit
relayNicknameSave Saves the value for relayNickname to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun relayNicknameSave(relayNickname:String):Unit
relayPortSave Saves the value for relayPort to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun relayPortSave(relayPort:String):Unit
runAsDaemonSave Saves the value for runAsDaemon to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun runAsDaemonSave(boolean:Boolean):Unit
socksPortIsolationFlagsSave Saves the value for isolationFlags to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun socksPortIsolationFlagsSave(isolationFlags:List<String>):Unit
socksPortSave Saves the value for socksPort to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun socksPortSave(socksPort:String):Unit
transPortIsolationFlagsSave Saves the value for isolationFlags to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun transPortIsolationFlagsSave(isolationFlags:List<String>):Unit
transPortSave Saves the value for transPort to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun transPortSave(transPort:String):Unit
useSocks5Save Saves the value for useSocks5 to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun useSocks5Save(boolean:Boolean):Unit
virtualAddressNetworkSave Saves the value for virtualAddressNetwork to TorServicePrefs. If the value is the same as what is declared in defaultTorSettings, TorServicePrefs is queried to remove the setting if it exists.abstract fun virtualAddressNetworkSave(virtualAddressNetwork:String):Unit