diff options
author | Unknwon <u@gogs.io> | 2015-12-01 18:23:12 -0500 |
---|---|---|
committer | Unknwon <u@gogs.io> | 2015-12-01 18:23:12 -0500 |
commit | 53bf23d965a5a0d2582b4f45da2dd997f90360b7 (patch) | |
tree | b542b8a5446bcbdd5287212c390d9eb2816290b6 /modules/auth/auth_form.go | |
parent | 7ccce4d1102508cf1f993bde31bf502eb142a991 (diff) | |
parent | 573305f3d3ac55a79639dcb4cc55694ad7a914a5 (diff) |
Merge pull request #2079 from nanoant/patch/ldap-custom-username-attr
LDAP: Optional user name attribute specification
Diffstat (limited to 'modules/auth/auth_form.go')
-rw-r--r-- | modules/auth/auth_form.go | 45 |
1 files changed, 23 insertions, 22 deletions
diff --git a/modules/auth/auth_form.go b/modules/auth/auth_form.go index 6f356344..1604792a 100644 --- a/modules/auth/auth_form.go +++ b/modules/auth/auth_form.go @@ -10,28 +10,29 @@ import ( ) type AuthenticationForm struct { - ID int64 - Type int `binding:"Range(2,5)"` - Name string `binding:"Required;MaxSize(30)"` - Host string - Port int - BindDN string - BindPassword string - UserBase string - UserDN string `form:"user_dn"` - AttributeName string - AttributeSurname string - AttributeMail string - Filter string - AdminFilter string - IsActive bool - SMTPAuth string - SMTPHost string - SMTPPort int - AllowedDomains string - TLS bool - SkipVerify bool - PAMServiceName string `form:"pam_service_name"` + ID int64 + Type int `binding:"Range(2,5)"` + Name string `binding:"Required;MaxSize(30)"` + Host string + Port int + BindDN string + BindPassword string + UserBase string + UserDN string `form:"user_dn"` + AttributeUsername string + AttributeName string + AttributeSurname string + AttributeMail string + Filter string + AdminFilter string + IsActive bool + SMTPAuth string + SMTPHost string + SMTPPort int + AllowedDomains string + TLS bool + SkipVerify bool + PAMServiceName string `form:"pam_service_name"` } func (f *AuthenticationForm) Validate(ctx *macaron.Context, errs binding.Errors) binding.Errors { |