[MAGNOLIA-3841] Mime type resolution fails when running in jetty due to ;jsessionid being included in the path Created: 20/Sep/11  Updated: 29/Oct/13  Resolved: 14/Oct/13

Status: Closed
Project: Magnolia
Component/s: core
Affects Version/s: 4.4.5
Fix Version/s: None

Type: Bug Priority: Neutral
Reporter: Tobias Mattsson Assignee: Unassigned
Resolution: Duplicate Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Attachments: File ContentTypeFilter.java.diff    
Issue Links:
causality
caused by MAGNOLIA-3716 VirtualUriFilter does not encode redi... Closed
duplicate
is duplicated by MAGNOLIA-3843 Cannot find MIME type for extension "... Closed
relation
is related to MAGNOLIA-3784 fix broken MostBasicTest#loginOnAutho... Closed
supersession
is superseded by MAGNOLIA-5382 Handling of URIs and paths with path ... Closed
Template:
Acceptance criteria:
Empty
Task DoD:
[ ]* Doc/release notes changes? Comment present?
[ ]* Downstream builds green?
[ ]* Solution information and context easily available?
[ ]* Tests
[ ]* FixVersion filled and not yet released
[ ]  Architecture Decision Record (ADR)
Bug DoR:
[ ]* Steps to reproduce, expected, and actual results filled
[ ]* Affected version filled
Date of First Response:
Sprint: 4.5.13

 Description   

When running integration tests for 4.5 trunk they log this message:

INFO info.magnolia.cms.beans.config.MIMEMapping : Cannot find MIME type for extension "html;jsessionid=4611ywu6o2i9"

The reason for this is that jetty includes the part of the path after ; in request.getRequestURI().

Apparently JBoss AS also does this.



 Comments   
Comment by Jeff Snider [ 10/Feb/12 ]

This only affects Tomcat 6.0.33 and up. The Tomcat team saw the lack of inclusion of ";jsessionid=12345" in the getRequestURI() as a bug so they fixed it and blamed the application for not handling what it barfed in there. That's classy.

https://issues.apache.org/bugzilla/show_bug.cgi?id=51833

Comment by Nickolaus Wing [ 13/Apr/12 ]

Here is a simple patch file (against today's trunk) to resolve the issue. Should work fine for all containers, no matter which behavior they choose.

Comment by Marcel Stör [ 21/Aug/13 ]

they fixed it and blamed the application for not handling what it barfed in there

Did you read the Tomcat bug you refer to? The old behavior clearly violated the Servlet spec and had to be fixed.

As long as ;jsessionid... is in the URL I get a blank page when opening AdminCentral. After each login I need to manually clean the URL in the browser's address bar and hit reload - really annoying. Not sure if it's got anything to do with this bug but I have reason to believe it does.

Generated at Mon Feb 12 03:50:11 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.