diff --git a/common/client-core/surb-storage/src/lib.rs b/common/client-core/surb-storage/src/lib.rs index 079c213bbc..ffd7ad85f6 100644 --- a/common/client-core/surb-storage/src/lib.rs +++ b/common/client-core/surb-storage/src/lib.rs @@ -1,6 +1,7 @@ // Copyright 2022 - Nym Technologies SA // SPDX-License-Identifier: Apache-2.0 +#![allow(deprecated)] // silences clippy warning: use of deprecated associated function `nym_crypto::generic_array::GenericArray::::from_exact_iter`: please upgrade to generic-array 1.x - TODO pub use backend::*; pub use combined::CombinedReplyStorage; pub use key_storage::SentReplyKeys; diff --git a/common/cosmwasm-smart-contracts/coconut-dkg/src/types.rs b/common/cosmwasm-smart-contracts/coconut-dkg/src/types.rs index 6e4fdef06a..20d4920db6 100644 --- a/common/cosmwasm-smart-contracts/coconut-dkg/src/types.rs +++ b/common/cosmwasm-smart-contracts/coconut-dkg/src/types.rs @@ -1,6 +1,8 @@ // Copyright 2022-2023 - Nym Technologies SA // SPDX-License-Identifier: Apache-2.0 +#![allow(clippy::derivable_impls)] +// MAX: surpressing warning for the moment, will be dealt with in a different PR (TODO) use cosmwasm_schema::cw_serde; use std::fmt::{Display, Formatter}; use std::str::FromStr; diff --git a/common/crypto/src/lib.rs b/common/crypto/src/lib.rs index 3875fa7f81..4b455cf6a8 100644 --- a/common/crypto/src/lib.rs +++ b/common/crypto/src/lib.rs @@ -1,6 +1,8 @@ // Copyright 2021 - Nym Technologies SA // SPDX-License-Identifier: Apache-2.0 +#![allow(deprecated)] // silences clippy warning: deprecated associated function `generic_array::GenericArray::::from_exact_iter`: please upgrade to generic-array 1.x - TODO + #[cfg(feature = "asymmetric")] pub mod asymmetric; pub mod bech32_address_validation; diff --git a/common/gateway-requests/src/lib.rs b/common/gateway-requests/src/lib.rs index b63b29dca1..e577cb0e5a 100644 --- a/common/gateway-requests/src/lib.rs +++ b/common/gateway-requests/src/lib.rs @@ -1,5 +1,6 @@ // Copyright 2020-2022 - Nym Technologies SA // SPDX-License-Identifier: Apache-2.0 +#![allow(deprecated)] // silences clippy warning: deprecated associated function `nym_crypto::generic_array::GenericArray::::clone_from_slice`: please upgrade to generic-array 1.x - TODO pub use nym_crypto::generic_array; use nym_crypto::OutputSizeUser; diff --git a/common/gateway-requests/src/types/binary_request.rs b/common/gateway-requests/src/types/binary_request.rs index a0e75385f9..d38d4f7d19 100644 --- a/common/gateway-requests/src/types/binary_request.rs +++ b/common/gateway-requests/src/types/binary_request.rs @@ -70,7 +70,7 @@ impl BinaryRequest { let plaintext = match self { BinaryRequest::ForwardSphinx { packet } => packet.into_v1_bytes()?, - BinaryRequest::ForwardSphinxV2 { packet } => packet.into_v2_bytes()?, + BinaryRequest::ForwardSphinxV2 { packet } => packet.to_v2_bytes()?, }; BinaryData::make_encrypted_blob(kind as u8, &plaintext, shared_key) diff --git a/common/http-api-client/src/lib.rs b/common/http-api-client/src/lib.rs index 06a0511564..091b0c1995 100644 --- a/common/http-api-client/src/lib.rs +++ b/common/http-api-client/src/lib.rs @@ -1,6 +1,9 @@ // Copyright 2023 - Nym Technologies SA // SPDX-License-Identifier: Apache-2.0 +#![allow(deprecated)] +// silences clippy warning: use of deprecated tuple variant `HttpClientError::GenericRequestFailure`: use another more strongly typed variant - this variant is only left for compatibility reasons - TODO + //! Nym HTTP API Client //! //! Centralizes and implements the core API client functionality. This crate provides custom, diff --git a/common/nymsphinx/acknowledgements/src/lib.rs b/common/nymsphinx/acknowledgements/src/lib.rs index 490e94eaea..d37990d49f 100644 --- a/common/nymsphinx/acknowledgements/src/lib.rs +++ b/common/nymsphinx/acknowledgements/src/lib.rs @@ -1,5 +1,6 @@ // Copyright 2021 - Nym Technologies SA // SPDX-License-Identifier: Apache-2.0 +#![allow(deprecated)] // silences clippy warning: deprecated associated function `nym_crypto::generic_array::GenericArray::::clone_from_slice`: please upgrade to generic-array 1.x - TODO pub mod identifier; pub mod key; diff --git a/common/nymsphinx/anonymous-replies/Cargo.toml b/common/nymsphinx/anonymous-replies/Cargo.toml index fe9f272146..4cc0d68a80 100644 --- a/common/nymsphinx/anonymous-replies/Cargo.toml +++ b/common/nymsphinx/anonymous-replies/Cargo.toml @@ -12,6 +12,7 @@ rand = { workspace = true } bs58 = { workspace = true } thiserror = { workspace = true } tracing = { workspace = true } +serde = { workspace = true } nym-crypto = { workspace = true, features = ["stream_cipher", "rand"] } nym-sphinx-addressing = { workspace = true } diff --git a/common/nymsphinx/anonymous-replies/src/lib.rs b/common/nymsphinx/anonymous-replies/src/lib.rs index 2c47a23a76..84bfa7a323 100644 --- a/common/nymsphinx/anonymous-replies/src/lib.rs +++ b/common/nymsphinx/anonymous-replies/src/lib.rs @@ -1,6 +1,7 @@ // Copyright 2021 - Nym Technologies SA // SPDX-License-Identifier: Apache-2.0 +#![allow(deprecated)] // silences clippy warning: deprecated struct `nym_crypto::generic_array::GenericArray`: please upgrade to generic-array 1.x - TODO pub mod encryption_key; pub mod reply_surb; pub mod requests; diff --git a/common/nymsphinx/anonymous-replies/src/requests/mod.rs b/common/nymsphinx/anonymous-replies/src/requests/mod.rs index ecb2fc7ac5..b6916a20e8 100644 --- a/common/nymsphinx/anonymous-replies/src/requests/mod.rs +++ b/common/nymsphinx/anonymous-replies/src/requests/mod.rs @@ -7,6 +7,7 @@ use crate::{ReplySurbError, ReplySurbWithKeyRotation}; use nym_sphinx_addressing::clients::{Recipient, RecipientFormattingError}; use nym_sphinx_params::key_rotation::InvalidSphinxKeyRotation; use rand::{CryptoRng, RngCore}; +use serde::{Deserialize, Serialize}; use std::fmt::{Display, Formatter}; use std::mem; use thiserror::Error; @@ -30,7 +31,7 @@ pub enum InvalidAnonymousSenderTagRepresentation { InvalidLength { received: usize, expected: usize }, } -#[derive(Debug, Copy, Clone, Eq, PartialEq, Hash)] +#[derive(Debug, Copy, Clone, Eq, PartialEq, Hash, Serialize, Deserialize)] #[cfg_attr(target_arch = "wasm32", wasm_bindgen)] pub struct AnonymousSenderTag([u8; SENDER_TAG_SIZE]); diff --git a/common/store-cipher/src/lib.rs b/common/store-cipher/src/lib.rs index 98d586151f..5119021d16 100644 --- a/common/store-cipher/src/lib.rs +++ b/common/store-cipher/src/lib.rs @@ -1,6 +1,7 @@ // Copyright 2023 - Nym Technologies SA // SPDX-License-Identifier: Apache-2.0 +#![allow(deprecated)] use aes_gcm::aead::{Aead, Nonce}; use aes_gcm::{AeadCore, AeadInPlace, KeyInit}; use rand::{thread_rng, CryptoRng, Fill, RngCore}; diff --git a/nym-outfox/src/lib.rs b/nym-outfox/src/lib.rs index e10d30e846..0d278c06d7 100644 --- a/nym-outfox/src/lib.rs +++ b/nym-outfox/src/lib.rs @@ -1,3 +1,6 @@ +// MAX: temp ignore deprecated, can be dealt with in its own PR +#![allow(deprecated)] // silences clippy warning: deprecated associated function `chacha20::cipher::generic_array::GenericArray::::from_slice`: please upgrade to generic-array 1.x - TODO + pub mod constants; pub mod error; pub mod format;