diff --git a/network/tor/tor/src/main/java/bisq/tor/controller/TorControlProtocol.java b/network/tor/tor/src/main/java/bisq/tor/controller/TorControlProtocol.java index 1c18e6efba..5b33d0011c 100644 --- a/network/tor/tor/src/main/java/bisq/tor/controller/TorControlProtocol.java +++ b/network/tor/tor/src/main/java/bisq/tor/controller/TorControlProtocol.java @@ -72,6 +72,15 @@ public String getInfo(String keyword) throws IOException { return assertTwoLineOkReply(replyStream, "GETINFO"); } + public void hsFetch(String hsAddress) throws IOException { + String command = "HSFETCH " + hsAddress + "\r\n"; + sendCommand(command); + String reply = receiveReply().findFirst().orElseThrow(); + if (!reply.equals("250 OK")) { + throw new ControlCommandFailedException("Couldn't initiate HSFETCH for : " + hsAddress); + } + } + public void resetConf(String configName) throws IOException { String command = "RESETCONF " + configName + "\r\n"; sendCommand(command);