Apache2 + .Htaccess + Limit to IP

Status
Not open for further replies.

EvilGenius

Active Member
754
2009
4
0
Hi,

I have a file that I would like only to be allowed to access,

If the referrer is a specific IP(s), Not a Domain name.
and No Blank Refs

Yes yes I know there are other ways, but I'm looking for this specifically.

Can someone help me out, what the htaccess code would be...?


Thanks in Advanced.
EG
 
2 comments
<Limit GET POST PUT>
order deny,allow
deny from all
allow from 1.2.3.4
</Limit>

Just insert your IP address, or the IP addresses you wish to allow access to your site. Each IP address is placed on a new line. For example:

<Limit GET POST PUT>
order deny,allow
deny from all
allow from 1.2.3.4
allow from 5.6.7.8
</Limit>
 
You mis understood.

Is it possible for the rewrite to resolve an IP (for the referring site) and compare it against an IP I provide myself, then allow access to file.
 
Status
Not open for further replies.
Back
Top