summaryrefslogtreecommitdiffstats
path: root/routers
diff options
context:
space:
mode:
authorSergio Benitez <sbenitez@mit.edu>2015-08-12 16:58:27 -0700
committerSergio Benitez <sbenitez@mit.edu>2015-08-12 17:01:22 -0700
commit7d84d4a8f0cb30df04241f528ed74672a485274a (patch)
treee42a4d0163ac9573a75ea47e6659a8761e78d936 /routers
parent631c85ba4f51d3fe910324595c154dfaf25935d2 (diff)
downloadgitea-7d84d4a8f0cb30df04241f528ed74672a485274a.tar.gz
gitea-7d84d4a8f0cb30df04241f528ed74672a485274a.zip
Significantly enhanced LDAP support in Gogs.
Diffstat (limited to 'routers')
-rw-r--r--routers/admin/auths.go18
1 files changed, 9 insertions, 9 deletions
diff --git a/routers/admin/auths.go b/routers/admin/auths.go
index 2bec7da46c..bb73026b7d 100644
--- a/routers/admin/auths.go
+++ b/routers/admin/auths.go
@@ -63,18 +63,18 @@ func NewAuthSourcePost(ctx *middleware.Context, form auth.AuthenticationForm) {
case models.LDAP:
u = &models.LDAPConfig{
Ldapsource: ldap.Ldapsource{
+ Name: form.Name,
Host: form.Host,
Port: form.Port,
UseSSL: form.UseSSL,
- BaseDN: form.BaseDN,
- AttributeUsername: form.AttributeUsername,
+ BindDN: form.BindDN,
+ BindPassword: form.BindPassword,
+ UserBase: form.UserBase,
+ Filter: form.Filter,
AttributeName: form.AttributeName,
AttributeSurname: form.AttributeSurname,
AttributeMail: form.AttributeMail,
- Filter: form.Filter,
- MsAdSAFormat: form.MsAdSA,
Enabled: true,
- Name: form.Name,
},
}
case models.SMTP:
@@ -149,18 +149,18 @@ func EditAuthSourcePost(ctx *middleware.Context, form auth.AuthenticationForm) {
case models.LDAP:
config = &models.LDAPConfig{
Ldapsource: ldap.Ldapsource{
+ Name: form.Name,
Host: form.Host,
Port: form.Port,
UseSSL: form.UseSSL,
- BaseDN: form.BaseDN,
- AttributeUsername: form.AttributeUsername,
+ BindDN: form.BindDN,
+ BindPassword: form.BindPassword,
+ UserBase: form.UserBase,
AttributeName: form.AttributeName,
AttributeSurname: form.AttributeSurname,
AttributeMail: form.AttributeMail,
Filter: form.Filter,
- MsAdSAFormat: form.MsAdSA,
Enabled: true,
- Name: form.Name,
},
}
case models.SMTP: