leaf returns the parsed leaf certificate, either from c.Leaf or by parsing the corresponding c.Certificate[0].
()
| 1611 | // leaf returns the parsed leaf certificate, either from c.Leaf or by parsing |
| 1612 | // the corresponding c.Certificate[0]. |
| 1613 | func (c *Certificate) leaf() (*x509.Certificate, error) { |
| 1614 | if c.Leaf != nil { |
| 1615 | return c.Leaf, nil |
| 1616 | } |
| 1617 | return x509.ParseCertificate(c.Certificate[0]) |
| 1618 | } |
| 1619 | |
| 1620 | type handshakeMessage interface { |
| 1621 | marshal() ([]byte, error) |
no outgoing calls
no test coverage detected