mirror of
https://github.com/fluencelabs/rust-libp2p
synced 2025-05-23 08:01:19 +00:00
Fix exchange algorithm in secio (#257)
This commit is contained in:
parent
f74cf9f126
commit
8fb919321b
@ -285,7 +285,7 @@ where
|
||||
|
||||
// Generate an ephemeral key for the negotiation.
|
||||
.and_then(|(socket, context)| {
|
||||
match EphemeralPrivateKey::generate(&agreement::ECDH_P256, &context.rng) {
|
||||
match EphemeralPrivateKey::generate(context.chosen_exchange.as_ref().unwrap(), &context.rng) {
|
||||
Ok(tmp_priv_key) => Ok((socket, context, tmp_priv_key)),
|
||||
Err(_) => {
|
||||
debug!("failed to generate ECDH key");
|
||||
|
Loading…
x
Reference in New Issue
Block a user