Server returns a new TLS server side connection using conn as the underlying transport. The configuration config must be non-nil and must include at least one certificate or else set GetCertificate.
(conn net.Conn, config *Config)
| 32 | // The configuration config must be non-nil and must include |
| 33 | // at least one certificate or else set GetCertificate. |
| 34 | func Server(conn net.Conn, config *Config) *Conn { |
| 35 | c := &Conn{ |
| 36 | conn: conn, |
| 37 | config: config, |
| 38 | } |
| 39 | c.handshakeFn = c.serverHandshake |
| 40 | return c |
| 41 | } |
| 42 | |
| 43 | // Client returns a new TLS client side connection |
| 44 | // using conn as the underlying transport. |
no outgoing calls
no test coverage detected
searching dependent graphs…