diff options
| author | adnano <[email protected]> | 2020-09-27 13:50:48 -0400 |
|---|---|---|
| committer | adnano <[email protected]> | 2020-09-27 13:50:48 -0400 |
| commit | 2eb7fb9ba48751cb26efd6324285be3f1f4a98da (patch) | |
| tree | dbaceef3ff42918971042ba86b4160cf4387ec64 /client.go | |
| parent | Adjust user prompt in client example (diff) | |
| download | go-gemini-2eb7fb9ba48751cb26efd6324285be3f1f4a98da.tar.xz go-gemini-2eb7fb9ba48751cb26efd6324285be3f1f4a98da.zip | |
Implement certificate creation
Diffstat (limited to 'client.go')
| -rw-r--r-- | client.go | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -205,8 +205,8 @@ func (c *Client) Send(req *Request) (*Response, error) { return err } // Check that the certificate is valid for the hostname - if cert.Subject.CommonName != hostname(req.Host) { - return ErrCertificateNotValid + if err := cert.VerifyHostname(req.Host); err != nil { + return err } // Check that the client trusts the certificate if c.TrustCertificate == nil { |