commit
508dbb95a1
@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "tokio-rustls"
|
||||
version = "0.6.0"
|
||||
version = "0.7.0"
|
||||
authors = ["quininer kel <quininer@live.com>"]
|
||||
license = "MIT/Apache-2.0"
|
||||
repository = "https://github.com/quininer/tokio-rustls"
|
||||
@ -18,8 +18,8 @@ appveyor = { repository = "quininer/tokio-rustls" }
|
||||
futures-core = { version = "0.2.0", optional = true }
|
||||
futures-io = { version = "0.2.0", optional = true }
|
||||
tokio = { version = "0.1.6", optional = true }
|
||||
rustls = "0.12"
|
||||
webpki = "0.18.0-alpha"
|
||||
rustls = "0.13"
|
||||
webpki = "0.18.1"
|
||||
|
||||
[dev-dependencies]
|
||||
# futures = "0.2.0"
|
||||
|
@ -4,14 +4,14 @@ version = "0.1.0"
|
||||
authors = ["quininer <quininer@live.com>"]
|
||||
|
||||
[dependencies]
|
||||
rustls = "0.12"
|
||||
webpki = "0.18.0-alpha"
|
||||
rustls = "0.13"
|
||||
webpki = "0.18.1"
|
||||
tokio-rustls = { path = "../..", default-features = false, features = [ "tokio" ] }
|
||||
|
||||
tokio = "0.1"
|
||||
|
||||
clap = "2.26"
|
||||
webpki-roots = "0.14"
|
||||
webpki-roots = "0.15"
|
||||
|
||||
[target.'cfg(unix)'.dependencies]
|
||||
tokio-file-unix = "0.5"
|
||||
|
@ -4,7 +4,7 @@ version = "0.1.0"
|
||||
authors = ["quininer <quininer@live.com>"]
|
||||
|
||||
[dependencies]
|
||||
rustls = "0.12"
|
||||
rustls = "0.13"
|
||||
tokio-rustls = { path = "../..", default-features = false, features = [ "tokio" ] }
|
||||
|
||||
tokio = { version = "0.1.6" }
|
||||
|
@ -45,7 +45,8 @@ fn main() {
|
||||
let flag_echo = matches.occurrences_of("echo") > 0;
|
||||
|
||||
let mut config = ServerConfig::new(NoClientAuth::new());
|
||||
config.set_single_cert(load_certs(cert_file), load_keys(key_file).remove(0));
|
||||
config.set_single_cert(load_certs(cert_file), load_keys(key_file).remove(0))
|
||||
.expect("invalid key or certificate");
|
||||
let arc_config = Arc::new(config);
|
||||
|
||||
let socket = TcpListener::bind(&addr).unwrap();
|
||||
|
@ -26,7 +26,8 @@ fn start_server(cert: Vec<Certificate>, rsa: PrivateKey) -> SocketAddr {
|
||||
use tokio::io as aio;
|
||||
|
||||
let mut config = ServerConfig::new(rustls::NoClientAuth::new());
|
||||
config.set_single_cert(cert, rsa);
|
||||
config.set_single_cert(cert, rsa)
|
||||
.expect("invalid key or certificate");
|
||||
let config = Arc::new(config);
|
||||
|
||||
let (send, recv) = channel();
|
||||
|
Loading…
Reference in New Issue
Block a user