Prevent direct access to files but allow download from site
nginx-forum at forum.nginx.org
Wed Mar 11 22:36:10 UTC 2020
I would like to block direct access to files in a folder on my site, but
allow downloading from the site.
Specifically, I want to be able to download a file from the site's html
<a href="/assets/file/test.txt" download=""> Download TXT </a>
But do not allow direct access and download, using the browser or other
tools such as curl or wget.
So block access to the link:
is it possible to obtain such a result?
Posted at Nginx Forum: https://forum.nginx.org/read.php?2,287297,287297#msg-287297
More information about the nginx