Hi Eric,
> I just patched a fresh install with your latest LDAP patch (along with patch
> 2057231). LDAP works fine, but now password authentication fails. I noticed
> that your patch replaced:
>
> plugin.sequence.org.dspace.authenticate.AuthenticationMethod = \
> org.dspace.authenticate.PasswordAuthentication, \
> org.dspace.authenticate.LDAPHierarchicalAuthentication, \
> org.dspace.authenticate.X509Authentication
>
> with:
>
> plugin.sequence.org.dspace.authenticate.AuthenticationMethod = \
> org.dspace.authenticate.LDAPHierarchicalAuthentication
Yes - that was just an example for how to use only hierarchical LDAP authN,
but as you found you can still use the stackable system as you wish.
> I changed it back and still got the same error (see Java stacktrace below).
>
> java.lang.NullPointerException
> at
> org.dspace.authenticate.LDAPHierarchicalAuthentication.getSpecialGroups(LDAPHi
> erarchicalAuthentication.java:143)
> at
> org.dspace.authenticate.AuthenticationManager.getSpecialGroups(AuthenticationM
> anager.java:308)
Hmmm, weird. It seems to be suggesting that the context is null. Try
replacing the getSpecialGroups method in HierarchicalLDAPAuthentication.java
with:
public int[] getSpecialGroups(Context context, HttpServletRequest
request)
{
// Prevents anonymous users from being added to this group, and the
second check
// ensures they are LDAP users
if ((context != null) &&
(context.getCurrentUser() != null) &&
(!context.getCurrentUser().getNetid().equals("")))
{
if (ldapGroup == null)
{ // Oops - the group isn't there.
log.warn(LogManager.getHeader(context,
"ldap_specialgroup",
"Group defined in ldap.login.specialgroup does not
exist"));
return new int[0];
} else
{
return new int[] { ldapGroup.getID() };
}
}
return new int[0];
}
Thanks,
Stuart
_________________________________________________________________
Gwasanaethau Gwybodaeth Information Services
Prifysgol Aberystwyth Aberystwyth University
E-bost / E-mail: [EMAIL PROTECTED]
Ffon / Tel: (01970) 622860
_________________________________________________________________
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
DSpace-tech mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/dspace-tech