You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by "Martin Grigorov (JIRA)" <ji...@apache.org> on 2011/07/05 16:57:16 UTC

[jira] [Commented] (WICKET-3841) Redirecting to the home page after binding the session leads to Wicket creating an invalid URL

    [ https://issues.apache.org/jira/browse/WICKET-3841?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13059937#comment-13059937 ] 

Martin Grigorov commented on WICKET-3841:
-----------------------------------------

Tomcat 7 will be improved for 7.0.18. See http://marc.info/?t=130934589600002&r=1&w=2 for the discussion.
Jetty 7 bug report at: https://bugs.eclipse.org/bugs/show_bug.cgi?id=351199

> Redirecting to the home page after binding the session leads to Wicket creating an invalid URL
> ----------------------------------------------------------------------------------------------
>
>                 Key: WICKET-3841
>                 URL: https://issues.apache.org/jira/browse/WICKET-3841
>             Project: Wicket
>          Issue Type: Bug
>          Components: wicket-core
>    Affects Versions: 1.5-RC5.1
>         Environment: Mac Safari 5.0.5
>            Reporter: Matt Brictson
>            Assignee: Peter Ertl
>             Fix For: 1.5-RC6
>
>         Attachments: WICKET-3841-quickstart.tgz
>
>
> This issue is demonstrated in the attached quickstart.
> Consider a stateless page that contains a form. When the user loads this page, a servlet session does not yet exist.
> Now, in the onSubmit() of the form, call Session.get().bind(). This forces a servlet session to be created. The response to the form submission will thus contain a session cookie, and if a redirect is performed the URL will be rewritten to include a jsessionid.
> A problem occurs when a redirect to the home page is performed in this scenario. Wicket responds with a Location header that looks like this:
> Location: http://localhost:8080;jsessionid=cck8jr4b1vdtd5h7a17qv9bn
> If I'm not mistaken this is an invalid URL. There should be a forward-slash between 8080 and ;jsessionid.
> Safari on the Mac reports the following error:
> "Safari can't open the page "http://localhost:8080;jsessionid=cck8jr4b1vdtd5h7a17qv9bn/" because Safari can't connect to the server "localhost".
> If you then press the reload button in Safari, the error changes to:
> "Safari can't open the page "http://localhost:8080;jsessionid=cck8jr4b1vdtd5h7a17qv9bn/" because the page's address isn't valid."
> Other browsers, like Firefox 5.0, seem to automatically correct Wicket's mistake and do not report an error.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira