Skip to content

Commit

Permalink
WhonixTorController: Implement RESETCONF command
Browse files Browse the repository at this point in the history
  • Loading branch information
alvasw committed May 22, 2024
1 parent 5280cf7 commit 75cdfa3
Showing 1 changed file with 9 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,15 @@ public void addOnion(TorKeyPair torKeyPair, int onionPort, int localPort) throws
String reply = receiveReply();
}

public void resetConf(String configName) throws IOException {
String command = "RESETCONF " + configName + "\r\n";
sendCommand(command);
String reply = receiveReply();
if (!reply.equals("250 OK")) {
throw new ControlCommandFailedException("Couldn't reset config: " + configName);
}
}

public void takeOwnership() throws IOException {
String command = "TAKEOWNERSHIP\r\n";
sendCommand(command);
Expand Down

0 comments on commit 75cdfa3

Please sign in to comment.