bip_util/bt.rs
1use sha;
2
3/// Bittorrent `NodeId`.
4pub type NodeId = sha::ShaHash;
5
6/// Bittorrent `PeerId`.
7pub type PeerId = sha::ShaHash;
8
9/// Bittorrent `InfoHash`.
10pub type InfoHash = sha::ShaHash;
11
12/// Length of a `NodeId`.
13pub const NODE_ID_LEN: usize = sha::SHA_HASH_LEN;
14
15/// Length of a `PeerId`.
16pub const PEER_ID_LEN: usize = sha::SHA_HASH_LEN;
17
18/// Length of an `InfoHash`.
19pub const INFO_HASH_LEN: usize = sha::SHA_HASH_LEN;