nervosnetwork / tentacle

A multiplexed p2p network framework that supports custom protocols
https://docs.rs/tentacle
MIT License
54 stars 24 forks source link

Tls reconnect error #332

Closed Pencil-Yao closed 3 years ago

Pencil-Yao commented 3 years ago

I found a stituation: in tls mod, using correct tls-certificate, the client end could reconnect to server many many times. But after any bad node using error certifacte and occur tls-handshake error, the good node can't reconnect forever.

For reproducing error, I write a ut https://github.com/Pencil-Yao/tentacle/blob/tls-reconnect-err/tentacle/tests/test_tls_reconnect.rs. In the ut, node0 and node1 is ok, node2 use error certificate, and test_tls_reconnect_wrong can not be done.