Skip to main content

Module handshake

Module handshake 

Source
Expand description

Features for manual invocation of Tor’s cryptographic circuit handshakes.

These features are used to implement onion services, by giving the onion service code more direct control over the lower-level pieces of the protocol.

Re-exportsΒ§

use tor_cell::relaycell::RelayCellFormat; πŸ”’
use tor_error::internal; πŸ”’
use crate::crypto::binding::CircuitBinding; πŸ”’
use crate::crypto::cell::CgoRelayCrypto; πŸ”’
use crate::crypto::cell::Tor1Hsv3RelayCrypto; πŸ”’
use crate::crypto::cell::ClientLayer; πŸ”’
use crate::crypto::cell::CryptInit; πŸ”’
use crate::crypto::cell::InboundClientLayer; πŸ”’
use crate::crypto::cell::InboundRelayLayer; πŸ”’
use crate::crypto::cell::OutboundClientLayer; πŸ”’
use crate::crypto::cell::OutboundRelayLayer; πŸ”’
use crate::crypto::cell::RelayLayer; πŸ”’
use crate::crypto::cell::Tor1RelayCrypto; πŸ”’
use crate::Result; πŸ”’
pub use crate::crypto::handshake::KeyGenerator;
pub use crate::crypto::handshake::hs_ntor;

StructsΒ§

BoxedClientLayer πŸ”’
A set of type-erased cryptographic layers to use for a single hop at a client.
ResponderInboundLayer πŸ”’
Wrapper to make a relay layer behave as a client layer.
ResponderOutboundLayer πŸ”’
Wrapper to make a relay layer behave as a client layer.

EnumsΒ§

HandshakeRole
What role we are playing in a handshake.
RelayCryptLayerProtocol πŸ”’
Internal counterpart of RelayProtocol; includes variants that can’t be negotiated from extend_virtual.
RelayProtocol
The relay protocol to use when extending a circuit manually with Circuit::extend_virtual.

FunctionsΒ§

construct πŸ”’
Helper: Construct a BoxedClientLayer for a layer type L whose inbound and outbound cryptographic states are the same type.