websocket.DefaultDialer.Dial(url, headers)
改为
websocket.Dialer{TLSClientConfig: &tls.Config{RootCAs: nil, InsecureSkipVerify: true}}.Dial(url, headers)
忽略证书的校验即可解决
2023-09-27 21:16:16
websocket.DefaultDialer.Dial(url, headers)
改为
websocket.Dialer{TLSClientConfig: &tls.Config{RootCAs: nil, InsecureSkipVerify: true}}.Dial(url, headers)
忽略证书的校验即可解决