[MGNLDAM-834] Server Error on asset download with content disposition header conaining special characters Created: 12/Mar/20  Updated: 17/Nov/21  Resolved: 08/Nov/21

Status: Closed
Project: Magnolia DAM Module
Component/s: DAM App
Affects Version/s: 2.4.1
Fix Version/s: None

Type: Bug Priority: Major
Reporter: Frank Sommer Assignee: Unassigned
Resolution: Not an issue Votes: 0
Labels: maintenance
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

JBoss EAP 7.2


Issue Links:
relation
is related to DOCU-1985 Update Managing pages to cover all IE... 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:
Epic Link: Support

 Description   

If I have an asset with a file name that contains special characters like ยด the download of this asset fails and a server error is shown.

This issue happens only with JBoss application server. On tomcat server everything is fine.

The solution is to use an url encoded file name instead to use the file name directly from the asset.

res.setHeader(CONTENT_DISPOSITION, "attachment; filename=\"" + asset.getFileName() + "\"");


 Comments   
Comment by Richard Gange [ 16/Mar/20 ]

Deemed an unsafe character by the IETF. https://www.ietf.org/rfc/rfc3986.txt

Comment by Richard Gange [ 08/Nov/21 ]

Seems to be an issue specific to JBoss application server and not a general issue with special characters in nodes names. Therefore the issue will be closed as not an issue. If I can track down some setting in JBoss then I will report the workaround in the description.

Comment by Richard Gange [ 17/Nov/21 ]

Tried with Widlfly 25 and there is no problem. Encodes the URL as expected. I have to conclude there is some issue with JBoss EAP. Still haven't found a proper workaround for it.

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