[Tails-dev] Please review and merge bugfix/tordate_vs_bridge…

Poista viesti

Vastaa
Lähettäjä: anonym
Päiväys:  
Vastaanottaja: The Tails public development discussion list
Vanhat otsikot: Re: [Tails-dev] bridge mode vs. clock way off
Aihe: [Tails-dev] Please review and merge bugfix/tordate_vs_bridge_mode [was: bridge mode vs. clock way off]
27/11/12 00:01, anonym wrote:
> 22/11/12 14:11, intrigeri wrote:
>> Hi,
>>
>> anonym wrote (21 Nov 2012 14:21:43 GMT) :
>>> Log severity info is really verbose. I ran a test for 20 minutes with
>>> some rather heavy Tor usage, and the log grew something like
>>> 100KB/minute. That's too much, IMHO.
>>
>> Agreed.
>>
>>> However, we can save this approach
>>> like this:
>>
>>> 1. We patch torrc at build time to have "Log info ...", as proposed.
>>> 2. But once tordate finishes we edit torrc and downgrade to notice
>>>    level debugging, and send a SIGHUP to Tor.

>>
>>> Ugly, ugly, ugly workarounds, all the time! :) What do you think?
>>
>> Wow... I could live with that, but if there's a trivial bugfix in Tor
>> itself that can allow us to avoid yet another ugly kludge, then I'd
>> rather use the possibility thereof.
>
> I tried implementing this in a branch yesterday, hoping to get it in
> 0.15. I encountered some issues, and then I saw that you had already
> pushed the 0.15 tag etc. so I didn't look on it again until today. It
> turns step 2 isn't as easy as I initially thought:
>
> Since we're in bridge mode, Vidalia will start before tordate so bridges
> can be added. When Vidalia connects to Tor, it unsets the (hidden) Tor
> option "__ReloadTorrcOnSIGHUP", so we either have to:
>
> a. restart Tor (and Vidalia) yet again to have Tor re-read the new
>    torrc (now without "info" level logging), or
> b. manually re-set "__ReloadTorrcOnSIGHUP", send a HUP so Tor re-reads
>    torrc and then possibly unset "__ReloadTorrcOnSIGHUP" again (or
>    restart Vidalia)

>
> I don't like either, mostly because this was meant to be a simple,
> unobtrusive fix. I guess option a is best so Vidalia doesn't get
> out-of-sync with Tor's state, if that's possible. But it's yet another
> Tor restart...
>
> Note: You can't change anything about "Log" lines in torrc via the
> control port. Otherwise that'd be the easy way out.


This turned out to be wrong (thanks again Robert!). I've now pushed a
fix into the branch bugfix/tordate_vs_bridge_mode (merged into
experimental). Please review and merge this branch into testing and
devel so it ends up in the next Tails release.

d1e3258 Use shell library for tor_is_working() in the Unsafe Browser.
98b48a9 Add logging for is_clock_way_off().
0d9232b Extract Tor's ControlPort from torrc.
4793282 White-list root to use Tor's ControlPort.
e9c2de1 Kill Vidalia when restarting Tor.
44489d0 Make tordate work in bridge mode with an incorrect clock

Cheers!