integrate old code
Some checks are pending
continuous-integration/drone/push Build is running

This commit is contained in:
2019-03-31 18:04:01 +02:00
parent fb7d706dae
commit 819eb7d362
6 changed files with 82 additions and 29 deletions

View File

@@ -5,7 +5,7 @@ use std::io::{BufRead, BufReader, Error, ErrorKind, Result, Write};
use std::net::{IpAddr, SocketAddr};
use std::os::unix::net::UnixStream;
use std::path::PathBuf;
use std::time::Duration;
use std::time::{Duration, Instant};
pub struct Userspace(PathBuf);
@@ -49,8 +49,8 @@ impl WireguardController for Userspace {
};
match key.as_ref() {
"" => {
//Empty line means end of data
build_peer(&mut peer, builder); //TODO: handle possible actual error case
//Empty line means end of data
build_peer(&mut peer, builder); //TODO: handle possible actual error case
}
"public_key" => {
add_key(&mut peer, parse_err(ECCKey::from_base64(value))?)?;