Skip to content

crypto/tls: func (c *Conn) Handshake() returns an error on Windows 7 #30985

Description

@admitrevskiy

What version of Go are you using (go version)?

1.12

Does this issue reproduce with the latest release?

Yes

What operating system and processor architecture are you using (go env)?

Windows 7 x64

What did you do?

Hi!
func (c *Conn) Handshake() in package crypto/tls/ works perfectly on every OS except for Windows 7/Windows 2012 R2/etc. The following example demonstrates the problem:
https://github.com/admitrevskiy/tls_example
Please note that the ServerName inside tls.Config is 1.1.1.1.

What did you expect to see?

No error

What did you see instead?

Failed to connect to 1.1.1.1:853, cause: x509: certificate is valid for
 1.1.1.1, 1.0.0.1, 162.159.132.53, 2606:4700:4700::1111, 2606:4700:4700::1001, 2
606:4700:4700::64, 2606:4700:4700::6400, not 1.1.1.1

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions