Versions in this module Expand all Collapse all v0 v0.0.1 Jan 3, 2026 Changes in this version + const DefaultNSSSocketPath + const ProtocolVersion + const SSS_GET_VERSION + const SSS_NSS_ENDGRENT + const SSS_NSS_ENDNETGRENT + const SSS_NSS_ENDPWENT + const SSS_NSS_ENDSERVENT + const SSS_NSS_GETGRENT + const SSS_NSS_GETGRGID + const SSS_NSS_GETGRNAM + const SSS_NSS_GETNETGRENT + const SSS_NSS_GETPWENT + const SSS_NSS_GETPWNAM + const SSS_NSS_GETPWUID + const SSS_NSS_GETSERVBYNAME + const SSS_NSS_GETSERVBYPORT + const SSS_NSS_GETSERVENT + const SSS_NSS_INITGR + const SSS_NSS_SETGRENT + const SSS_NSS_SETNETGRENT + const SSS_NSS_SETPWENT + const SSS_NSS_SETSERVENT + const SSS_NSS_STATUS_NOTFOUND + const SSS_NSS_STATUS_PROTOCOL_ERROR + const SSS_NSS_STATUS_SUCCESS + const SSS_NSS_STATUS_TRYAGAIN + const SSS_NSS_STATUS_UNAVAIL + func MarshalRequest(command uint32, data []byte) ([]byte, error) + func MarshalString(s string) []byte + func UnmarshalString(data []byte, offset int) (string, int, error) + type Client struct + func NewClient(opts ...ClientOption) *Client + func (c *Client) Close() error + func (c *Client) Connect() error + func (c *Client) ConnectContext(ctx context.Context) error + func (c *Client) GetGroupByGID(gid uint32) (*Group, error) + func (c *Client) GetGroupByName(groupname string) (*Group, error) + func (c *Client) GetGroupsForUser(username string) ([]uint32, error) + func (c *Client) GetUserByName(username string) (*User, error) + func (c *Client) GetUserByUID(uid uint32) (*User, error) + type ClientOption func(*Client) + func WithContext(ctx context.Context) ClientOption + func WithSocketPath(path string) ClientOption + func WithTimeout(timeout time.Duration) ClientOption + type Group struct + GID uint32 + Members []string + Name string + Passwd string + func UnmarshalGroup(data []byte) (*Group, error) + type MessageHeader struct + Command uint32 + Length uint32 + Reserved uint32 + Status uint32 + type Request struct + Data []byte + Header MessageHeader + type Response struct + Data []byte + Header MessageHeader + func UnmarshalResponse(data []byte) (*Response, error) + type User struct + GID uint32 + Gecos string + HomeDir string + Name string + Passwd string + Shell string + UID uint32 + func UnmarshalUser(data []byte) (*User, error)