[Catalyst] Catalyst::Plugin::Authentication::Store::LDAP

Adam Jacob adam at stalecoffee.org
Fri Feb 10 21:17:56 CET 2006


On Feb 10, 2006, at 10:53 AM, Christopher Heschong wrote:

> Adam, it works great for me...  Great job!  And the autoload stuff  
> for the
> attributes is MUCH appreciated.  I haven't (yet) tried the roles
> interface, but probably will this week.

Great!

> I found out why you commented out the exception for ldap_bind  
> failures,
> but it would be nice to send that to debug, or maybe somehow track  
> if it
> is the initial bind (in which case complain) or if it just can't re- 
> bind
> because of invalid credentials.

That makes sense... it should go ahead and carp if it fails on the  
initial bind (for the user lookup phase).  If it's doing a bind for  
authentication, it should just fail.  I'll see if I can't get that  
put in there in the next couple of days.

> This may be a C::P::Authentication question in general but is there  
> a way
> to fetch the error msg as a string for a failed operation?  Like  
> "Invalid
> credentials" or whatever the result from Net::LDAP is... basically  
> a hook
> into the underlying Net::LDAP::Message response.

I'm not totally clear on whether there is a way to catch  
Catalyst::Exception's.  It seems like that would be the way to go..

try {
	$c->login($username, $password);
} catch {
...deal with stuff..
}

> Again, this is a great help, thanks so much!

Thanks for the feedback!

Adam



More information about the Catalyst mailing list