Core components - Download - adds .coredownload to the filename | Community
Skip to main content
alexshel
Level 3
August 31, 2020
Solved

Core components - Download - adds .coredownload to the filename

  • August 31, 2020
  • 2 replies
  • 3221 views

Why core Download component (https://docs.adobe.com/content/help/en/experience-manager-core-components/using/components/download.html) adds .coredownload to the end of filename (before the extension)?

e.g. link to any /content/dam/.../filename.pdf file is rendered as /content/dam/.../filename.coredownload.pdf

 

Is there a way to remove it ?

Why doesn't it reference an asset by using a direct asset path in DAM (fileReference property) ?

 

 

Best answer by arunpatidar

Core components added coredownload selector to path to trigger https://github.com/adobe/aem-core-wcm-components/blob/master/bundles/core/src/main/java/com/adobe/cq/wcm/core/components/internal/servlets/DownloadServlet.java

which prepare the assets and deliver as an attachment otherwise the assets will be open in new page. Like creating any other link using RTE or other component.

 

If you will remove it from the URL then servlet will not be triggering to prepare assets.

 

2 replies

arunpatidar
Community Advisor
arunpatidarCommunity AdvisorAccepted solution
Community Advisor
August 31, 2020

Core components added coredownload selector to path to trigger https://github.com/adobe/aem-core-wcm-components/blob/master/bundles/core/src/main/java/com/adobe/cq/wcm/core/components/internal/servlets/DownloadServlet.java

which prepare the assets and deliver as an attachment otherwise the assets will be open in new page. Like creating any other link using RTE or other component.

 

If you will remove it from the URL then servlet will not be triggering to prepare assets.

 

Arun Patidar
MeasurableBusinessResults
Level 3
March 26, 2024

IMHO thats a bad design decision.

Having a different URL is bad for all CDNs like Akamai.
Now since the path is different in the URL, the CDN considers it a different asset.
This means the asset is cached twice, which is a waste of resources, it can also be transmitted twice with different URLs, which again is inefficient in terms of caching browser-side.

On top of this, using a CDN typically requires a flush agent for the CDN. Now if an editor updates the original asset in place in DAM (say a PDF), the flush agent for Akamai must take that into account and flush two URLs:
/content/dam/site/myproduct.pdf
and
/content/dam/site/myproduct.pdf.coredownload.pdf

A core component should be smarter AND more flexible and at least make this behaviour configurable.
If someone from the Adobe product team reads this: please improve this as a feature request.

Level 2
February 5, 2025

Hi All,

 

This path is getting flagged as security vulnerability. I tried to disable the Downloadservlet component itself but it is not restricting the URL to be formed with coredownload selector. In fact, it leads to 404 URL of the asset.

 

Do we have any option to disable the coredownload selector getting appended after the document path?

 

Thanks,

Sumit Kulkarni

phychem_ad
Level 2
September 29, 2022

how to configure to remove the coredownload.inline.pdf from the file path