Can't guess own address when using TunneledDirConns
00:38 < goldy> P I N G
00:39 < goldy> While working on a controller for the control port, I noticed
that "getinfo address" appears to be broken. I get a "550
Internal error" message.
00:40 < goldy> arma2, nickm, any idea as to why?
00:40 < nickm> what version of tor?
00:40 < nickm> reproducible/not?
00:41 < goldy> Windows: 0.2.1.2-alpha and 0.2.0.28-rc
00:41 < goldy> reproducible with those versions.
00:41 < nickm> ah.
00:41 < goldy> 0.1.2.19 and 0.1.2.14 both seem to work alright.
00:42 < nickm> it doesn't have any guess as to what its address is yet
00:42 < goldy> alright...
00:42 < nickm> previous versions learned it from directory headers or from
resolving the address field in the config file
00:42 < goldy> what changed?
00:43 < nickm> it's possible that when we switched to getting directory over
tor by default, we stopped getting useful header info in
directory replies.
00:43 < goldy> this was on a clean install, no cached-* files yet.
00:44 < nickm> seems like a bug.
00:44 < nickm> ah yes, in directory.c:
00:44 < goldy> why do I always find wierd bugs.
00:44 < nickm> if (conn->dirconn_direct) {
00:44 < nickm> char *guess = http_get_header(headers, X_ADDRESS_HEADER);
00:44 < nickm> because your use case is not typical?
00:44 < goldy> hehe, I'm not typical. :)
00:44 < nickm> because you were a windows programmer in a past life? :)
00:45 < nickm> it looks like tor only examines the X-your-address-is header on
a direct directory connection.
00:45 < nickm> this makes a bit of sense, but not perfect sense: that header
should be fine if we're doing an encrypted one-hop connection.
00:45 < nickm> really, though, it should be looking at netinfo cells.
00:45 < nickm> hm.
00:46 < goldy> so your saying that new installs are using a circuit to get
directory info?
00:46 < nickm> 0.2.0.x should do the former, and 0.2.1.x the latter
00:46 < nickm> goldy: Don't you read the changelogs? :)
00:46 < goldy> I briefly looked at it.
00:46 < nickm> new installs get directory information over one-hop connections
by default. To a first approximation.
00:46 < goldy> but didn't see a "yeah, this might break x" so I didn't see
it. ;)
00:47 < goldy> so who is the first hop? another hard-coded DA?
00:47 < nickm> first hop in a one-hop circuit? it would be the directory
server.
00:48 < goldy> so it would be like ( me -> DA) or (me -> one_hop[DA?] -> DA )?
00:48 < nickm> yup, verified. if you run with TunneledDirConns off, getinfo
address works again. this is a bug.
00:49 < goldy> ah, OK.
00:49 < nickm> mind if I copy-and-paste this conversation to the bugtracker?
00:49 < goldy> I was wondering why my IP checking program was crashing...guess
I found out why.
00:49 < goldy> not at all.
[Automatically added by flyspray2trac: Operating System: All]