9 #ifndef TOR_HS_CLIENT_H
10 #define TOR_HS_CLIENT_H
42 REGISTER_SUCCESS_ALREADY_EXISTS,
45 REGISTER_SUCCESS_AND_DECRYPTED,
47 REGISTER_FAIL_BAD_ADDRESS,
49 REGISTER_FAIL_PERMANENT_STORAGE,
50 } hs_client_register_auth_status_t;
57 REMOVAL_SUCCESS_NOT_FOUND,
60 } hs_client_removal_auth_status_t;
63 #define CLIENT_AUTH_FLAG_IS_PERMANENT (1<<0)
81 hs_client_register_auth_status_t
84 hs_client_removal_auth_status_t
89 #define client_service_authorization_free(auth) \
90 FREE_AND_NULL(hs_client_service_authorization_t, \
91 client_service_authorization_free_, (auth))
104 const char *desc_str,
120 const uint8_t *payload,
123 const uint8_t *payload,
126 const uint8_t *payload,
130 const char *body,
const int status_code);
145 #ifdef HS_CLIENT_PRIVATE
171 #ifdef TOR_UNIT_TESTS
173 STATIC void set_hs_client_auths_map(digest256map_t *map);
Header for crypto_ed25519.c.
Header file containing circuit data for the whole HS subsystem.
STATIC void purge_ephemeral_client_auth(void)
STATIC hs_client_service_authorization_t * parse_auth_file_content(const char *client_key_str)
STATIC extend_info_t * desc_intro_point_to_extend_info(const hs_desc_intro_point_t *ip)
STATIC extend_info_t * client_get_random_intro(const ed25519_public_key_t *service_pk)
STATIC int handle_rendezvous2(origin_circuit_t *circ, const uint8_t *payload, size_t payload_len)
STATIC routerstatus_t * pick_hsdir_v3(const ed25519_public_key_t *onion_identity_pk)
STATIC int auth_key_filename_is_valid(const char *filename)
STATIC hs_client_fetch_status_t fetch_v3_desc(const ed25519_public_key_t *onion_identity_pk)
STATIC void retry_all_socks_conn_waiting_for_desc(void)
int hs_client_receive_introduce_ack(origin_circuit_t *circ, const uint8_t *payload, size_t payload_len)
int hs_client_receive_rendezvous2(origin_circuit_t *circ, const uint8_t *payload, size_t payload_len)
int hs_config_client_authorization(const or_options_t *options, int validate_only)
@ HS_CLIENT_FETCH_PENDING
@ HS_CLIENT_FETCH_MISSING_INFO
@ HS_CLIENT_FETCH_NO_HSDIRS
@ HS_CLIENT_FETCH_HAVE_DESC
@ HS_CLIENT_FETCH_NOT_ALLOWED
@ HS_CLIENT_FETCH_LAUNCHED
digest256map_t * get_hs_client_auths_map(void)
hs_client_register_auth_status_t hs_client_register_auth_credentials(hs_client_service_authorization_t *creds)
void hs_client_note_connection_attempt_succeeded(const edge_connection_t *conn)
void hs_client_circuit_cleanup_on_close(const circuit_t *circ)
int hs_client_any_intro_points_usable(const ed25519_public_key_t *service_pk, const hs_descriptor_t *desc)
hs_client_removal_auth_status_t hs_client_remove_auth_credentials(const char *hsaddress)
void hs_client_launch_v3_desc_fetch(const ed25519_public_key_t *onion_identity_pk, const smartlist_t *hsdirs)
void hs_client_circuit_cleanup_on_free(const circuit_t *circ)
void hs_client_dir_info_changed(void)
int hs_client_reextend_intro_circuit(origin_circuit_t *circ)
int hs_client_refetch_hsdesc(const ed25519_public_key_t *identity_pk)
void hs_client_free_all(void)
void hs_client_purge_state(void)
void hs_client_close_intro_circuits_from_desc(const hs_descriptor_t *desc)
int hs_client_receive_rendezvous_acked(origin_circuit_t *circ, const uint8_t *payload, size_t payload_len)
int hs_client_send_introduce1(origin_circuit_t *intro_circ, origin_circuit_t *rend_circ)
hs_desc_decode_status_t hs_client_decode_descriptor(const char *desc_str, const ed25519_public_key_t *service_identity_pk, hs_descriptor_t **desc)
void hs_client_circuit_has_opened(origin_circuit_t *circ)
void hs_client_dir_fetch_done(dir_connection_t *dir_conn, const char *reason, const char *body, const int status_code)
extend_info_t * hs_client_get_random_intro_from_edge(const edge_connection_t *edge_conn)
#define HS_SERVICE_ADDR_LEN_BASE32
Header file for hs_descriptor.c.
Header file containing circuit and connection identifier data for the whole HS subsystem.
char onion_address[HS_SERVICE_ADDR_LEN_BASE32+1]
curve25519_secret_key_t enc_seckey
#define MOCK_DECL(rv, funcname, arglist)