Jelajahi Sumber

Merge pull request #150 from DravenJohnson/master

Fix: Fix if condition problem at opensslConn.go L99.
Rod Hynes 10 tahun lalu
induk
melakukan
b1e5df3c3f
1 mengubah file dengan 1 tambahan dan 1 penghapusan
  1. 1 1
      psiphon/opensslConn.go

+ 1 - 1
psiphon/opensslConn.go

@@ -96,7 +96,7 @@ func newOpenSSLConn(rawConn net.Conn, hostname string, config *CustomTLSConfig)
 		return nil, ContextError(err)
 	}
 
-	if config.SNIServerName {
+	if config.SNIServerName != "" {
 		// Explicitly exclude IPs:
 		// - "Literal IPv4 and IPv6 addresses are not permitted": https://tools.ietf.org/html/rfc6066#page-6.
 		// - OpenSSL does not appear to enforce this rule itself.