Trait OutboundClientLayer

Source
pub(crate) trait OutboundClientLayer {
    // Required methods
    fn originate_for(
        &mut self,
        cmd: ChanCmd,
        cell: &mut RelayCellBody,
    ) -> SendmeTag;
    fn encrypt_outbound(&mut self, cmd: ChanCmd, cell: &mut RelayCellBody);
}
Expand description

A client’s view of the cryptographic state shared with a single relay on a circuit, as used for outbound cells.

Required Methods§

Source

fn originate_for(&mut self, cmd: ChanCmd, cell: &mut RelayCellBody) -> SendmeTag

Prepare a RelayCellBody to be sent to the relay at this layer, and encrypt it.

Return the authentication tag.

Source

fn encrypt_outbound(&mut self, cmd: ChanCmd, cell: &mut RelayCellBody)

Encrypt a RelayCellBody to be decrypted by this layer.

Implementors§

Source§

impl<EtBC, PrfBC> OutboundClientLayer for tor_proto::crypto::cell::cgo::ClientOutbound<EtBC, PrfBC>
where EtBC: BlkCipherDec, PrfBC: BlkCipherEnc,

Available on crate feature counter-galois-onion only.
Source§

impl<L: InboundRelayLayer> OutboundClientLayer for ResponderOutboundLayer<L>

Available on crate feature hs-common only.
Source§

impl<SC: StreamCipher, D: Digest + Clone> OutboundClientLayer for tor_proto::crypto::cell::tor1::ClientOutbound<SC, D>