Solved

Block single .aspx page from being accesses from a single public IP

Posted on 2013-06-26
3
536 Views
Last Modified: 2013-06-28
I want to block www.example.com/user/login.aspx from being accessed from an external IP address of 1.2.3.4. Users at 1.2.3.4 still need to be able to access www.example.com/user and all other pages in that sub folder, just not login.aspx. Can this be accomplished?
0
Comment
Question by:Wetjet
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 25

Accepted Solution

by:
Ron Malmstead earned 250 total points
ID: 39281529
...on the load event for the login.aspx page..

 If Request.UserHostAddress.ToString = "1.2.3.4" Then
            Response.Redirect("www.someurl.com")
        End If
0
 
LVL 11

Assisted Solution

by:Sanjay Santoki
Sanjay Santoki earned 250 total points
ID: 39283814
Hello,

You can achieve it if you have IP address and Domain restrictions feature is installed in IIS role. Install if it is not installed and follow below simple steps to achieve your requirements;

Open IIS Manager -> Expand www.example.com -> users -> changed to content view which will show you list of files located under users folder -> right click on login.aspx -> switch to features view -> IP Address and Domain Restrictions -> from the Action pane select Add deny entry

;)

Regards,
Sanjay Santoki
0
 

Author Closing Comment

by:Wetjet
ID: 39285924
Thank you both of you.
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When you try to share a printer , you may receive one of the following error messages. Error message when you use the Add Printer Wizard to share a printer: Windows could not share your printer. Operation could not be completed (Error 0x000006…
This article will inform Clients about common and important expectations from the freelancers (Experts) who are looking at your Gig.
Viewers will learn how to connect to a wireless network using the network security key. They will also learn how to access the IP address and DNS server for connections that must be done manually. After setting up a router, find the network security…
After creating this article (http://www.experts-exchange.com/articles/23699/Setup-Mikrotik-routers-with-OSPF.html), I decided to make a video (no audio) to show you how to configure the routers and run some trace routes and pings between the 7 sites…

751 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question