cURL / Mailing Lists / curl-library / Single Mail


Re: Re: [patch] Changing the originating IP of outgoing posts

From: Pascal TROUVIN <>
Date: Tue, 28 Sep 2004 07:47:41 +0200 (CEST)

No, the idea is not to choose the ouput interface on the curl system.

But to specify the ip address of the TARGET system.

Just think about the following architecture:

    | is directed by DNS to a virtual IP load balanced among a
    | farm of web server
 +-----+----+--... Official Network
W1 W2 W3 ....

Now suppose you can reach each Web server individually because you know each IP address.

When you use curl in the normal way:


You get the response from one server in the pool.

And for security reason the web server refuse:

curl http://1.2.3.W1/

So I add the support of:

curl --remote-ip 1.2.3.W1

Which works fine here, I can test each web server in the pool.

In fact I do that for the integration of individual test in Nagios (Network monitoring).



> Message du 27/09/04 19:50
> De : "Daniel Stenberg" <>
> A :, "libcurl development" <>
> Copie &agrave; :
> Objet : Re: [patch] Changing the originating IP of outgoing posts
> On Mon, 27 Sep 2004, Pascal TROUVIN wrote:
> > I do not know if this is really your problem, but I patched curl to add a
> > new option '--remote-ip', this new option let you specify a URL and assign
> > the request to the specified host IP address.
> You mean like --interface already works?
> --
> Daniel Stenberg -- --
> Dedicated custom curl help for hire:
Received on 2004-09-28