[jboss-jira] [JBoss JIRA] (AS7-5040) getRequestURL doesn't return url in address bar but rather actual path
Kelly Dolan (JIRA)
jira-events at lists.jboss.org
Thu Jun 21 09:48:12 EDT 2012
[ https://issues.jboss.org/browse/AS7-5040?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12702702#comment-12702702 ]
Kelly Dolan commented on AS7-5040:
----------------------------------
AS75040.war is a simple application that only has one JSP. This JSP calls request.getRequestURL() and it returns what I would expect. I.e., seems to work.
AS75040w/Login.war is still simple but the JSP in question is now the login page. In this case, the call to request.getRequestURL() is not what I expect. I.e., it is not the value we used to receive and desperately need.
> getRequestURL doesn't return url in address bar but rather actual path
> ----------------------------------------------------------------------
>
> Key: AS7-5040
> URL: https://issues.jboss.org/browse/AS7-5040
> Project: Application Server 7
> Issue Type: Bug
> Affects Versions: 7.1.1.Final
> Reporter: Kelly Dolan
> Attachments: AS75040.war, AS75040wLogin.war
>
>
> Given:
> * an application MyEar.ear configured to use JAAS security that contains MyWar.war configured to redirect protected requests to a FORM login page
> * a login page - MyEar.ear/MyWar.war/WEB-INF/login.jsp
> * 2 conceptual sites - a user and admin site. The user site is accessed as http://server:port/MyEar/user and the admin site is accessed as http://server:port/MyEar/admin. The login page calls request.getRequestURL() to determine which site is being accessed and generates the content of the login page differently based on which site is being accessed among other things.
>
> In JBoss 4, request.getRequestURL() returns
> * returns http://server:port/MyEar/user when http://server:port/MyEar/user is entered
> * returns http://server:port/MyEar/admin when http://server:port/MyEar/admin is entered
> * if params are entered on the URL, they are not part of the string returned by getRequestURL() but that's okay for me
>
> In JBoss 7, request.getRequestURL() returns http://server:port/MyEar/WEB-INF/login.jsp.
>
> Ultimately, this seems to imply the URL in the address bar is not available to JSPs. This impacts all related get URL/path methods and for us, is a HUGE problem.
> JBAS-6570 was open for AS6 but closed (understandably).
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.jboss.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the jboss-jira
mailing list