mirror of
https://github.com/bjdgyc/anylink.git
synced 2025-08-08 09:04:52 +08:00
feat:根据SNI返回SSL证书
This commit is contained in:
@@ -49,8 +49,8 @@ func startTls() {
|
||||
NextProtos: []string{"http/1.1"},
|
||||
MinVersion: tls.VersionTLS12,
|
||||
CipherSuites: selectedCipherSuites,
|
||||
GetCertificate: func(*tls.ClientHelloInfo) (*tls.Certificate, error) {
|
||||
return dbdata.TLSCert, nil
|
||||
GetCertificate: func(chi *tls.ClientHelloInfo) (*tls.Certificate, error) {
|
||||
return dbdata.GetCertificateBySNI(chi.ServerName)
|
||||
},
|
||||
// InsecureSkipVerify: true,
|
||||
}
|
||||
|
Reference in New Issue
Block a user