Solved

Any chance to detect if the person is behind a proxy?

Posted on 2004-08-20
2
234 Views
Last Modified: 2012-05-05
hi all,

I know this is pretty impossible, but wh knows if there's any chance to do that and block access?  Also , how do you guys ban the person you don't really want to see on your site, I mean except IP & cookies, what else can be more reliable solution, can it be something like Wiindows unique certificate or something like that, I saw a lot of Request ServerVariables functions, any  of them can be unique or not for each user?

Also I know that php has function to detect the whole host not just an IP address, is that possible with asp?

Thanks,
N_F_S
0
Comment
Question by:N_F_S
[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
2 Comments
 
LVL 7

Accepted Solution

by:
vnvk earned 150 total points
ID: 11857777
I believe its not possible in ASP.

even for PHP, I tried the function at the below url:

http://www.phpbuddy.com/article.php?id=22

and it failed. Cos, I am behind a proxy server and a firewall and that url displayed the ip address of our ISP, as well as dsplayed that we are not behind proxy.

0
 
LVL 2

Expert Comment

by:Starr Duskk
ID: 14652672
in below examples, if it comes up blank, you know they are not behind a proxy...

ASP with Proxy detection

<%
    ipaddress = Request.ServerVariables("HTTP_X_FORWARDED_FOR")
    if ipaddress = "" then
        ipaddress = Request.ServerVariables("REMOTE_ADDR")
    end if
%>
 


PHP with Proxy detection

<?
    if (getenv(HTTP_X_FORWARDED_FOR)) {
        $ipaddress = getenv(HTTP_X_FORWARDED_FOR);
    } else {
        $ipaddress = getenv(REMOTE_ADDR);
    }
?>
 
JSP with Proxy detection

<%
    if (request.getHeader("HTTP_X_FORWARDED_FOR") == null) {
        String ipaddress = request.getRemoteAddr();
    } else {
        String ipaddress = request.getHeader("HTTP_X_FORWARDED_FOR");
    }
%>

0

Featured Post

Independent Software Vendors: 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

Suggested Solutions

Title # Comments Views Activity
Html Table Looping (part 2) 5 41
Display field if column exists 7 58
Want an individual results display div 8 61
Two decimal 5 43
I recently decide that I needed a way to make my pages scream on the net.   While searching around how I can accomplish this I stumbled across a great article that stated "minimize the server requests." I got to thinking, hey, I use more than one…
I was asked about the differences between classic ASP and ASP.NET, so let me put them down here, for reference: Let's make the introductions... Classic ASP was launched by Microsoft in 1998 and dynamically generate web pages upon user interact…
Are you ready to implement Active Directory best practices without reading 300+ pages? You're in luck. In this webinar hosted by Skyport Systems, you gain insight into Microsoft's latest comprehensive guide, with tips on the best and easiest way…

734 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