diff options
author | pennae <github@quasiparticle.net> | 2022-07-17 17:32:54 +0200 |
---|---|---|
committer | pennae <github@quasiparticle.net> | 2022-07-17 17:32:54 +0200 |
commit | 3eda99e9efbdfc2cb0e20932f20018d53baf5a64 (patch) | |
tree | 058d266f4a193bd4de931f39bb115c7225376507 /src/crypto.rs | |
parent | 1ef9d67fb6979ea91812c4ea892f7ecc12b3170f (diff) | |
download | minor-skulk-3eda99e9efbdfc2cb0e20932f20018d53baf5a64.tar.gz minor-skulk-3eda99e9efbdfc2cb0e20932f20018d53baf5a64.tar.xz minor-skulk-3eda99e9efbdfc2cb0e20932f20018d53baf5a64.zip |
make the Clone bytes types Copy as well
u8 arrays are copy, no need to not have our wrappers be copy.
Diffstat (limited to 'src/crypto.rs')
-rw-r--r-- | src/crypto.rs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/crypto.rs b/src/crypto.rs index 58ab6d2..a188f46 100644 --- a/src/crypto.rs +++ b/src/crypto.rs @@ -111,7 +111,7 @@ impl StretchedPW { } } -#[derive(Clone, Serialize, Deserialize, PartialEq, Eq)] +#[derive(Clone, Copy, Serialize, Deserialize, PartialEq, Eq)] pub(crate) struct SessionToken(#[serde(with = "as_hex")] [u8; 32]); impl Debug for SessionToken { @@ -138,7 +138,7 @@ impl SessionCredentials { } } -#[derive(Clone, Serialize, Deserialize, PartialEq, Eq)] +#[derive(Clone, Copy, Serialize, Deserialize, PartialEq, Eq)] pub(crate) struct KeyFetchToken(#[serde(with = "as_hex")] [u8; 32]); impl Debug for KeyFetchToken { @@ -222,7 +222,7 @@ impl WrappedKeyBundle { } } -#[derive(Clone, Serialize, Deserialize, PartialEq, Eq)] +#[derive(Clone, Copy, Serialize, Deserialize, PartialEq, Eq)] pub(crate) struct PasswordChangeToken(#[serde(with = "as_hex")] [u8; 32]); impl Debug for PasswordChangeToken { @@ -254,7 +254,7 @@ impl PasswordChangeReq { } } -#[derive(Clone, Serialize, Deserialize, PartialEq, Eq)] +#[derive(Clone, Copy, Serialize, Deserialize, PartialEq, Eq)] pub(crate) struct AccountResetToken(#[serde(with = "as_hex")] [u8; 32]); impl Debug for AccountResetToken { |