Hotlinking is the use of a linked object, often an image, from one site by a web page belonging to a second site.
Questions tagged [hotlinking]
245 questions
3
votes
2 answers
htaccess - Prevent Hotlinking/Webpage Scraping & Redirect Attacker's Webpage to Warning Page
Malicious website owners are using the contents of our website to say example.com on their websites say spam.com like:

Maroof Mandal
- 521
- 9
- 29
3
votes
4 answers
Laravel download response with hotlink protection and low memory usage
I have a file download website and I serve the files through Laravel for hotlink protection, but it seems like downloads keep my php processes alive for a very long time (as some users have bad download speed).
For hotlink protection I create a…

Alex
- 4,674
- 5
- 38
- 59
3
votes
6 answers
How can I make an entire div a link, but also have other links inside?
I have a div. I want it to link somewhere when you click on it, but I also want to put other links inside it, so when you click on the other links you're redirected to one place, but if you click anywhere else you're redirected somewhere…

Joe Morano
- 1,715
- 10
- 50
- 114
3
votes
2 answers
More Eyeballs on my Poor mod_rewrite Attempt Please
We're changing the way users embed images in their blogs, but I need to make sure previously embedded images are still displayed.
I'm trying to redirect legacy image embed links to either a static image or a single legacy image embed handling file.…

Michael Robinson
- 29,278
- 12
- 104
- 130
3
votes
0 answers
Hotlinking photos from Facebook - an "ok" practice?
For my current website project, I wanted to off-load some bandwidth as well as data management to facebook - by this I mean:
Use a public Facebook page as 3rd party host for images to use for our website (screenshots, info-graphics, etc) , thereby…

BrownChiLD
- 3,545
- 9
- 43
- 61
3
votes
2 answers
Can I hide an image path on asp.net page without http Handler?
I have many static images under a directory in my site structure, and I'm not concerned with hotlinking or copy-protecting the images. For a myriad of reasons, what I need to do is not show the image path on the site (or show a fake one).
Is there…

jehuty
- 528
- 1
- 6
- 20
3
votes
1 answer
Remove special characters
I'm protecting links with the following function
function encode_html5($str){
return '#'.preg_replace("/0{1}([0-9a-f]{3})/i", "$1", implode("", unpack("H*", iconv("UTF-8", "UTF-16BE", $str))));
}
The problem is some special characters…

rabotalius
- 1,430
- 5
- 18
- 27
3
votes
2 answers
How to prevent downloads by directly accessing file via URL?
I am making an online streaming website where users can listen to audio or video files. Currently I am calling an mp3 file in an audio tag using below code.
Play
In my website a user can stream a…

SunnyD
- 71
- 2
- 10
3
votes
2 answers
anti image hotlinking (custom regex)
I'd like to set up a regular expression that would disallow hotlinking of images that DO NOT end with the following pattern: -200.jpg
The "200" can actually be "150" or "250" or any number between 100-999 (that is to say 3 chars). The .jpg can be…
user1883314
3
votes
1 answer
Prevent direct access to images using the browser url
I have a folder named - Images. This folder contains user profile pictures. Right now a user can see his image by just copying the image URL to his browser any time. This way he can also see other user's profile pics. What I want to achieve is - The…

Anoop Nair
- 171
- 1
- 2
- 13
3
votes
2 answers
Wget: How to bypass "hotlinking" protected image
Is it possible to bypass "hotlink" image protection? i'm not trying to post it on other sites just to download.
when i download the following image, using…

Crazy_Bash
- 1,755
- 10
- 26
- 38
3
votes
1 answer
Nginx - how to implement hotlinking prevention?
Seeking help from Nginx experts here.
I want to block people accessing CSS or JS directly from my website. A bit like this: http://assets.behance.net/
I got this reference from ServerFault:
https://serverfault.com/a/332493/117595
location ~*…

PKHunter
- 682
- 2
- 13
- 28
2
votes
1 answer
How to prevent hotlinking dynamically ( without hard coding host domain ) using .htaccess HTTP_HOST and HTTP_REFERER
I want to know how to prevent hotlinking to resources on my site without hard coding the domain name.
I need this since the software will be used for multiple domains, and may be used as an installation. It would not be feasible to instruct every…

TheWebGuy
- 31
- 3
2
votes
1 answer
nginx redirect if other referer than my site
I have nginx webserver and people are starting to hotlink to download.php and that gives me nothing.
I wish to add 4 white list sites from which it is possible to hotlink (domains of my site) and make others that hotlink to my site get redirected…

Treat
- 182
- 1
- 6
- 15
2
votes
2 answers
How to allow Google Doc to display hotlinked files?
I have restricted hotlinking my files in using htaccess. But I need those files to be displayed in Google Doc Viewer.
In htaccess I allow Google Docs to hotlink my files, but it is not working. Please help me in this
Below is the code I used in my…

Afsal Meerankutty
- 366
- 4
- 15