diff options
author | Alex Auvolat <alex@adnab.me> | 2022-07-22 13:06:10 +0200 |
---|---|---|
committer | Alex Auvolat <alex@adnab.me> | 2022-07-22 13:06:10 +0200 |
commit | 5da59ebec5f3072d0b6c3b1ffc90eb8923c50ad9 (patch) | |
tree | cd5c08198db5a0b8499dfb80222d82e8d0518ab2 /src/netapp.rs | |
parent | 9cb28c21b4a80aa9f29097f6bb1b8b6c23446ddc (diff) | |
download | netapp-5da59ebec5f3072d0b6c3b1ffc90eb8923c50ad9.tar.gz netapp-5da59ebec5f3072d0b6c3b1ffc90eb8923c50ad9.zip |
Move things around and fix error bit
Diffstat (limited to 'src/netapp.rs')
-rw-r--r-- | src/netapp.rs | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/netapp.rs b/src/netapp.rs index 166f560..29df3b9 100644 --- a/src/netapp.rs +++ b/src/netapp.rs @@ -22,7 +22,13 @@ use crate::endpoint::*; use crate::error::*; use crate::message::*; use crate::server::*; -use crate::util::*; + +/// A node's identifier, which is also its public cryptographic key +pub type NodeID = sodiumoxide::crypto::sign::ed25519::PublicKey; +/// A node's secret key +pub type NodeKey = sodiumoxide::crypto::sign::ed25519::SecretKey; +/// A network key +pub type NetworkKey = sodiumoxide::crypto::auth::Key; /// Tag which is exchanged between client and server upon connection establishment /// to check that they are running compatible versions of Netapp, |