aboutsummaryrefslogtreecommitdiffstats
path: root/src/wireguard/types.rs
diff options
context:
space:
mode:
authorMathias Hall-Andersen <mathias@hall-andersen.dk>2020-03-29 18:21:48 +0200
committerMathias Hall-Andersen <mathias@hall-andersen.dk>2020-03-29 18:21:48 +0200
commit12a7b371d4fed75f3934cf7d3788a6cf51c33c22 (patch)
tree970fc1287d6cbdbd419ef9151e6e94a077b5a7fd /src/wireguard/types.rs
parentMerge branch 'tests' (diff)
downloadwireguard-rs-12a7b371d4fed75f3934cf7d3788a6cf51c33c22.tar.xz
wireguard-rs-12a7b371d4fed75f3934cf7d3788a6cf51c33c22.zip
Restructuring and dependency version bump.
Diffstat (limited to 'src/wireguard/types.rs')
-rw-r--r--src/wireguard/types.rs27
1 files changed, 0 insertions, 27 deletions
diff --git a/src/wireguard/types.rs b/src/wireguard/types.rs
index d4355a9..b899ed9 100644
--- a/src/wireguard/types.rs
+++ b/src/wireguard/types.rs
@@ -2,33 +2,6 @@ use clear_on_drop::clear::Clear;
use std::fmt;
use std::time::Instant;
-#[cfg(test)]
-pub fn dummy_keypair(initiator: bool) -> KeyPair {
- let k1 = Key {
- key: [0x53u8; 32],
- id: 0x646e6573,
- };
- let k2 = Key {
- key: [0x52u8; 32],
- id: 0x76636572,
- };
- if initiator {
- KeyPair {
- birth: Instant::now(),
- initiator: true,
- send: k1,
- recv: k2,
- }
- } else {
- KeyPair {
- birth: Instant::now(),
- initiator: false,
- send: k2,
- recv: k1,
- }
- }
-}
-
#[derive(Clone)]
pub struct Key {
pub key: [u8; 32],