curl-users
FW: Specifying a IP address to curl
Date: Fri, 4 Mar 2005 18:08:48 +0530
I wanted to download using the specified IP address.
The command line used earlier is:
curl -v3 -P "167.68.0.67" -sc COOKIE
"http://courtgate.coca.co.clark.nv.us/DistrictCourt/asp/CaseNo.asp" >
/dev/null
The --interface option results into error. Here is the commandline and log
detail:
curl -v3 --interface "167.68.0.67" -sc COOKIE
"http://courtgate.coca.co.clark.nv.us/DistrictCourt/asp/CaseNo.asp" >
/dev/null
* About to connect() to webproxy port 80
* getaddrinfo(3) failed for 167.68.0.66:0
* Couldn't bind to '167.68.0.66'
* Closing connection #0
~Sagar S
-----Original Message-----
From: Daniel Stenberg [mailto:daniel-curl_at_haxx.se]
Sent: Friday, March 04, 2005 4:59 PM
To: sagar.saibi_at_patni.com; curl tool talk
Cc: 'Anand Singh'
Subject: Re: Specifying a IP address to curl
On Fri, 4 Mar 2005, Sagar Saibi wrote:
> I want to download a web page with a specific IP (167.68.1.66).
You mean you want to fetch from that IP
curl http://167.68.1.66/
or use it as source-IP?
curl --interface 167.68.1.66 [URL]
> Using -p option to specify IP it gives me connection error.
-p enables proxytunnel. How would that help you?
> But if am I using -P option it downloads the web page.
-P enables FTP PORT. I don't see how that helps you either.
> And with the -v3 option it gives me the following log :
-v and -3 are two options.
> About to connect() to webproxy port 80
> Connected to webproxy.int.westgroup.com (163.231.227.49) port 80
>
> How come this is connecting me to a different IP address.
Different than what? Can you show us a full command line?
> Can somebody please confirm whether the -P option is using my specified IP
> address.
It does if you transfer with FTP and the given IP is the one you want the
server to contact you back on. Otherwise it doesn't.
-- Daniel Stenberg -- http://curl.haxx.se -- http://daniel.haxx.se Dedicated custom curl help for hire: http://haxx.se/curl.html http://www.patni.com World-Wide Partnerships. World-Class Solutions. _____________________________________________________________________ This e-mail message may contain proprietary, confidential or legally privileged information for the sole use of the person or entity to whom this message was originally addressed. Any review, e-transmission dissemination or other use of or taking of any action in reliance upon this information by persons or entities other than the intended recipient is prohibited. If you have received this e-mail in error kindly delete this e-mail from your records. If it appears that this mail has been forwarded to you without proper authority, please notify us immediately at netadmin_at_patni.com and delete this mail. _____________________________________________________________________ http://www.patni.com World-Wide Partnerships. World-Class Solutions. _____________________________________________________________________ This e-mail message may contain proprietary, confidential or legally privileged information for the sole use of the person or entity to whom this message was originally addressed. Any review, e-transmission dissemination or other use of or taking of any action in reliance upon this information by persons or entities other than the intended recipient is prohibited. If you have received this e-mail in error kindly delete this e-mail from your records. If it appears that this mail has been forwarded to you without proper authority, please notify us immediately at netadmin_at_patni.com and delete this mail. _____________________________________________________________________Received on 2005-03-04