diff options
Diffstat (limited to 'src/packet_content.rs')
| -rw-r--r-- | src/packet_content.rs | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/packet_content.rs b/src/packet_content.rs index a6fa914..5b762d7 100644 --- a/src/packet_content.rs +++ b/src/packet_content.rs @@ -11,8 +11,7 @@ use crate::{ }; use bytes::{Buf, Bytes}; -#[cfg(feature = "std")] -use crate::std_identity::Keystore; +use crate::crypto::Keystore; #[derive(PartialEq, Clone, core::fmt::Debug)] pub enum PacketContent { @@ -152,8 +151,7 @@ impl From<Bytes> for PeerToPeerCipher { } impl PeerToPeerCipher { - #[cfg(feature = "std")] - pub fn try_decrypt(&mut self, keystore: &Keystore) -> bool { + pub fn try_decrypt<T: Keystore>(&mut self, keystore: &T) -> bool { let decrypt = keystore.decrypt_and_id_p2p(self.source, self.destination, self.mac, &self.ciphertext); |
