Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type IncomingHandshaker ¶
type IncomingHandshaker struct { Conn net.Conn PeerID [20]byte Extensions [8]byte Cipher mse.CryptoMethod Error error // contains filtered or unexported fields }
IncomingHandshaker does the BitTorrent protocol handshake on an incoming connection.
func New ¶
func New(conn net.Conn) *IncomingHandshaker
New returns a new IncomingHandshaker for a net.Conn.
func (*IncomingHandshaker) Close ¶
func (h *IncomingHandshaker) Close()
Close the IncomingHandshaker. Also closes the underlying connection if there is an ongoing handshake operation.
Click to show internal directories.
Click to hide internal directories.