my dog learned polymorphism*
The moose likes Servlets and the fly likes Form Based Authentication with 2 webapps Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "Form Based Authentication with 2 webapps" Watch "Form Based Authentication with 2 webapps" New topic
Author

Form Based Authentication with 2 webapps

Drew Lane
Ranch Hand

Joined: May 13, 2001
Posts: 296
I previously built a webapp using form based authentication (j_security_check, etc.) and protected directories for regular HTML browsers.

Now I want to build a second webapp for WAP browsers using the protected content from the first webapp.

I setup a subdomain for this second webapp (ie. wap.mydomain.com) and it's pointing to a directory called "wap" inside the first webapp.

I am able to login with the second app but I'm having a problem with the error page; it always takes me to the error page of the first webapp.

I know this error page is defined in web.xml, but I don't think it's possible to define two different error pages.

I guess I could make up a generic error page for both logins but that's not ideal...

Maybe it's possible to define two webapps that share resources in web.xml?

Am I going about this all wrong?

Thanks,

Drew
Ganesh Gowtham
Ranch Hand

Joined: Mar 30, 2005
Posts: 225

Originally posted by Drew Lane:
I previously built a webapp using form based authentication (j_security_check, etc.) and protected directories for regular HTML browsers.

Now I want to build a second webapp for WAP browsers using the protected content from the first webapp.

I setup a subdomain for this second webapp (ie. wap.mydomain.com) and it's pointing to a directory called "wap" inside the first webapp.

I am able to login with the second app but I'm having a problem with the error page; it always takes me to the error page of the first webapp.

I know this error page is defined in web.xml, but I don't think it's possible to define two different error pages.

I guess I could make up a generic error page for both logins but that's not ideal...

Maybe it's possible to define two webapps that share resources in web.xml?

Am I going about this all wrong?

Thanks,

Drew



Hi Drew ,
Y wont u try the jsp <%@page %> attribute "ErrorPage" to point ur inner wap domain. Try ..

by the by how to configure inner like wap.myWebApp.com , Let me know the steps , eben i am trying but in vain.So let me know the steps from scratch..

regards
gowtham g r
grgowtham_cse@yahoo.com


Thanks, Ganesh Gowtham
http://ganesh.gowtham.googlepages.com
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 60766
    
  65

Gowtham, JavaRanch is a community of people from all over the world, many of who are not native English speakers. While using abbreviations like "u" instead of spelling out "you" is convenient when text messaging your friends on a cell phone or in a chat room, it presents an extra challenge to those that are already struggling with English. Additionally, such shortcuts may confound automated translation tools that patrons of the Ranch may be making use of.

I would like to ask for your help in making the content of JavaRanch a little easier to read for everybody that visits here by not using such abbreviations.

Please read this for more information.

thanks,
bear
Forum Bartender


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
 
jQuery in Action, 2nd edition
 
subject: Form Based Authentication with 2 webapps
 
Similar Threads
Get Error messages/Exceptions from Active Directory Server(ADS) with Weblogic 9.2
2 times login required?
Redirect to the requested page failed using form-based authentication
can I have two login page using form-based authentication?
A Realm for more than one Webapp