Versions in this module Expand all Collapse all v1 v1.0.1 Apr 30, 2024 Changes in this version + func NewPair(ctx context.Context, stype linux.SockType, uid uniqueid.Provider) (Endpoint, Endpoint) + type Address struct + Addr string + type BoundEndpoint interface + BidirectionalConnect func(ctx context.Context, ep ConnectingEndpoint, ...) *syserr.Error + Passcred func() bool + Release func(ctx context.Context) + UnidirectionalConnect func(ctx context.Context) (ConnectedEndpoint, *syserr.Error) + type BoundSocketFD interface + Accept func(ctx context.Context) (int, error) + Close func(ctx context.Context) + Listen func(ctx context.Context, backlog int32) error + NotificationFD func() int32 + type ConnectedEndpoint interface + CloseNotify func() + CloseSend func() + CloseUnread func() + EventUpdate func() error + GetLocalAddress func() (Address, tcpip.Error) + IsSendClosed func() bool + Passcred func() bool + Release func(ctx context.Context) + Send func(ctx context.Context, data [][]byte, c ControlMessages, from Address) (n int64, notify bool, err *syserr.Error) + SendMaxQueueSize func() int64 + SendNotify func() + SendQueuedSize func() int64 + SetSendBufferSize func(v int64) (newSz int64) + Writable func() bool + type ConnectingEndpoint interface + Connected func() bool + GetLocalAddress func() (Address, tcpip.Error) + ID func() uint64 + ListeningLocked func() bool + Passcred func() bool + Type func() linux.SockType + WaiterQueue func() *waiter.Queue + type ControlMessages struct + Credentials CredentialsControlMessage + Rights RightsControlMessage + func (c *ControlMessages) Clone() ControlMessages + func (c *ControlMessages) Empty() bool + func (c *ControlMessages) Release(ctx context.Context) + type Credentialer interface + ConnectedPasscred func() bool + Passcred func() bool + type CredentialsControlMessage interface + Equals func(CredentialsControlMessage) bool + type Endpoint interface + Accept func(ctx context.Context, peerAddr *Address) (Endpoint, *syserr.Error) + Bind func(address Address) *syserr.Error + Close func(ctx context.Context) + Connect func(ctx context.Context, server BoundEndpoint) *syserr.Error + GetLocalAddress func() (Address, tcpip.Error) + GetRemoteAddress func() (Address, tcpip.Error) + GetSockOpt func(opt tcpip.GettableSocketOption) tcpip.Error + GetSockOptInt func(opt tcpip.SockOptInt) (int, tcpip.Error) + LastError func() tcpip.Error + Listen func(ctx context.Context, backlog int) *syserr.Error + RecvMsg func(ctx context.Context, data [][]byte, args RecvArgs) (RecvOutput, func(), *syserr.Error) + SendMsg func(context.Context, [][]byte, ControlMessages, BoundEndpoint) (int64, func(), *syserr.Error) + SetSockOpt func(opt tcpip.SettableSocketOption) tcpip.Error + SetSockOptInt func(opt tcpip.SockOptInt, v int) tcpip.Error + Shutdown func(flags tcpip.ShutdownFlags) *syserr.Error + SocketOptions func() *tcpip.SocketOptions + State func() uint32 + Type func() linux.SockType + func NewConnectioned(ctx context.Context, stype linux.SockType, uid uniqueid.Provider) Endpoint + func NewConnectionless(ctx context.Context) Endpoint + func NewExternal(stype linux.SockType, uid uniqueid.Provider, queue *waiter.Queue, ...) Endpoint + type HostBoundEndpoint interface + ResetBoundSocketFD func(ctx context.Context) + SetBoundSocketFD func(ctx context.Context, bsFD BoundSocketFD) error + type HostConnectedEndpoint struct + func NewHostConnectedEndpoint(hostFD int, addr string) (*HostConnectedEndpoint, *syserr.Error) + func (c *HostConnectedEndpoint) CloseNotify() + func (c *HostConnectedEndpoint) CloseRecv() + func (c *HostConnectedEndpoint) CloseSend() + func (c *HostConnectedEndpoint) CloseUnread() + func (c *HostConnectedEndpoint) EventUpdate() error + func (c *HostConnectedEndpoint) GetLocalAddress() (Address, tcpip.Error) + func (c *HostConnectedEndpoint) IsRecvClosed() bool + func (c *HostConnectedEndpoint) IsSendClosed() bool + func (c *HostConnectedEndpoint) Passcred() bool + func (c *HostConnectedEndpoint) Readable() bool + func (c *HostConnectedEndpoint) Recv(ctx context.Context, data [][]byte, args RecvArgs) (RecvOutput, bool, *syserr.Error) + func (c *HostConnectedEndpoint) RecvMaxQueueSize() int64 + func (c *HostConnectedEndpoint) RecvNotify() + func (c *HostConnectedEndpoint) RecvQueuedSize() int64 + func (c *HostConnectedEndpoint) Release(ctx context.Context) + func (c *HostConnectedEndpoint) Send(ctx context.Context, data [][]byte, controlMessages ControlMessages, ...) (int64, bool, *syserr.Error) + func (c *HostConnectedEndpoint) SendMaxQueueSize() int64 + func (c *HostConnectedEndpoint) SendNotify() + func (c *HostConnectedEndpoint) SendQueuedSize() int64 + func (c *HostConnectedEndpoint) SetReceiveBufferSize(v int64) (newSz int64) + func (c *HostConnectedEndpoint) SetSendBufferSize(v int64) (newSz int64) + func (c *HostConnectedEndpoint) SockType() linux.SockType + func (c *HostConnectedEndpoint) Writable() bool + type Receiver interface + CloseNotify func() + CloseRecv func() + IsRecvClosed func() bool + Readable func() bool + Recv func(ctx context.Context, data [][]byte, args RecvArgs) (out RecvOutput, notify bool, err *syserr.Error) + RecvMaxQueueSize func() int64 + RecvNotify func() + RecvQueuedSize func() int64 + Release func(ctx context.Context) + type RecvArgs struct + Creds bool + NumRights int + Peek bool + type RecvOutput struct + Control ControlMessages + ControlTrunc bool + MsgLen int64 + RecvLen int64 + Source Address + UnusedRights []RightsControlMessage + type RightsControlMessage interface + Clone func() RightsControlMessage + Release func(ctx context.Context) + type SCMConnectedEndpoint struct + func NewSCMEndpoint(hostFD int, queue *waiter.Queue, addr string) (*SCMConnectedEndpoint, *syserr.Error) + func (e *SCMConnectedEndpoint) Init() error + func (e *SCMConnectedEndpoint) Release(ctx context.Context) + type SCMRights struct + FDs []int + func (c *SCMRights) Clone() RightsControlMessage + func (c *SCMRights) Release(ctx context.Context)