Tor
0.4.6.0-alpha-dev
feature
nodelist
vote_routerstatus_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-2020, The Tor Project, Inc. */
5
/* See LICENSE for licensing information */
6
7
/**
8
* @file vote_routerstatus_st.h
9
* @brief Routerstatus (vote entry) structure
10
**/
11
#ifndef VOTE_ROUTERSTATUS_ST_H
12
#define VOTE_ROUTERSTATUS_ST_H
13
14
#include "
feature/nodelist/routerstatus_st.h
"
15
#include "
lib/defs/x25519_sizes.h
"
16
17
/** The claim about a single router, made in a vote. */
18
struct
vote_routerstatus_t
{
19
routerstatus_t
status
;
/**< Underlying 'status' object for this router.
20
* Flags are redundant. */
21
/** How many known-flags are allowed in a vote? This is the width of
22
* the flags field of vote_routerstatus_t */
23
#define MAX_KNOWN_FLAGS_IN_VOTE 64
24
uint64_t
flags
;
/**< Bit-field for all recognized flags; index into
25
* networkstatus_t.known_flags. */
26
char
*
version
;
/**< The version that the authority says this router is
27
* running. */
28
char
*
protocols
;
/**< The protocols that this authority says this router
29
* provides. */
30
unsigned
int
has_measured_bw
:1;
/**< The vote had a measured bw */
31
/** True iff the vote included an entry for ed25519 ID, or included
32
* "id ed25519 none" to indicate that there was no ed25519 ID. */
33
unsigned
int
has_ed25519_listing
:1;
34
/** True if the Ed25519 listing here is the consensus-opinion for the
35
* Ed25519 listing; false if there was no consensus on Ed25519 key status,
36
* or if this VRS doesn't reflect it. */
37
unsigned
int
ed25519_reflects_consensus
:1;
38
uint32_t
measured_bw_kb
;
/**< Measured bandwidth (capacity) of the router */
39
/** The hash or hashes that the authority claims this microdesc has. */
40
vote_microdesc_hash_t
*
microdesc
;
41
/** Ed25519 identity for this router, or zero if it has none. */
42
uint8_t
ed25519_id
[
ED25519_PUBKEY_LEN
];
43
};
44
45
#endif
/* !defined(VOTE_ROUTERSTATUS_ST_H) */
vote_routerstatus_t::microdesc
vote_microdesc_hash_t * microdesc
Definition:
vote_routerstatus_st.h:40
vote_microdesc_hash_t
Definition:
vote_microdesc_hash_st.h:18
routerstatus_t
Definition:
routerstatus_st.h:19
ED25519_PUBKEY_LEN
#define ED25519_PUBKEY_LEN
Definition:
x25519_sizes.h:27
vote_routerstatus_t::version
char * version
Definition:
vote_routerstatus_st.h:26
vote_routerstatus_t::flags
uint64_t flags
Definition:
vote_routerstatus_st.h:24
vote_routerstatus_t::ed25519_id
uint8_t ed25519_id[ED25519_PUBKEY_LEN]
Definition:
vote_routerstatus_st.h:42
vote_routerstatus_t
Definition:
vote_routerstatus_st.h:18
vote_routerstatus_t::has_measured_bw
unsigned int has_measured_bw
Definition:
vote_routerstatus_st.h:30
vote_routerstatus_t::has_ed25519_listing
unsigned int has_ed25519_listing
Definition:
vote_routerstatus_st.h:33
routerstatus_st.h
Routerstatus (consensus entry) structure.
vote_routerstatus_t::protocols
char * protocols
Definition:
vote_routerstatus_st.h:28
vote_routerstatus_t::status
routerstatus_t status
Definition:
vote_routerstatus_st.h:19
vote_routerstatus_t::ed25519_reflects_consensus
unsigned int ed25519_reflects_consensus
Definition:
vote_routerstatus_st.h:37
vote_routerstatus_t::measured_bw_kb
uint32_t measured_bw_kb
Definition:
vote_routerstatus_st.h:38
x25519_sizes.h
Definitions for sizes of x25519 keys and elements.
Generated by
1.8.20