Versions in this module Expand all Collapse all v0 v0.0.1 Jun 6, 2019 Changes in this version + func Authenticate(config *Config, username, password string) (bool, error) + func AuthenticateExtended(config *Config, username, password string, attrs, groups []string) (status bool, entry *ldap.Entry, userGroups []string, err error) + func UpdatePassword(config *Config, username, oldPasswd, newPasswd string) error + type Config struct + BaseDN string + Port int + Security SecurityType + Server string + func (c *Config) Connect() (*Conn, error) + func (c *Config) Domain() (string, error) + func (c *Config) UPN(username string) (string, error) + type Conn struct + Config *Config + Conn *ldap.Conn + func (c *Conn) Bind(upn, password string) (bool, error) + func (c *Conn) GetAttributes(attr, value string, attrs []string) (*ldap.Entry, error) + func (c *Conn) GetDN(attr, value string) (string, error) + func (c *Conn) GroupDN(group string) (string, error) + func (c *Conn) ModifyDNPassword(dn, newPasswd string) error + func (c *Conn) ObjectGroups(attr, value string, groups []string) ([]string, error) + func (c *Conn) Search(filter string, attrs []string, sizeLimit int) ([]*ldap.Entry, error) + func (c *Conn) SearchOne(filter string, attrs []string) (*ldap.Entry, error) + type SecurityType int + const SecurityNone + const SecurityStartTLS + const SecurityTLS