diff options
author | Robert Ransom <rransom.8774@gmail.com> | 2011-04-27 13:37:08 -0700 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2011-05-16 14:07:24 -0400 |
commit | 7571e9f1cb81927c5bd47190409a30c7f23ea4a1 (patch) | |
tree | 8695854f1b0e9bd234e8330639e80df4e5e4186c /src/or/directory.c | |
parent | 00ff80e0ae3a07ff3e2148d66d59716bc4630096 (diff) | |
download | tor-7571e9f1cb81927c5bd47190409a30c7f23ea4a1.tar.gz tor-7571e9f1cb81927c5bd47190409a30c7f23ea4a1.zip |
Check fetched rendezvous descriptors' service IDs
Diffstat (limited to 'src/or/directory.c')
-rw-r--r-- | src/or/directory.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/or/directory.c b/src/or/directory.c index 01f33752ff..9f9b2c1577 100644 --- a/src/or/directory.c +++ b/src/or/directory.c @@ -1909,7 +1909,8 @@ connection_dir_client_reached_eof(dir_connection_t *conn) (int)body_len, status_code, escaped(reason)); switch (status_code) { case 200: - if (rend_cache_store(body, body_len, 0) < -1) { + if (rend_cache_store(body, body_len, 0, + conn->rend_data->onion_address) < -1) { log_warn(LD_REND,"Failed to parse rendezvous descriptor."); /* Any pending rendezvous attempts will notice when * connection_about_to_close_connection() @@ -3114,7 +3115,7 @@ directory_handle_command_post(dir_connection_t *conn, const char *headers, !strcmpstart(url,"/tor/rendezvous/publish")) { /* rendezvous descriptor post */ log_info(LD_REND, "Handling rendezvous descriptor post."); - if (rend_cache_store(body, body_len, 1) < 0) { + if (rend_cache_store(body, body_len, 1, NULL) < 0) { log_fn(LOG_PROTOCOL_WARN, LD_DIRSERV, "Rejected rend descriptor (length %d) from %s.", (int)body_len, conn->_base.address); |