cURL / Mailing Lists / curl-library / Single Mail


Re: Limiting IP addresses CURL is allowed to connect to.

From: Sam Olsen <>
Date: Mon, 4 Aug 2008 16:58:42 +0200

That's a perfectly acceptable solution. I just figured it might be something
others would find
useful as well, in which case it would make sense to include support for it
in libcurl itself.

Anyhow, thank you for responding.

On Mon, Aug 4, 2008 at 3:38 PM, Ralph Mitchell <>wrote:

> On Mon, Aug 4, 2008 at 8:22 AM, Sam Olsen <> wrote:
>> Hi,
>> I've found myself wanting to control the IP address scope of applications
>> using libcurl in
>> FOLLOWLOCATION mode several times, and it is now a requirement for one of
>> the projects
>> I'm working on. I'm basically using libcurl to crawl websites and would
>> like to somehow prevent
>> the crawler from hitting unintended sites.
>> Is there someway to accomplish what I want with the current version of
>> libcurl?
> Why not just turn off FOLLOWLOCATION and handle all the redirects
> yourself?? Are you planning on handling other kinds of redirects, such as
> "meta refresh" tags and self-submitting forms?? Just deal with "Location"
> headers the same way.
> Ralph Mitchell
Received on 2008-08-04