b231eb4f04
* Remove AsyncRead/Write traits from native client - moving them to stream/ * Substream model first push * Update / add examples * Update lockfile * Clippy * clippy examples * remove codecs * Remove unused bincode setup * Revert a lot of changes when SDK client itself implemented AsyncRead/Write * Remove unnecessary mut * Use local PollSender in MixnetStream instead of client_input.input_sender Now that client-core's input_sender is back to mpsc::Sender (reverted PollSender migration), MixnetStream creates its own PollSender wrapper for the AsyncWrite impl's poll_ready/start_send calls. * Remove now-unnecessary parameter * Clippy * Cleanup more stragglers from previous setup (Async traits on MixnetClient) * Rename files (remove module inception) * - Shrink StreamId from 16 bytes to u64, add version byte to wire format - Introduce MixStreamHeader/MixStreamFrame structs for decode - Replace StreamMap type alias with struct using tokio::sync::Mutex - Add StreamMap helper methods, eliminate lock().expect() panics - Rename stream.rs -> mixnet_stream.rs to avoid module inception - Document irrevocable stream mode, add LP integration TODO * - Remove dummy channel - Add err variant for reciever alredy taken - Remove panics * add timeout to stream * clippy
34 lines
1.2 KiB
Rust
34 lines
1.2 KiB
Rust
// Copyright 2021 - Nym Technologies SA <contact@nymtech.net>
|
|
// SPDX-License-Identifier: Apache-2.0
|
|
|
|
#![allow(deprecated)] // silences clippy warning: deprecated associated function `generic_array::GenericArray::<T, N>::from_exact_iter`: please upgrade to generic-array 1.x - TODO
|
|
|
|
#[cfg(feature = "asymmetric")]
|
|
pub mod asymmetric;
|
|
pub mod bech32_address_validation;
|
|
#[cfg(feature = "hashing")]
|
|
pub mod crypto_hash;
|
|
#[cfg(feature = "hashing")]
|
|
pub mod hkdf;
|
|
#[cfg(feature = "hashing")]
|
|
pub mod hmac;
|
|
#[cfg(all(feature = "asymmetric", feature = "hashing", feature = "stream_cipher"))]
|
|
pub mod shared_key;
|
|
pub mod symmetric;
|
|
|
|
#[cfg(feature = "hashing")]
|
|
pub use digest::{Digest, OutputSizeUser};
|
|
#[cfg(any(feature = "hashing", feature = "stream_cipher", feature = "aead"))]
|
|
pub use generic_array;
|
|
|
|
// with the below my idea was to try to introduce having a single place of importing all hashing, encryption,
|
|
// etc. algorithms and import them elsewhere as needed via common/crypto
|
|
#[cfg(feature = "stream_cipher")]
|
|
pub use aes;
|
|
#[cfg(feature = "aead")]
|
|
pub use aes_gcm_siv::{Aes128GcmSiv, Aes256GcmSiv};
|
|
#[cfg(feature = "hashing")]
|
|
pub use blake3;
|
|
#[cfg(feature = "stream_cipher")]
|
|
pub use ctr;
|