You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by Batara Kesuma <bk...@ml.gaijinweb.com> on 2004/03/18 05:00:14 UTC

[users@httpd] Side effect of blocking images

Hi,
I don't want my images to be linked from other sites. So I added this to
my mod_rewrite settings:

RewriteCond %{HTTP_REFERER} !^http://my-server.com/.*$ [NC]
RewriteRule .*\.jpg$        -          [F]

Does this setting have any side effect? I mean, is there any possibility
the user's browser doesn't pass 'Referer' value? Or firewall rule that
change the Reference on browser maybe? Anyone has comment on this
setting? Please help.

Thank you,
Batara




---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: [users@httpd] Side effect of blocking images

Posted by Joshua Slive <jo...@slive.ca>.
On Fri, 19 Mar 2004, MyStuff wrote:
> >>RewriteCond %{HTTP_REFERER} !^http://my-server.com/.*$ [NC]
> >>RewriteRule .*\.jpg$        -          [F]

> Would it be possible to display an alternate image for those that are
> trying to hot link to images on my site?

Sure.  Just replace the above RewriteRule with something like

RewriteRule /images/my.jpg /images/no-you-dont.jpg

Joshau.

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: [users@httpd] Side effect of blocking images

Posted by MyStuff <st...@colony.net>.
Hello,

> On Thu, 18 Mar 2004, Batara Kesuma wrote:
> 
>>I don't want my images to be linked from other sites. So I added this to
>>my mod_rewrite settings:
>>
>>RewriteCond %{HTTP_REFERER} !^http://my-server.com/.*$ [NC]
>>RewriteRule .*\.jpg$        -          [F]
>>
>>Does this setting have any side effect? I mean, is there any possibility
>>the user's browser doesn't pass 'Referer' value? Or firewall rule that
>>change the Reference on browser maybe? Anyone has comment on this
>>setting? Please help.

Would it be possible to display an alternate image for those that are 
trying to hot link to images on my site?

Thanks

Dale

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Re: [users@httpd] Side effect of blocking images

Posted by Joshua Slive <jo...@slive.ca>.
On Thu, 18 Mar 2004, Batara Kesuma wrote:
> I don't want my images to be linked from other sites. So I added this to
> my mod_rewrite settings:
>
> RewriteCond %{HTTP_REFERER} !^http://my-server.com/.*$ [NC]
> RewriteRule .*\.jpg$        -          [F]
>
> Does this setting have any side effect? I mean, is there any possibility
> the user's browser doesn't pass 'Referer' value? Or firewall rule that
> change the Reference on browser maybe? Anyone has comment on this
> setting? Please help.

Yes, you could be blocking people who choose not to send Referer.  You can
eliminate this problem by also acceping an empty HTTP_REFERER.  There
could also be people who deliberately change the referer, but since I
can't think of a good reason to do that, I wouldn't mind blocking them.

Joshua.

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org