diff options
author | Nick Mathewson <nickm@torproject.org> | 2012-12-05 22:34:49 -0500 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2013-01-03 11:29:46 -0500 |
commit | 2802ccaeb6b95e693af7736e58e91434d28ac6a2 (patch) | |
tree | e11e0d9753d2b6bd40761c3b03f491468a1c8d58 /src/or/onion.h | |
parent | 5d15d597a9059d0f87ced081e187db622caa7978 (diff) | |
download | tor-2802ccaeb6b95e693af7736e58e91434d28ac6a2.tar.gz tor-2802ccaeb6b95e693af7736e58e91434d28ac6a2.zip |
Teach cpuworker and others about create_cell_t and friends
The unit of work sent to a cpuworker is now a create_cell_t; its
response is now a created_cell_t. Several of the things that call or
get called by this chain of logic now take create_cell_t or
created_cell_t too.
Since all cpuworkers are forked or spawned by Tor, they don't need a
stable wire protocol, so we can just send structs. This saves us some
insanity, and helps p
Diffstat (limited to 'src/or/onion.h')
-rw-r--r-- | src/or/onion.h | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/src/or/onion.h b/src/or/onion.h index 08e1a22ecf..36cb761188 100644 --- a/src/or/onion.h +++ b/src/or/onion.h @@ -12,8 +12,9 @@ #ifndef TOR_ONION_H #define TOR_ONION_H -int onion_pending_add(or_circuit_t *circ, char *onionskin); -or_circuit_t *onion_next_task(char **onionskin_out); +struct create_cell_t; +int onion_pending_add(or_circuit_t *circ, struct create_cell_t *onionskin); +or_circuit_t *onion_next_task(struct create_cell_t **onionskin_out); void onion_pending_remove(or_circuit_t *circ); void clear_pending_onions(void); @@ -39,14 +40,14 @@ int onion_skin_create(int type, onion_handshake_state_t *state_out, uint8_t *onion_skin_out); int onion_skin_server_handshake(int type, - const uint8_t *onion_skin, + const uint8_t *onion_skin, size_t onionskin_len, const server_onion_keys_t *keys, uint8_t *reply_out, - uint8_t *keys_out, size_t key_out_len); -// uint8_t *rend_authenticator_out); + uint8_t *keys_out, size_t key_out_len, + uint8_t *rend_nonce_out); int onion_skin_client_handshake(int type, const onion_handshake_state_t *handshake_state, - const uint8_t *reply, + const uint8_t *reply, size_t reply_len, uint8_t *keys_out, size_t key_out_len, uint8_t *rend_authenticator_out); |