Is it possible to hide the IP address in a PHP connection?

In short, I want to test my bot systems on the site (the β€œbot” here refers to cheating players with programs, not spiders, etc.).

I wrote my own bot using the PHP CLI. In most cases, my site is able to detect bot activity and block it.

However, I need to check the work with dynamic IP addresses, and since I have a static one, this, as far as I can tell, is not easy. There are other things that I would like to check out, including several IP addresses.

So, in the bottom line, is it possible to hide / change the IP address visible by the server when my PHP script connects to it, and if so, how to do it? (I have never used proxies before, so I don’t know much about them).

+7
source share
3 answers

you can write test code that replaces $ _SERVER ['REMOTE_ADDR'] at the very beginning of your script and do whatever tests you like.

+7
source

No, IP is one of the few things that a client cannot mask.

+1
source

You can definitely use proxies. There are many open proxies that are available, but they are unreliable and slow. You can use paid proxy solutions, something like this proxy.lc

0
source

All Articles