DefaultStreamHandler is an implementation of streamHandlerFunc that performs a two way io.Copy between originConn and remoteConn.
(originConn io.ReadWriter, remoteConn net.Conn, log *zerolog.Logger)
| 27 | // DefaultStreamHandler is an implementation of streamHandlerFunc that |
| 28 | // performs a two way io.Copy between originConn and remoteConn. |
| 29 | func DefaultStreamHandler(originConn io.ReadWriter, remoteConn net.Conn, log *zerolog.Logger) { |
| 30 | stream.Pipe(originConn, remoteConn, log) |
| 31 | } |
| 32 | |
| 33 | // tcpConnection is an OriginConnection that directly streams to raw TCP. |
| 34 | type tcpConnection struct { |