diff options
author | George Kadianakis <desnacked@riseup.net> | 2017-11-06 15:45:42 +0200 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2017-11-17 09:57:46 -0500 |
commit | 7e52947d571c8038bfcd82e14f373f3c00924cbe (patch) | |
tree | 2b998ec4c30b841d334b772f8dbdbc572101e7e6 /src/or/directory.c | |
parent | 9fbc835f10e9fba6a9b0c6643a41aee9c8aa05c2 (diff) | |
download | tor-7e52947d571c8038bfcd82e14f373f3c00924cbe.tar.gz tor-7e52947d571c8038bfcd82e14f373f3c00924cbe.zip |
Intoduce unittest for skipping outdated dirservers.
Diffstat (limited to 'src/or/directory.c')
-rw-r--r-- | src/or/directory.c | 42 |
1 files changed, 0 insertions, 42 deletions
diff --git a/src/or/directory.c b/src/or/directory.c index 43a03a2fd9..66bdef2361 100644 --- a/src/or/directory.c +++ b/src/or/directory.c @@ -1012,48 +1012,6 @@ directory_must_use_begindir(const or_options_t *options) return !public_server_mode(options); } -struct directory_request_t { - /** - * These fields specify which directory we're contacting. Routerstatus, - * if present, overrides the other fields. - * - * @{ */ - tor_addr_port_t or_addr_port; - tor_addr_port_t dir_addr_port; - char digest[DIGEST_LEN]; - - const routerstatus_t *routerstatus; - /** @} */ - /** One of DIR_PURPOSE_* other than DIR_PURPOSE_SERVER. Describes what - * kind of operation we'll be doing (upload/download), and of what kind - * of document. */ - uint8_t dir_purpose; - /** One of ROUTER_PURPOSE_*; used for uploads and downloads of routerinfo - * and extrainfo docs. */ - uint8_t router_purpose; - /** Enum: determines whether to anonymize, and whether to use dirport or - * orport. */ - dir_indirection_t indirection; - /** Alias to the variable part of the URL for this request */ - const char *resource; - /** Alias to the payload to upload (if any) */ - const char *payload; - /** Number of bytes to upload from payload</b> */ - size_t payload_len; - /** Value to send in an if-modified-since header, or 0 for none. */ - time_t if_modified_since; - /** Hidden-service-specific information v2. */ - const rend_data_t *rend_query; - /** Extra headers to append to the request */ - config_line_t *additional_headers; - /** Hidden-service-specific information for v3+. */ - const hs_ident_dir_conn_t *hs_ident; - /** Used internally to directory.c: gets informed when the attempt to - * connect to the directory succeeds or fails, if that attempt bears on the - * directory's usability as a directory guard. */ - circuit_guard_state_t *guard_state; -}; - /** Evaluate the situation and decide if we should use an encrypted * "begindir-style" connection for this directory request. * 0) If there is no DirPort, yes. |