View Single Post
Old 04-21-2011, 11:36 AM  
Klen
 
Klen's Avatar
 
Industry Role:
Join Date: Aug 2006
Location: Little Vienna
Posts: 32,235
Quote:
Originally Posted by fris View Post
Code:
<?php

$test = new proxyCheck();
$test->serverVar = $_SERVER;
$header = $test->checkHeader();

class proxyCheck {
	  
	  var $serverVar = array();
	  
	  private $proxyHeader = array();
	  
		function checkHeader() {
			
			  if(isset($this->serverVar['HTTP_X_FORWARDED_FOR'])) {
			  		$this->proxyHeader['HTTP_X_FORWARDED_FOR'] = $this->serverVar['HTTP_X_FORWARDED_FOR'];
			  }
			  
	  	  if(isset($this->serverVar['HTTP_X_FORWARDED'])) {
	  			  $this->proxyHeader['HTTP_X_FORWARDED'] = $this->serverVar['HTTP_X_FORWARDED'];
			  }
			  
			  if(isset($this->serverVar['HTTP_FORWARDED'])) {
	  			  $this->proxyHeader['HTTP_FORWARDED'] = $this->serverVar['HTTP_FORWARDED'];
			  }
			  
			  if(isset($this->serverVar['HTTP_PROXY_AGENT'])) {
	  			  $this->proxyHeader['HTTP_PROXY_AGENT'] = $this->serverVar['HTTP_PROXY_AGENT'];
			  }
			  
			  if(isset($this->serverVar['HTTP_VIA'])) {
	  			  $this->proxyHeader['HTTP_VIA'] = $this->serverVar['HTTP_VIA'];
			  }
			  
			  if(isset($this->serverVar['HTTP_PROXY_CONNECTION'])) {
	  			  $this->proxyHeader['HTTP_PROXY_CONNECTION'] = $this->serverVar['HTTP_PROXY_CONNECTION'];
			  }
			  
			  if(isset($this->serverVar['HTTP_CLIENT_IP'])) {
	  			  $this->proxyHeader['HTTP_CLIENT_IP'] = $this->serverVar['HTTP_CLIENT_IP'];
			  }
			  
			  return $this->proxyHeader;
		}
		
		
}

?>
not sure if this is what you are after.
Welll there are several types of proxys,what is considered proxy here it's non-anonymous alias transparent proxy where you can see both real and proxy ip.I find it weird why this kind of proxy ip's still exits since all web proxy sites are anonymous proxies,plus even if someone using classing proxies it's very easy to find anonymous proxies.I guess only bot things uses this kind of proxy therefore it need to be banned from traffic pool.
Klen is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote