2017-05-02 15:22:00 +02:00
|
|
|
/* Copyright (c) 2017, The Tor Project, Inc. */
|
|
|
|
/* See LICENSE for licensing information */
|
|
|
|
|
|
|
|
/**
|
|
|
|
* \file hs_client.h
|
|
|
|
* \brief Header file containing client data for the HS subsytem.
|
|
|
|
**/
|
|
|
|
|
|
|
|
#ifndef TOR_HS_CLIENT_H
|
|
|
|
#define TOR_HS_CLIENT_H
|
|
|
|
|
2017-06-01 13:12:33 +02:00
|
|
|
#include "crypto_ed25519.h"
|
2017-06-01 12:37:11 +02:00
|
|
|
#include "hs_descriptor.h"
|
2017-07-21 20:32:47 +02:00
|
|
|
#include "hs_ident.h"
|
2017-06-01 12:37:11 +02:00
|
|
|
|
2017-05-02 15:22:00 +02:00
|
|
|
void hs_client_note_connection_attempt_succeeded(
|
|
|
|
const edge_connection_t *conn);
|
|
|
|
|
2017-06-01 12:37:11 +02:00
|
|
|
int hs_client_decode_descriptor(
|
|
|
|
const char *desc_str,
|
|
|
|
const ed25519_public_key_t *service_identity_pk,
|
|
|
|
hs_descriptor_t **desc);
|
2017-07-27 23:15:19 +02:00
|
|
|
int hs_client_any_intro_points_usable(const ed25519_public_key_t *service_pk,
|
|
|
|
const hs_descriptor_t *desc);
|
2017-06-01 13:12:33 +02:00
|
|
|
int hs_client_refetch_hsdesc(const ed25519_public_key_t *identity_pk);
|
2017-06-01 12:37:11 +02:00
|
|
|
|
2017-07-14 16:16:48 +02:00
|
|
|
int hs_client_send_introduce1(origin_circuit_t *intro_circ,
|
|
|
|
origin_circuit_t *rend_circ);
|
|
|
|
|
2017-07-21 19:56:10 +02:00
|
|
|
void hs_client_circuit_has_opened(origin_circuit_t *circ);
|
|
|
|
|
2017-07-21 20:20:37 +02:00
|
|
|
int hs_client_receive_rendezvous_acked(origin_circuit_t *circ,
|
|
|
|
const uint8_t *payload,
|
|
|
|
size_t payload_len);
|
2017-07-21 23:48:18 +02:00
|
|
|
int hs_client_receive_introduce_ack(origin_circuit_t *circ,
|
|
|
|
const uint8_t *payload,
|
|
|
|
size_t payload_len);
|
2017-07-25 16:14:00 +02:00
|
|
|
int hs_client_receive_rendezvous2(origin_circuit_t *circ,
|
|
|
|
const uint8_t *payload,
|
|
|
|
size_t payload_len);
|
2017-07-21 23:48:18 +02:00
|
|
|
|
2017-07-21 20:32:47 +02:00
|
|
|
void hs_client_desc_has_arrived(const hs_ident_dir_conn_t *ident);
|
|
|
|
|
2017-07-21 21:19:32 +02:00
|
|
|
extend_info_t *hs_client_get_random_intro_from_edge(
|
|
|
|
const edge_connection_t *edge_conn);
|
|
|
|
|
2017-07-27 18:37:52 +02:00
|
|
|
int hs_client_reextend_intro_circuit(origin_circuit_t *circ);
|
|
|
|
|
2017-08-29 22:02:13 +02:00
|
|
|
void hs_client_free_all(void);
|
|
|
|
|
2017-05-02 15:22:00 +02:00
|
|
|
#endif /* TOR_HS_CLIENT_H */
|
|
|
|
|