Since I need to patch tor that does not yet support binding on a link-local ipv6 address, I compiled it from source.
The compile is successful (with minor warnings on the ar command) but the resulting executable has a strange behavior: it changes identity every 5 minutes.
Here is a detailed post on tor trac of this phenomenon: https://trac.torproject.org/projects/tor/ticket/24350
To be sure the observation is not due to my patch, the above post is when compiling the unmodified source that is within the Ubuntu source repository. Same behavior is observed with the latest tor (0.3.1.8 as of this post).
I suspect what I have observed comes from a configuration paramater of one of the libraries (libevent, libssl) that has somewhere a default timeout of 5 minutes.
For tor, but more generally for any package I might want to compile, I would like to know where to find all the "parameters" to set so that the executable has the same behavior as those from the Ubuntu repositories.
For instance, I can see that the path where tor searches its configurations are different (first below is the tor binary from Ubuntu repo):
$ strings -d tor | grep -e '/.*torrc' /etc/tor/torrc-defaults /etc/tor/torrc ~/.torrc $ strings -d tor_0.3.1.8 | grep -e '/.*torrc' /usr/local/etc/tor/torrc ~/.torrc /usr/local/etc/tor/torrc-defaults
Then I guess, when you build/compile something on Debian/Ubuntu you have a set of parameters for: path, timeouts, various options, etc...
I can live with the different default paths (the systemd service forces the path of the configuration file) but the "5 minutes bug" is very annoying. Moreover, as tor is about anonymity, there could be more serious "silent bug" like this one... and I'll be glad if I could avoid them!
In summary, I would like set up a build environment to be able to compile executable with the exact same defaults parameters as those from the Ubuntu official repository. First instance of that would be to compile tor with the same "parameters" as in the Ubuntu repo.