Documentation ¶
Index ¶
Constants ¶
View Source
const ID = "/noise"
ID is the protocol ID for noise
View Source
const LengthPrefixLength = 2
LengthPrefixLength is the length of the length prefix itself, which precedes all transport messages in order to delimit them. In bytes.
View Source
const MaxPlaintextLength = MaxTransportMsgLength - poly1305.TagSize
MaxPlaintextLength is the maximum payload size. It is MaxTransportMsgLength minus the MAC size. Payloads over this size will be automatically chunked.
View Source
const MaxTransportMsgLength = 0xffff
MaxTransportMsgLength is the Noise-imposed maximum transport message length, inclusive of the MAC size (16 bytes, Poly1305 for noise-p2p).
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Transport ¶
type Transport struct {
// contains filtered or unexported fields
}
Transport implements the interface sec.SecureTransport https://godoc.org/gitlab.dms3.io/p2p/go-p2p-core/sec#SecureConn
func (*Transport) SecureInbound ¶
SecureInbound runs the Noise handshake as the responder.
Click to show internal directories.
Click to hide internal directories.