- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 10 for VerifyHostname (0.2 sec)
-
okhttp/src/main/kotlin/okhttp3/internal/tls/OkHostnameVerifier.kt
} } /** Returns true if [certificate] matches [hostname]. */ private fun verifyHostname( hostname: String, certificate: X509Certificate, ): Boolean { val hostname = hostname.asciiToLowercase() return getSubjectAltNames(certificate, ALT_DNS_NAME).any { verifyHostname(hostname, it) } } /**
Registered: Sun Jun 16 04:42:17 UTC 2024 - Last Modified: Mon Apr 15 14:55:09 UTC 2024 - 7.7K bytes - Viewed (0) -
src/crypto/x509/verify.go
// VerifyOptions contains parameters for Certificate.Verify. type VerifyOptions struct { // DNSName, if set, is checked against the leaf certificate with // Certificate.VerifyHostname or the platform verifier. DNSName string // Intermediates is an optional pool of certificates that are not trust // anchors, but can be used to form a chain from the leaf certificate to a // root certificate.
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed May 22 22:58:39 UTC 2024 - 35.7K bytes - Viewed (0) -
src/crypto/x509/x509_test.go
}, } err = c.VerifyHostname("1.2.3.4") if err == nil { t.Fatalf("VerifyHostname(1.2.3.4) should have failed, did not") } c = &Certificate{ IPAddresses: []net.IP{net.ParseIP("127.0.0.1"), net.ParseIP("::1")}, } err = c.VerifyHostname("127.0.0.1") if err != nil { t.Fatalf("VerifyHostname(127.0.0.1): %v", err) } err = c.VerifyHostname("::1") if err != nil {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed May 22 21:00:16 UTC 2024 - 163.4K bytes - Viewed (0) -
src/crypto/tls/conn.go
return c.ocspResponse } // VerifyHostname checks that the peer certificate chain is valid for // connecting to host. If so, it returns nil; if not, it returns an error // describing the problem. func (c *Conn) VerifyHostname(host string) error { c.handshakeMutex.Lock() defer c.handshakeMutex.Unlock() if !c.isClient { return errors.New("tls: VerifyHostname called on TLS server connection") }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 23 03:10:12 UTC 2024 - 51.8K bytes - Viewed (0) -
src/crypto/tls/tls_test.go
testenv.MustHaveExternalNetwork(t) c, err := Dial("tcp", "www.google.com:https", nil) if err != nil { t.Fatal(err) } if err := c.VerifyHostname("www.google.com"); err != nil { t.Fatalf("verify www.google.com: %v", err) } if err := c.VerifyHostname("www.yahoo.com"); err == nil { t.Fatalf("verify www.yahoo.com succeeded") } c, err = Dial("tcp", "www.google.com:https", &Config{InsecureSkipVerify: true})
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 23 03:10:12 UTC 2024 - 60.5K bytes - Viewed (0) -
src/crypto/x509/verify_test.go
} c, err := ParseCertificate(cDER) if err != nil { t.Fatalf("failed to parse certificate: %s", err) } if err := c.VerifyHostname("label"); err == nil { t.Fatalf("VerifyHostname unexpected success with bare wildcard SAN") }
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 23 01:00:11 UTC 2024 - 110.2K bytes - Viewed (0) -
src/crypto/x509/name_constraints_test.go
{}, }, }, leaf: leafSpec{ sans: []string{"unknown:"}, }, }, // #30: without SANs, a certificate with a CN is still accepted in a // constrained chain, since we ignore the CN in VerifyHostname. { roots: []constraintsSpec{ { ok: []string{"dns:foo.com", "dns:.foo.com"}, }, }, intermediates: [][]constraintsSpec{ { {}, }, }, leaf: leafSpec{
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 09 22:40:21 UTC 2024 - 45.2K bytes - Viewed (0) -
src/crypto/tls/handshake_client.go
if len(session.verifiedChains) == 0 { // The original connection had InsecureSkipVerify, while this doesn't. return nil, nil, nil, nil } if err := session.peerCertificates[0].VerifyHostname(c.config.ServerName); err != nil { return nil, nil, nil, nil } } if session.version != VersionTLS13 { // In TLS 1.2 the cipher suite must match the resumed session. Ensure we
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 23 03:10:12 UTC 2024 - 38.6K bytes - Viewed (0) -
src/crypto/tls/common.go
// certificate needs to be valid for it. if chi.ServerName != "" { x509Cert, err := c.leaf() if err != nil { return fmt.Errorf("failed to parse certificate: %w", err) } if err := x509Cert.VerifyHostname(chi.ServerName); err != nil { return fmt.Errorf("certificate is not valid for requested server name: %w", err) } } // supportsRSAFallback returns nil if the certificate and connection support
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 23 03:10:12 UTC 2024 - 59.1K bytes - Viewed (0) -
src/cmd/vendor/golang.org/x/tools/internal/stdlib/manifest.go
{"(*Conn).Read", Method, 0}, {"(*Conn).RemoteAddr", Method, 0}, {"(*Conn).SetDeadline", Method, 0}, {"(*Conn).SetReadDeadline", Method, 0}, {"(*Conn).SetWriteDeadline", Method, 0}, {"(*Conn).VerifyHostname", Method, 0}, {"(*Conn).Write", Method, 0}, {"(*ConnectionState).ExportKeyingMaterial", Method, 11}, {"(*Dialer).Dial", Method, 15}, {"(*Dialer).DialContext", Method, 15}, {"(*QUICConn).Close", Method, 21},
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Tue Apr 02 02:20:05 UTC 2024 - 534.2K bytes - Viewed (0)