Implementing Activate User

This commit is contained in:
Chris Mann 2023-07-21 09:23:45 +02:00
parent 6999a109a1
commit 639695d26d

View file

@ -42,7 +42,8 @@ func suggestPassword() string {
func addNewUser(newUser NewUser, config *ConfigFile) bool { func addNewUser(newUser NewUser, config *ConfigFile) bool {
log.Printf(fmt.Sprint("Adding New User")) log.Printf(fmt.Sprint("Adding New User"))
l, _ := ldap.DialURL(config.LdapServerAddr)
l.Bind(config.NewUserDN, config.NewUserPassword)
// l.Bind(config.) // l.Bind(config.)
dn := newUser.DN dn := newUser.DN
req := ldap.NewAddRequest(dn, nil) req := ldap.NewAddRequest(dn, nil)