@@ -88,8 +88,8 @@ func (h ocisHandler) Bind(bindDN, bindSimplePw string, conn net.Conn) (ldap.LDAP
|
||||
// check password
|
||||
res, err := h.as.ListAccounts(ctx, &accounts.ListAccountsRequest{
|
||||
//Query: fmt.Sprintf("username eq '%s'", username),
|
||||
// TODO this allows lookung up users when you know the username using basic auth
|
||||
// adding the password to the query is an option but sending the sover the wira a la scim seems ugly
|
||||
// TODO this allows looking up users when you know the username using basic auth
|
||||
// adding the password to the query is an option but sending this over the wire a la scim seems ugly
|
||||
// but to set passwords our accounts need it anyway
|
||||
Query: fmt.Sprintf("login eq '%s' and password eq '%s'", userName, bindSimplePw),
|
||||
})
|
||||
|
||||
@@ -73,28 +73,28 @@ func Backend(val *config.Config) Option {
|
||||
}
|
||||
}
|
||||
|
||||
// Fallback provides a strring to set the fallback option.
|
||||
// Fallback provides a string to set the fallback option.
|
||||
func Fallback(val *config.Config) Option {
|
||||
return func(o *Options) {
|
||||
o.Fallback = val
|
||||
}
|
||||
}
|
||||
|
||||
// BaseDN provides a strring to set the BaseDN option.
|
||||
// BaseDN provides a string to set the BaseDN option.
|
||||
func BaseDN(val string) Option {
|
||||
return func(o *Options) {
|
||||
o.BaseDN = val
|
||||
}
|
||||
}
|
||||
|
||||
// NameFormat provides a strring to set the NameFormat option.
|
||||
// NameFormat provides a string to set the NameFormat option.
|
||||
func NameFormat(val string) Option {
|
||||
return func(o *Options) {
|
||||
o.NameFormat = val
|
||||
}
|
||||
}
|
||||
|
||||
// GroupFormat provides a strring to set the GroupFormat option.
|
||||
// GroupFormat provides a string to set the GroupFormat option.
|
||||
func GroupFormat(val string) Option {
|
||||
return func(o *Options) {
|
||||
o.GroupFormat = val
|
||||
|
||||
Reference in New Issue
Block a user