Tor  0.4.3.0-alpha-dev
rend_service_descriptor_st.h
Go to the documentation of this file.
1 /* Copyright (c) 2001 Matej Pfajfar.
2  * Copyright (c) 2001-2004, Roger Dingledine.
3  * Copyright (c) 2004-2006, Roger Dingledine, Nick Mathewson.
4  * Copyright (c) 2007-2019, The Tor Project, Inc. */
5 /* See LICENSE for licensing information */
6 
7 /**
8  * @file rend_service_descriptor_st.h
9  * @brief Parsed v2 HS descriptor structure.
10  **/
11 
12 #ifndef REND_SERVICE_DESCRIPTOR_ST_H
13 #define REND_SERVICE_DESCRIPTOR_ST_H
14 
15 #define REND_PROTOCOL_VERSION_BITMASK_WIDTH 16
16 
17 /** Information used to connect to a hidden service. Used on both the
18  * service side and the client side. */
20  crypto_pk_t *pk; /**< This service's public key. */
21  int version; /**< Version of the descriptor format: 0 or 2. */
22  time_t timestamp; /**< Time when the descriptor was generated. */
23  /** Bitmask: which introduce/rendezvous protocols are supported?
24  * (We allow bits '0', '1', '2' and '3' to be set.) */
25  unsigned protocols : REND_PROTOCOL_VERSION_BITMASK_WIDTH;
26  /** List of the service's introduction points. Elements are removed if
27  * introduction attempts fail. */
29  /** Has descriptor been uploaded to all hidden service directories? */
31  /** List of hidden service directories to which an upload request for
32  * this descriptor could be sent. Smartlist exists only when at least one
33  * of the previous upload requests failed (otherwise it's not important
34  * to know which uploads succeeded and which not). */
36 };
37 
38 #endif /* !defined(REND_SERVICE_DESCRIPTOR_ST_H) */