Home All Groups Group Topic Archive Search About

Tie a file an IP address

Author
31 Jul 2006 9:17 AM
creamy
Please i would like to know if it is possible to restict a file to an
IP address. i.e: It would only open on a system based on its IP
address. Thanks.

Author
31 Jul 2006 10:41 AM
Evertjan.
creamy wrote on 31 jul 2006 in microsoft.public.inetserver.asp.general:

> Please i would like to know if it is possible to restict a file to an
> IP address. i.e: It would only open on a system based on its IP
> address. Thanks.

If you mean based on the remote client's IP address,
[insofar as no proxi is used by the cliest]
and by "open" "showing it's rendered content":

<% 'vbscript
q = request.servervariables("remote_addr")
If q <> "123.456.789.123" then server.transfer "\404.asp"
%>
<html>
<body>
My terrible secrets
.....


--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
Are all your drivers up to date? click for free checkup

Author
31 Jul 2006 12:32 PM
Anthony Jones
"creamy" <blackdevil_he***@yahoo.com> wrote in message
news:1154337475.811605.58270@m79g2000cwm.googlegroups.com...
> Please i would like to know if it is possible to restict a file to an
> IP address. i.e: It would only open on a system based on its IP
> address. Thanks.
>

In IIS Manager find the ASP file or folder that you want to restrict access
to.
Open properties and selecte security tab
In IP address and domain name restrictions click edit...
Ensure Grant Access is selected then click Add..
Add the IP address or range of address you want to give access.

Anthony.
Author
1 Aug 2006 10:59 AM
creamy
Thanks,
But the server.transfer... doesn't seem to work. What now. Thanx.
Author
1 Aug 2006 3:09 PM
Anthony Jones
"creamy" <blackdevil_he***@yahoo.com> wrote in message
news:1154429965.803563.234710@m79g2000cwm.googlegroups.com...
> Thanks,
> But the server.transfer... doesn't seem to work. What now. Thanx.
>

Could eloborate?  In what way does it not work?

Bookmark and Share