How to rotate the ip address of each request from the same machine

My requirement is to rotate the ip address for each HTTP request coming from the same machine. Is it possible to manage the IP addresses of each request at the application level, if I have a set of registered IP addresses with me?

thank

Jitendra

+3
source share
1 answer

Of course, all you have to do is associate the socket with the address you want to use. See Socket::bind(SocketAddress)and SocketFactory::createSocket(InetAddress, int, InetAddress, int).

You will most likely want to use the library to execute the request; you will need to find a way to specify, for example. SocketFactorythe library will use (or may already accept a local address).

0
source

All Articles