Add default proxy params (#3863)

This commit is contained in:
benthecarman 2021-12-01 12:28:59 -06:00 committed by GitHub
parent b2bf190dce
commit 169222a306
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -253,6 +253,12 @@ object Socks5ProxyParams {
val DefaultPort = 9050
val defaultProxyParams: Socks5ProxyParams =
Socks5ProxyParams(
address = InetSocketAddress.createUnresolved("127.0.0.1", DefaultPort),
credentialsOpt = None,
randomizeCredentials = true)
def proxyCredentials(
proxyParams: Socks5ProxyParams): Option[Socks5Connection.Credentials] =
if (proxyParams.randomizeCredentials) {