I want to store in the repository an unchanged file, but change its content on dowloading due to user's role.
To do this I just created my own action that changes content of the file, but found that Alfresco does not provide an appropriate rule to be executed on file downloading.
My action must execute on download using API (link) and using CIFS or WebDAV (copying from folder), so I have to use a rules engine to execute action.
How can I realize this?