Chaoskeeper
asked on
Masking server IP with fsockopen?
here's my code so far
$url='http://whatismyipaddress.com/';
$proxy = '128.130.35.76'; // proxy IP, change this according to your proxy setting in your IE or NS
$port = 80; // proxy port, change this according to your proxy setting in your IE or NS
$fp = fsockopen($proxy, $port);
fputs($fp, "GET $url HTTP/1.0\r\nHost: $proxy\r\nConnection: close\r\n\r\n");
while(!feof($fp)){
$line = fgets($fp, 4000);
print($line);
}
fclose($fp);
The connection to the proxy server seems to work just fine, but still after loading the page it still shows the IP of my server.
Is there any way to hide my servers' IP behind the proxy I've chosen?
$url='http://whatismyipaddress.com/';
$proxy = '128.130.35.76'; // proxy IP, change this according to your proxy setting in your IE or NS
$port = 80; // proxy port, change this according to your proxy setting in your IE or NS
$fp = fsockopen($proxy, $port);
fputs($fp, "GET $url HTTP/1.0\r\nHost: $proxy\r\nConnection: close\r\n\r\n");
while(!feof($fp)){
$line = fgets($fp, 4000);
print($line);
}
fclose($fp);
The connection to the proxy server seems to work just fine, but still after loading the page it still shows the IP of my server.
Is there any way to hide my servers' IP behind the proxy I've chosen?
ASKER
the proxy is actually a random one somewhere on the internet
it seems that my host only accepts connections from the common ports (80,21, 110, etc) so I can't take any proxy that has a fancy port
but still if I take a proxy server stated as "high-anonymity" in this list http://www.proxylist.com.ru/proxyb-search.php?act=list&queryId=WW22T4aUh&page=11 it still shows my servers IP
tricky little bastard
it seems that my host only accepts connections from the common ports (80,21, 110, etc) so I can't take any proxy that has a fancy port
but still if I take a proxy server stated as "high-anonymity" in this list http://www.proxylist.com.ru/proxyb-search.php?act=list&queryId=WW22T4aUh&page=11 it still shows my servers IP
tricky little bastard
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
It seems that your proxy is a transparent proxy, showing who is doing what behind the proxy.
You need to configure your proxy to be a anonymous proxy, meaning that the proxy will not relay your ip, but show the proxy ip address.
If it is your corporate firewall, I reckon you will have trouble changing the settings because of the obvious consequence.....
Regards,
alain34