Download content api

cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Established Member

Download content api

Jump to solution

hi team

i have came across a requirement in my current project, where i have to disable all dowload buttons in share so that a set of users (organized via groups) can not see download link and can not download the content. 
I was able to hide download link and download action for the group using action evaluators. 

I took help from this post and made some additional changes to handle group: https://hub.alfresco.com/t5/alfresco-content-services-forum/how-to-disabling-preview-download-in-alf...

Everything works fine. But during unit test i found i was able to download the content using REST "/api/node/content/{storeType}/{storeId}/{id}" api. 

Is there a way i can restrict the download on this API or i can disable this api and create custom download API to handle the group checks ?

 

1 Solution

Accepted Solutions
Highlighted
Moderator
Moderator

Re: Download content api

Jump to solution

I am not aware if OOTB content download API can be customized to put the restrictions you are looking for. Someone else might provide more thoughts on this. 

 However you can look at this custom webscript, it may be helpful:

https://hub.alfresco.com/t5/alfresco-content-services-blog/downloading-content-from-alfresco-reposit...

This is custom content download webscript which restircts a group of users from downloding the content. 

~Abhinav
(ACSCE, AWS SAA-C02, GAIQ)

View solution in original post

5 Replies
Highlighted
Moderator
Moderator

Re: Download content api

Jump to solution

I am not aware if OOTB content download API can be customized to put the restrictions you are looking for. Someone else might provide more thoughts on this. 

 However you can look at this custom webscript, it may be helpful:

https://hub.alfresco.com/t5/alfresco-content-services-blog/downloading-content-from-alfresco-reposit...

This is custom content download webscript which restircts a group of users from downloding the content. 

~Abhinav
(ACSCE, AWS SAA-C02, GAIQ)

View solution in original post

Highlighted
Established Member

Re: Download content api

Jump to solution

Thanks for help, i was able to create custom download WebScript and able to control the downloads for the set of users.

I want to disable the OOTB download API, can someone help me or guide me if that can be done ?

Highlighted
Customer

Re: Download content api

Jump to solution

Hi:

You can disable / restrict this download uri in your Apache or nginx frontend.

Regards.

--C.

Highlighted
Established Member

Re: Download content api

Jump to solution

Will give it a try. I was hoping to disable at the repository level though

Highlighted
Established Member

Re: Download content api

Jump to solution

Able to stop users from accessing the OOTB download api by blocking them at proxy layer. It is a workaround