Today I encountered an interesting problem. When I navigate to a particular website and I click on a redirection URL, it works perfectly but copy-pasting the exact same URL will give me a 404 error!
It made me think that there was some JavaScript involved but after more investigation I found this URL: http://bib-alex.net/status.php?name=a-d-aadl-abw-zhrh–khald-a-ar_ptiff.pdf
Having looked at the source I cannot see any scripts. So I am a bit confused! Why does it behave like this and is it intentional?
Those links rely on the existence of the
RefererHTTP header.If you click on one of those links, your browser will send a
Refererheader, set to the page you came from, in the request to the URL you’re going to. If you copy/paste the URL, there is no originating page, so no such header is set.Sites usually do this to prevent leeching, e.g. because they don’t want others to “steal” their bandwidth, or because they don’t want others to download their files without also seeing their ads.