| From | Sent On | Attachments |
|---|---|---|
| Florian Kirchhoff | Oct 19, 2007 11:10 am | |
| Nathan Anderson | Oct 19, 2007 12:29 pm | |
| Florian Kirchhoff | Oct 22, 2007 7:20 am | |
| Nathan Anderson | Oct 22, 2007 11:43 am | |
| Jason Thrasher | Dec 22, 2008 5:16 pm |
| Subject: | Re: [appfuse-user] Zero size response when using LDAP based authentication | |
|---|---|---|
| From: | Florian Kirchhoff (Flor...@qwest.com) | |
| Date: | Oct 22, 2007 7:20:54 am | |
| List: | net.java.dev.appfuse.users | |
Nathan,
I am using Spring MVC, but the problem appears to be somwhat similar. The blank screen was caused by some exception, I have no idea why I could not find any signes of the exception until I turned off the GZIP filter. Once I did that I could see the error page and find the problem. My issue was that for an application generated using appfuse:gen. The generated web app has a footer.jsp which uses the following tag:
<authz:authentication operation="fullName"/>
which if the principal implements UserDetails, will call the "getFullName" on it. Problem is when we use LDAP authentication, the UserDetails are in org.acegisecurity.userdetails.ldap.LdapUserDetailsImpl, which doesn't have a getFullName method, which thru a JspException which for some unknown reason resulted in a zero size response... So I changed the footer.jsp to reference the "Username" operation which is part of the UserDetails interface and should therefore work no matter what the implementation is...
Florian
melinate wrote:
Which web layer are you using in your app? I had a zero size response in a Struts 2 app which I found to be caused by trying to read from a non-existent session variable [which was caused by a typo ;)].
Nathan
----- Original Message ----- From: "Florian Kirchhoff" <Flor...@qwest.com> To: use...@appfuse.dev.java.net Sent: Friday, October 19, 2007 11:10:56 AM (GMT-0800) America/Los_Angeles Subject: [appfuse-user] Zero size response when using LDAP based authentication
Hi,
I have successfully used AppFuse 2.0 to create a CRUD type app for several entities. I am trying to switch from DB based to LDAP based authentication. I have followed the steps in http://appfuse.org/display/APF/LDAP+Authentication (which are great). I checked my LDAP setup with some unit tests and confirmed that I can bind to LDAP to authenticate successfully. I can see that all the roles are found from the Groups in LDAP. When I switch to my web app, the same applies (bind is ok, roles are OK) but in after the redirect to mainI get a zero size response from the server, resulting in a blank page. I get the same whether I run in IE or Firefox or if I use jetty:run-war or Tomcat 5.5 which makes me think this is a Acegi related issue...
Now here is the weird think, before I log on I can browse the non protected JSPs, like login.jsp, 404.jsp and 403.jsp. Once I succesfully log in I get a zero size response/blank page for all pages I try to access, even these unprotected pages...
When I compare the log files for the DB vs. LDAP setup, I see no difference that would give me a clue as to the problem.
Is there some additional change I should make when changing from DB to LDAP based AAA?
Any help with this would be greatly appreciated.
Thanks,
Florian
--
View this message in context:
http://www.nabble.com/Zero-size-response-when-using-LDAP-based-authentication-tf4654949s2369.html#a13300084
Sent from the AppFuse - User mailing list archive at Nabble.com.
--
View this message in context:
http://www.nabble.com/Zero-size-response-when-using-LDAP-based-authentication-tf4654949s2369.html#a13342290
Sent from the AppFuse - User mailing list archive at Nabble.com.





