Versions in this module Expand all Collapse all v0 v0.1.1 Jun 26, 2026 v0.1.0 Jun 26, 2026 Changes in this version + const KeySize + const LenPrefixSize + const MaxFrameSize + const NonceSize + const TagSize + var ErrFingerprintMismatch = errors.New("e2e: peer identity does not match pinned fingerprint") + var ErrFrameTooLarge = errors.New("e2e: frame exceeds maximum size") + var ErrHandshake = errors.New("e2e: handshake failed") + var ErrReplay = errors.New("e2e: replayed or out-of-order nonce") + type EncryptedConn struct + func Client(conn net.Conn) (*EncryptedConn, error) + func ClientAuth(conn net.Conn, identity *ecdh.PrivateKey) (*EncryptedConn, []byte, error) + func Server(conn net.Conn) (*EncryptedConn, error) + func ServerAuth(conn net.Conn, identity *ecdh.PrivateKey) (*EncryptedConn, []byte, error) + func (c *EncryptedConn) Close() error + func (c *EncryptedConn) LocalAddr() net.Addr + func (c *EncryptedConn) Read(p []byte) (int, error) + func (c *EncryptedConn) RemoteAddr() net.Addr + func (c *EncryptedConn) SetDeadline(t time.Time) error + func (c *EncryptedConn) SetReadDeadline(t time.Time) error + func (c *EncryptedConn) SetWriteDeadline(t time.Time) error + func (c *EncryptedConn) Write(p []byte) (int, error)