diff --git a/dtls/src/conn/mod.rs b/dtls/src/conn/mod.rs index 1a140587b..960134832 100644 --- a/dtls/src/conn/mod.rs +++ b/dtls/src/conn/mod.rs @@ -407,7 +407,10 @@ impl DTLSConn { }); // Do handshake - c.handshake(initial_fsm_state).await?; + // Temporary fix until https://github.com/webrtc-rs/webrtc/issues/614 is solved + tokio::time::timeout(Duration::from_secs(3), c.handshake(initial_fsm_state)) + .await + .map_err(|_| Error::ErrConnClosed)??; trace!("Handshake Completed");