Skip to main content
Aug 10, 2020 7:54 AM UTC
Solved

AEM 6.4 SVG as object not showing on edit mode

I am using svg objects in my project but it keep downloading in edit mode.

refer to this 

https://experienceleaguecommunities.adobe.com/t5/adobe-experience-manager/design-importer-issue-with-svg-objects-in-aem-6-3/qaq-p/310314

 

I did know it blocked by DAM Safe Binary Filter(6.5), so I removed it. but it not working.

 

Then I disable the Content Disposition Filter it fixed, but looks like not a recommened soultion due to security purpose. 

 

So I just wondering what would casue if it's disabled? or is there a alternative way?  

 

 

 

 

 

 

 

 

 

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
vanegi
vanegiAccepted solution
Adobe Employee
Aug 10, 2020 8:35 AM UTC

Hello @cn0341,

This is a known security fix at Sling level, and the disposition filter is added to force this behavior. See [0].

To undo this behavior, you can disable the component [1] or allow the mime type.

 

[0]: SLING-4883 Extend content disposition filter protection to jcr:data

[1]: org.apache.sling.security.impl.ContentDispositionFilter

[2]: http://<host:port>/system/console/components/org.apache.sling.security.impl.ContentDispositionFilter

 

 

OR

 

To allow SVGs to be opened in a browser, you can follow below steps:-

 

- Open org.apache.sling.security.impl.ContentDispositionFilter configuration, and allow below mime type in Included Resource Paths & Content Types.

 

/content/*:image/svg+xml

 

- Uncheck "Enable For All Resource Paths”.

 

Thanks!!

3 replies

vanegi
Adobe Employee
vanegiAdobe EmployeeAccepted solution
Adobe Employee
Aug 10, 2020 8:35 AM UTC

Hello @cn0341,

This is a known security fix at Sling level, and the disposition filter is added to force this behavior. See [0].

To undo this behavior, you can disable the component [1] or allow the mime type.

 

[0]: SLING-4883 Extend content disposition filter protection to jcr:data

[1]: org.apache.sling.security.impl.ContentDispositionFilter

[2]: http://<host:port>/system/console/components/org.apache.sling.security.impl.ContentDispositionFilter

 

 

OR

 

To allow SVGs to be opened in a browser, you can follow below steps:-

 

- Open org.apache.sling.security.impl.ContentDispositionFilter configuration, and allow below mime type in Included Resource Paths & Content Types.

 

/content/*:image/svg+xml

 

- Uncheck "Enable For All Resource Paths”.

 

Thanks!!

Translate
cn0341Author
Aug 11, 2020 6:10 AM UTC
Hi @vanegi, thanks your reply. just want make sure I am doing the right way on Content Disposition Filter
Translate
SundeepKatepally
Community Advisor
Community Advisor
Aug 10, 2020 11:29 AM UTC
There is an OSGi Configuration in Felix console named "Apache Sling Content
Disposition Filter" which controls Content Disposition for different mime types based on the path.
 
Translate