<div dir="ltr">Thanks for the clarification, I've managed to get it going with a few scripts to edit my torrc on start.</div><div class="gmail_extra"><br><div class="gmail_quote">On 8 February 2017 at 06:49, teor <span dir="ltr"><<a href="mailto:teor2345@gmail.com" target="_blank">teor2345@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span class=""><br>
> On 8 Feb 2017, at 02:53, Andrew Smith <<a href="mailto:me@andrewmichaelsmith.com">me@andrewmichaelsmith.com</a>> wrote:<br>
><br>
> OK, thanks for the clarification and raising the ticket.<br>
><br>
> To answer the why - for starters I'm trying to run a local tor network for fun and to learn more about tor.<br>
><br>
> Why am I trying to put a hostname in there? Because the system I'm setting up the network in may not have static IPs. As I understand it I need to maintain a DirAuthority line with a hard coded IP for each and every directory authority I run myself. If I can use a DNS name, this will mean I end up updating the torrc with DirAuthority lines a lot less. With IPs I am forced to change every torrc in my network every time an IP changes.<br>
<br>
</span>This is a feature that we're unlikely to implement, because the public<br>
Tor network doesn't want to have to trust the DNS system (it's insecure,<br>
and blocked or modified for some clients).<br>
<br>
We *might* accept a patch for this behind a torrc option.<br>
<span class=""><br>
> There are certainly ways around this (I could have a script populate torrc based upon DNS, for example) but it would make my life easier if I didn't have to.<br>
<br>
</span>You could use 127.0.0.1 if all the tor instances are on the same machine.<br>
<br>
Or if they are all on the same network, you could use a private address<br>
range.<br>
<br>
If they're not, you could use a VPN or similar solution to route the<br>
private addresses.<br>
<br>
Any of these options require setting a few torrc options that allow<br>
private addresses, the easiest way to do this is to set:<br>
<br>
TestingTorNetwork 1<br>
<br>
This also changes some other torrc options: read the man page for details.<br>
<br>
Tim<br>
<div class="HOEnZb"><div class="h5"><br>
> On 6 February 2017 at 23:10, teor <<a href="mailto:teor2345@gmail.com">teor2345@gmail.com</a>> wrote:<br>
><br>
> > On 7 Feb 2017, at 03:31, Andrew Smith <<a href="mailto:me@andrewmichaelsmith.com">me@andrewmichaelsmith.com</a>> wrote:<br>
> ><br>
> > Hi<br>
> ><br>
> > I'm experimenting running my own tor network. To achieve this I'm setting DirAuthority in torrc.<br>
> ><br>
> > But it seems that I cannot use a hostname for my DirAuthority.<br>
><br>
> Why are you trying to do this?<br>
> If you share your goal, we might be able to help you with a workaround<br>
> or alternate strategy.<br>
><br>
> For example, if you use a hostname in the "Address" field, your<br>
> authority will look it up, add the IPv4 to its descriptor, and then<br>
> other authorities, relays, and clients will use that address.<br>
> (After the network has bootstrapped using the original address.)<br>
><br>
> > For example:<br>
> ><br>
> > DirAuthority da1 orport=7000 no-v2 v3ident=xxx da1:7000 xxx<br>
> ><br>
> > Results in the error:<br>
> ><br>
> > Unrecognized flag 'da1:7000' on DirAuthority line<br>
> ><br>
> > If I replace "da1" with an IP address there is no error. Is this expected behaviour?<br>
><br>
> It is the implemented behaviour, and has been since at least 2006<br>
> (tor-0.1.2.2-alpha). The code responsible is:<br>
><br>
>   while (smartlist_len(items)) {<br>
>     char *flag = smartlist_get(items, 0);<br>
>     if (TOR_ISDIGIT(flag[0]))<br>
>       break;<br>
><br>
> Which means that only IPv4 addresses are guaranteed to work here.<br>
><br>
> > I'm running tor v0.2.8.12. The documentation calls this an "address" (as opposed to other parts which refer to an "IP") which made me think a hostname would work.<br>
><br>
> The "Address" torrc option takes a hostname, as do some other options<br>
> (I think the HiddenServicePort target is another.)<br>
><br>
> Thanks for the bug report, we'll fix the man page:<br>
> <a href="https://trac.torproject.org/projects/tor/ticket/21405" rel="noreferrer" target="_blank">https://trac.torproject.org/<wbr>projects/tor/ticket/21405</a><br>
><br>
> T<br>
><br>
> --<br>
<br>
T<br>
<br>
--<br>
Tim Wilson-Brown (teor)<br>
<br>
teor2345 at gmail dot com<br>
PGP C855 6CED 5D90 A0C5 29F6 4D43 450C BA7F 968F 094B<br>
ricochet:ekmygaiu4rzgsk6n<br>
xmpp: teor at torproject dot org<br>
------------------------------<wbr>------------------------------<wbr>------------<br>
<br>
<br>
<br>
</div></div><br>______________________________<wbr>_________________<br>
tor-relays mailing list<br>
<a href="mailto:tor-relays@lists.torproject.org">tor-relays@lists.torproject.<wbr>org</a><br>
<a href="https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-relays" rel="noreferrer" target="_blank">https://lists.torproject.org/<wbr>cgi-bin/mailman/listinfo/tor-<wbr>relays</a><br>
<br></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr">Andy Smith<div><div><div><a href="http://andrewmichaelsmith.com" target="_blank">http://andrewmichaelsmith.com</a> | @bingleybeep</div></div></div></div></div>
</div>