ldap

package
v0.2.1-0...-e2a08ac Latest Latest
Warning

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

Go to latest
Published: Mar 26, 2026 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BackoffConfig

type BackoffConfig struct {
	MinDelay   time.Duration
	Multiplier int64
}

type LdapClient

type LdapClient interface {
	SendData
	RequestData
	Close() error
	BindRequest(ctx context.Context, bindDN string, bindPass string) error
}

func NewLDAPClient

func NewLDAPClient(ctx context.Context, cfg LdapConfig) (LdapClient, error)

type LdapConfig

type LdapConfig struct {
	Url                   string
	BaseDN                string
	BindDN                string
	BindPass              string
	BackoffConfig         BackoffConfig
	TlsInsecureSkipVerify bool
	ReconnectTimeout      time.Duration
}

type RequestData

type RequestData interface {
	Search(ctx context.Context, request ldap.SearchRequest) ([]*ldap.Entry, error)
	GetDNByObjectGUID(ctx context.Context, objectGUID string) (*string, error)
}

type SendData

type SendData interface {
	AddRequest(ctx context.Context, entries []*ldap.Entry) error
	ModifyRequest(ctx context.Context, entries []*ldap.Entry) error
	DeleteRequest(ctx context.Context, dns []string) error
	DeleteByObjectGUID(ctx context.Context, objectGUID string) error
}

Jump to

Keyboard shortcuts

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