I have a (Webserver)Server with two network interfaces. The first is the standard interface with the public internet connection, the other is a virtual VPN-networkinterface.
Now I want to send POST data via curl on an other Webservice within the VPN-Network.
How I can say the php there have to call the address with the VPN-Networkinterface?
The documentation lists CURLOPT_INTERFACE as a configurable option.
CURLOPT_INTERFACE The name of the outgoing network interface to use. This can be an interface name, an IP address or a host name.
curl_setopt($ch, CURLOPT_INTERFACE, "XXX.XXX.XXX.XXX");
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With