[tor-commits] [chutney/master] Add HS torrc template and network configuration

nickm at torproject.org nickm at torproject.org
Tue Dec 23 19:37:39 UTC 2014


commit a49e68bd0ab3eaefc2d6468b22376ff14f1c45dc
Author: David Goulet <dgoulet at ev0ke.net>
Date:   Wed Dec 10 13:00:18 2014 -0500

    Add HS torrc template and network configuration
    
    This adds a network with an HS service bound to port 6000 that serves
    port 22 on your local machine.
    
    The hidden service is node test025h and the hostname can be found in
    "$dir/hidden_service/hostname".
    
    To start the network, use the "hs" network.
    
    Fixes #13934
    
    Signed-off-by: David Goulet <dgoulet at ev0ke.net>
---
 networks/hs             |    9 +++++++++
 torrc_templates/hs.tmpl |    8 ++++++++
 2 files changed, 17 insertions(+)

diff --git a/networks/hs b/networks/hs
new file mode 100644
index 0000000..a76ba2b
--- /dev/null
+++ b/networks/hs
@@ -0,0 +1,9 @@
+Authority = Node(tag="a", authority=1, relay=1, torrc="authority.tmpl")
+Middle = Node(tag="m", relay=1, torrc="relay-non-exit.tmpl")
+Relay = Node(tag="r", relay=1, torrc="relay.tmpl")
+Client = Node(tag="c", torrc="client.tmpl")
+HS = Node(tag="h", torrc="hs.tmpl")
+
+NODES = Authority.getN(4) + Middle.getN(10) + Relay.getN(6) + Client.getN(5) + HS.getN(1)
+
+ConfigureNodes(NODES)
diff --git a/torrc_templates/hs.tmpl b/torrc_templates/hs.tmpl
new file mode 100644
index 0000000..bcef11e
--- /dev/null
+++ b/torrc_templates/hs.tmpl
@@ -0,0 +1,8 @@
+${include:common.i}
+SocksPort 0
+Address $ip
+
+HiddenServiceDir ${dir}/hidden_service
+# SSH is usually a popular service that is running. This is really just to make
+# a quick way to test the HS with torsocks and have an app at the other end.
+HiddenServicePort 6000 127.0.0.1:22



More information about the tor-commits mailing list