userFilter arguments in login.config from login.jsp
Juan Andrés Mucarquer
juan.mucarquer at alumnos.usm.cl
Thu May 2 22:12:41 EDT 2013
On 05/02/2013 10:53 AM, Daniel Fisher wrote:
> On Sun, Apr 28, 2013 at 5:58 PM, Juan Mucarquer
> <juan.mucarquer at alumnos.usm.cl <mailto:juan.mucarquer at alumnos.usm.cl>>
> wrote:
>
> Hello,
>
> I'm using vt-ldap in order to login users. The problem is there are
> duplicate UIDs in the LDAP, but in different OUs.
>
> For example exists:
> uid=john.doe,ou=people,dc=university,dc=edu
> uid=john.doe,ou=students,dc=university,dc=edu
>
> In login.config, the userFilter is set by default:
>
> userFilter=(uid={0})
>
> Where {0} is the uid supplied in the AuthUserPassLoginPage (login.jsp).
>
> As I'm reading in the vt-ldap documentation, its possible to pass
> another argument to the login module (userFilterArgs). Thats my
> question, how I can pass the OU argument ({1}) from the login.jsp,
> in order to login users like userFilter=(uid={0},ou={1})?
>
> Currently, I cannot login users where this happens, due to the
> search returns multiple DNs, and tries to login with the first it finds.
>
>
> You could pass the userId to the LoginHandler containing both the userId
> and the ou argument, perhaps like 'juan at students"
> Then you could write a custom DN resolver to split the userId and inject
> the argument:
> https://github.com/dfish3r/sandbox/blob/master/vt-ldap/CustomDnResolver.java
> Lastly, set the resolver in your login.config like
> so: dnResolver="CustomDnResolver"
> A filter of (&(uid={0})(ou={1})) should then format properly.
>
> --Daniel Fisher
>
>
>
> --
> To unsubscribe from this list send an email to users-unsubscribe at shibboleth.net
>
Thanks, that will help a lot!
More information about the users
mailing list