gssapi

package
v3.4.12 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 1, 2025 License: MIT Imports: 15 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func UnmarshalWrapToken added in v3.4.11

func UnmarshalWrapToken(wt *gssapi.WrapToken, b []byte, expectFromAcceptor bool) error

Types

type Client added in v3.4.7

type Client struct {
	*client.Client

	Subkey types.EncryptionKey
	// contains filtered or unexported fields
}

Client implements ldap.GSSAPIClient interface.

func NewClientFromCCache added in v3.4.7

func NewClientFromCCache(ccachePath, krb5confPath string, settings ...func(*client.Settings)) (*Client, error)

NewClientFromCCache creates a new client from a populated client cache.

func NewClientWithKeytab added in v3.4.7

func NewClientWithKeytab(username, realm, keytabPath, krb5confPath string, settings ...func(*client.Settings)) (*Client, error)

NewClientWithKeytab creates a new client from a keytab credential. Set the realm to empty string to use the default realm from config.

func NewClientWithPassword added in v3.4.7

func NewClientWithPassword(username, realm, password string, krb5confPath string, settings ...func(*client.Settings)) (*Client, error)

NewClientWithPassword creates a new client from a password credential. Set the realm to empty string to use the default realm from config.

func (*Client) Close added in v3.4.7

func (client *Client) Close() error

Close deletes any established secure context and closes the client.

func (*Client) DeleteSecContext added in v3.4.7

func (client *Client) DeleteSecContext() error

DeleteSecContext destroys any established secure context.

func (*Client) InitSecContext added in v3.4.7

func (client *Client) InitSecContext(target string, input []byte) ([]byte, bool, error)

InitSecContext initiates the establishment of a security context for GSS-API between the client and server. See RFC 4752 section 3.1.

func (*Client) InitSecContextWithOptions added in v3.4.11

func (client *Client) InitSecContextWithOptions(target string, input []byte, APOptions []int) ([]byte, bool, error)

InitSecContextWithOptions initiates the establishment of a security context for GSS-API between the client and server. See RFC 4752 section 3.1.

func (*Client) NegotiateSaslAuth added in v3.4.7

func (client *Client) NegotiateSaslAuth(input []byte, authzid string) ([]byte, error)

NegotiateSaslAuth performs the last step of the SASL handshake. See RFC 4752 section 3.1.

type SSPIClient

type SSPIClient struct {
	// contains filtered or unexported fields
}

SSPIClient implements ldap.GSSAPIClient interface. Depends on secur32.dll.

func NewSSPIClient

func NewSSPIClient() (*SSPIClient, error)

NewSSPIClient returns a client with credentials of the current user.

func NewSSPIClientWithChannelBinding added in v3.4.12

func NewSSPIClientWithChannelBinding(cert *x509.Certificate) (*SSPIClient, error)

NewSSPIClientWithChannelBinding creates an RFC 5929 compliant client.

func NewSSPIClientWithCredentials

func NewSSPIClientWithCredentials(creds *sspi.Credentials) *SSPIClient

NewSSPIClientWithCredentials returns a client with the provided credentials.

func NewSSPIClientWithUserCredentials

func NewSSPIClientWithUserCredentials(domain, username, password string) (*SSPIClient, error)

NewSSPIClientWithUserCredentials returns a client using the provided user's credentials.

func (*SSPIClient) Close

func (c *SSPIClient) Close() error

Close deletes any established secure context and closes the client.

func (*SSPIClient) DeleteSecContext

func (c *SSPIClient) DeleteSecContext() error

DeleteSecContext destroys any established secure context.

func (*SSPIClient) InitSecContext

func (c *SSPIClient) InitSecContext(target string, token []byte) ([]byte, bool, error)

InitSecContext initiates the establishment of a security context for GSS-API between the client and server. See RFC 4752 section 3.1.

func (*SSPIClient) InitSecContextWithOptions added in v3.4.11

func (c *SSPIClient) InitSecContextWithOptions(target string, token []byte, APOptions []int) ([]byte, bool, error)

InitSecContextWithOptions initiates the establishment of a security context for GSS-API between the client and server. See RFC 4752 section 3.1.

func (*SSPIClient) NegotiateSaslAuth

func (c *SSPIClient) NegotiateSaslAuth(token []byte, authzid string) ([]byte, error)

NegotiateSaslAuth performs the last step of the SASL handshake. See RFC 4752 section 3.1.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL