cURL / Mailing Lists / curl-users / Single Mail

curl-users

Re: problem with POST on Redirecting!

From: Ralph Mitchell <rmitchell_at_eds.com>
Date: Thu, 05 Dec 2002 00:20:30 -0600

The fact the the page is generated by a php script is irrelevant. The
browser never sees the php script, unless something goes horribly wrong
on the server. All the browser sees is the html generated by the
script.

So, the approach that has always worked for me is pretty much as Daniel
detailed it, except that I don't use a network analyser, I just fetch
the first page the browser would get, then the next page and so on,
following redirects and accumulating cookies along the way until I get
to the form to fill in.

Once I have the form in html in a file, I strip out the obvious fluff
(tables, images, etc) until I have reduced it to the essential details.
This way I make sure I don't miss anything. (Daniel, formfind.pl is
very useful, but I've found that it doesn't pick up values that include
spaces...)

The next step is to post back the form, with any associated cookies,
making sure I post back absolutely *every* input field, including the
submit button value, just in case the server wants it.

This is all done in a script, adding steps along the way until the form
is posted, so that the cookies are all nice and fresh every time I run
it...

Ralph Mitchell

Sanjeev wrote:

> > 1. Record a full session with a network analyzer
> > when you do this with your
> > browser. You should see a bunch of HTTP requests
> > and replies.
> >
> > 2. Based on the recording, you make sure you repeat
> > the operations as closely
> > as possible using curl.
> >
>
> Sure Sir! I will try these Options! I dont have any
> idea of this network analyzer! But i will check it!
>
> > If you still want our help, you need to take this
> > issue one step back and:
> >
> > 1. Keep everything on this list, not to my personal
> > email. I am not a private
> > support person. (Unless you feel like paying for
> > my help.)
> >
>
> Sorry! Once Again sir! As I said the problem with
> yahoo
> mailbox and its attachments, And since i caanot use
> another account for sending to mailing list other than
> subscribing with that ID also, i thought may be i can
> send those attachment to your private id. I'm
> extremely sorry sir!
>
> > 2. Show us the HTML of the form you're trying to
> > automaticly login to. I very
> > much suspect you have ignored some hidden input
> > fields or similar.
> >
>
> This in fact is a php file which has so many variables
>
> coming from other pages. So i thought this wouldn't be
> of any help! even i have to keep in mind my company's
> privacy!

-------------------------------------------------------
This SF.net email is sponsored by: Microsoft Visual Studio.NET
comprehensive development tool, built to increase your
productivity. Try a free online hosted session at:
http://ads.sourceforge.net/cgi-bin/redirect.pl?micr0003en
Received on 2002-12-05