enable sni for tls client (#691)

* enable sni for tls client
* update test case
* fix public_ip parse bug
This commit is contained in:
kevin
2025-03-19 01:15:34 +08:00
committed by GitHub
parent 3d1e841cc5
commit 81490d0662
4 changed files with 14 additions and 3 deletions
@@ -434,7 +434,7 @@ impl PunchSymToConeHoleClient {
let public_ips: Vec<Ipv4Addr> = stun_info
.public_ip
.iter()
.map(|x| x.parse().unwrap())
.filter_map(|x| x.parse().ok())
.collect();
if public_ips.is_empty() {
return Err(anyhow::anyhow!("failed to get public ips"));