[MAGNOLIA-7017] handleResourceRequest sends just the bytes but doesn't set the Content-type header. Created: 24/Apr/17  Updated: 16/Jun/21  Resolved: 16/Jun/21

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

Type: Bug Priority: Neutral
Reporter: Ervin Vystup Assignee: Unassigned
Resolution: Won't Fix Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
relation
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:

 Description   

handleResourceRequest method sends just the bytes but doesn't set the Content-type header.
To reproduce, upload an image directly into the website. Requesting such image outputs this warning:

"2017-03-23 22:06:04,632 WARN info.magnolia.cms.filters.ContentTypeFilter : Content type for http://localhost/mypage/content/01/image/200220461-001.jpg is not set."


 Comments   
Comment by Jan Haderka [ 16/Jun/21 ]

Uploading binary content directly into pages or other types of content is discouraged since Magnolia 6. Store binaries in DAM and link them from the content type to avoid the problem.

Generated at Mon Feb 12 04:19:57 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.