-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Paulo
Almeida
Sent: Tuesday, August 19, 2008 12:31 PM
To: BASE ML
Subject: Re: [base] LDAP authentication (or possible alternatives)

Hi,

I still haven't managed to get LDAP authentication running, but I did
find an alternative that seems to work for me, at least as far as I can
tell (I still need to test it more). The solution, of course, was to
install a POP3 server that authenticates to our LDAP server. 

I'd still like to get LDAP working, because this is far from elegant,
but at least I have something I can use. I'll probably learn some more
Java first and then I'll go back to my LDAP plugin.

- Paulo

On Thursday 14 August 2008 21:09, Nicklas Nordborg wrote:
> Paulo Almeida wrote:
> > I tried testing the POP3Authenticator and I also can't get it to 
> > work. It gives me this error when I try to login:
> >
> > The authentication
> > driver 'net.sf.basedb.core.authentication.POP3Authenticator' could 
> > not be loaded. The error message is: null
> >
> > I compiled the POP3Authenticator, put the .jar file in 
> > <basedir>/www/WEB-INF/lib and uncommented the auth.driver line in 
> > the default base.config file.
>
> Hmmm... The POP3Authenticator is part of BASE, so if you have compiled

> it a second time you now have two classes with the same name, and that

> is usually not a good idea.
>
> Also, have you set the initialization string auth.init to a valid pop3

> mail server?
>
> Can you submit the complete stacktrace?
>
> > I think this is the only problem now. I've been able to compile my 
> > LDAPAuthenticator with a different package name (I'm using just 
> > 'authentication' now), but I'm missing something when I try to tell 
> > Base to use an authentication module.
> >
> > Can you figure out what may be wrong? I'm attaching my latest 
> > LDAPAuthenticator.java
>
> I am not familiar with LDAP so I can't comment on anything is related 
> to that. Here are some points:
>
> * It is considered bad practice to import anything with a * at the
end.
> Only import the classes that you are actually using. The reason for 
> this is that it becomes harder to know from which package a certain 
> class is coming. It may also create name clashes when you update a 
> package to a newer version and there are new classes with the same 
> names as are found in other packages.
>
> * Why do you have a 'void main()' method?
>
> * If you are getting a NamingException this code only prints the error

> message and the returns indicating a successful login.
>
>          } catch (NamingException e) {
>              e.printStackTrace();
>          }
>       return new AuthenticationInformation(login, login);
>
> If the user/password is not correct you must throw either an 
> UnknownLoginException or an InvalidPasswordException. For other 
> problems you must throw an AuthenticationException.
>
> /Nicklas
>
> ----------------------------------------------------------------------
> --- 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=/
> _______________________________________________
> The BASE general discussion mailing list 
> basedb-users@lists.sourceforge.net
> unsubscribe: send a mail with subject "unsubscribe" to 
> [EMAIL PROTECTED]

------------------------------------------------------------------------
-
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=/
_______________________________________________
The BASE general discussion mailing list
basedb-users@lists.sourceforge.net
unsubscribe: send a mail with subject "unsubscribe" to
[EMAIL PROTECTED]

-------------------------------------------------------------------------
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=/
_______________________________________________
The BASE general discussion mailing list
basedb-users@lists.sourceforge.net
unsubscribe: send a mail with subject "unsubscribe" to
[EMAIL PROTECTED]

Reply via email to