Update tor binary to 0.4.7.10 (#810)

This commit is contained in:
napoly 2024-03-11 13:05:06 +01:00 committed by GitHub
parent 82b6bcfda5
commit 78098e49d8
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
8 changed files with 97 additions and 39 deletions

View file

@ -84,6 +84,7 @@ public class Config {
public static final String USE_TOR_FOR_XMR = "useTorForXmr";
public static final String TORRC_FILE = "torrcFile";
public static final String TORRC_OPTIONS = "torrcOptions";
public static final String TOR_CONTROL_HOST = "torControlHost";
public static final String TOR_CONTROL_PORT = "torControlPort";
public static final String TOR_CONTROL_PASSWORD = "torControlPassword";
public static final String TOR_CONTROL_COOKIE_FILE = "torControlCookieFile";
@ -173,6 +174,7 @@ public class Config {
public final String socks5ProxyHttpAddress;
public final File torrcFile;
public final String torrcOptions;
public final String torControlHost;
public final int torControlPort;
public final String torControlPassword;
public final File torControlCookieFile;
@ -446,6 +448,11 @@ public class Config {
.withValuesConvertedBy(RegexMatcher.regex("^([^\\s,]+\\s[^,]+,?\\s*)+$"))
.defaultsTo("");
ArgumentAcceptingOptionSpec<String> torControlHostOpt =
parser.accepts(TOR_CONTROL_HOST, "The control hostname of an already running Tor service to be used by Haveno.")
.withRequiredArg()
.defaultsTo("127.0.0.1");
ArgumentAcceptingOptionSpec<Integer> torControlPortOpt =
parser.accepts(TOR_CONTROL_PORT,
"The control port of an already running Tor service to be used by Haveno.")
@ -667,6 +674,7 @@ public class Config {
this.bitcoinRegtestHost = options.valueOf(bitcoinRegtestHostOpt);
this.torrcFile = options.has(torrcFileOpt) ? options.valueOf(torrcFileOpt).toFile() : null;
this.torrcOptions = options.valueOf(torrcOptionsOpt);
this.torControlHost = options.valueOf(torControlHostOpt);
this.torControlPort = options.valueOf(torControlPortOpt);
this.torControlPassword = options.valueOf(torControlPasswordOpt);
this.torControlCookieFile = options.has(torControlCookieFileOpt) ?