r11716@catbus: nickm | 2007-02-08 14:19:24 -0500

Warn when we get a v0 control connection.


svn:r9530
This commit is contained in:
Nick Mathewson 2007-02-08 19:44:48 +00:00
parent 9c081ab976
commit 69def349e0
3 changed files with 19 additions and 3 deletions

View File

@ -11,10 +11,16 @@ Changes in version 0.1.2.8-alpha - 2007-??-??
- Report events where a resolve succeeded or where we got a socks
protocol error correctly, rather than calling both of them "INTERNAL".
o Minor bugfixes (other)
o Minor bugfixes (other):
- Display correct results when reporting which versions are recommended,
and how recommended they are. (Resolves bug 383.)
o Minor features:
- Warn the user when an application uses the obsolete binary v0 control
protocol. We're planning to remove support for it during the next
development series, so it's good to give people some advance warning.
Changes in version 0.1.2.7-alpha - 2007-02-06
o Major bugfixes (rate limiting):
- Servers decline directory requests much more aggressively when

View File

@ -66,13 +66,13 @@ R - actually cause the directory.c functions to know about or_port
or_conn is full, and accept the sometimes directory data will just
never get written.
N - When we get a connection using the v0 controller protocol, warn that the
o When we get a connection using the v0 controller protocol, warn that the
next revision of Tor won't support it.
N - DNS improvements
. Asynchronous DNS
- Make evdns use windows strerror equivalents.
. Make sure patches get into libevent.
o Make sure patches get into libevent.
- Verify that it works well on windows
o Debug and re-enable server-side reverse DNS caching

View File

@ -2822,6 +2822,7 @@ connection_control_process_inbuf_v0(control_connection_t *conn)
uint32_t body_len;
uint16_t command_type;
char *body=NULL;
static int have_warned_about_v0_protocol = 0;
again:
/* Try to suck a control message from the buffer. */
@ -2850,6 +2851,15 @@ connection_control_process_inbuf_v0(control_connection_t *conn)
tor_assert(0);
}
if (!have_warned_about_v0_protocol) {
log_warn(LD_CONTROL, "An application has connected to us using the "
"version 0 control prototol, which has been deprecated since "
"Tor 0.1.1.1-alpha. This protocol will not be supported by "
"future versions of Tor; please use the v1 control protocol "
"instead.");
have_warned_about_v0_protocol = 1;
}
/* We got a command. If we need authentication, only authentication
* commands will be considered. */
if (conn->_base.state == CONTROL_CONN_STATE_NEEDAUTH_V0 &&