cURL
Haxx ad
libcurl

curl's project page on SourceForge.net

Sponsors:
Haxx

cURL > Mailing List > Monthly Index > Single Mail

curl-users Mailing List Archives

newbie login question

From: Horvath Adam <arunaseva_at_gmail.com>
Date: Thu, 12 Mar 2009 13:39:22 +0100

Hi!

I have a CURL question.

I created a login form. I like to fill this form and send with curl from
debian command-line. An outer domain authenticate this form and redirect
to another page. I need this page output back.

bash curl->login.php->outer authentication domain->redirect.php->bash curl

http://mydomain/login.php (my page):

<form method="post" action="https://outerdomain/auth.aspx">
Login name: <input type="text" name="LOGINNAME"/><br/>
Password: <input type="password" name="PWD"/><br/>
<input type="submit" name="sendbtn" value="Login"/>

... curl fill "LOGINNAME" and "PWD" fields and press the "Login" button and
accept the certificate (https).

... the outer domain authenticate (https://outerdomain/auth.aspx) and
send the answer back: http://mydomain/redirect.php (my page)

redirect.php output authentication result (success/no success)

curl have to get back this output and print to command line

First, I would be happy, if I could send the login form and so on

I tried this:

curl -L -e -d "LOGINNAME=name&PWD=password&sendbtn=Login"
http://mydomain/login.php

Not work.

Can you help me?

Thanks
Adam
-------------------------------------------------------------------
List admin: http://cool.haxx.se/cgi-bin/mailman/listinfo/curl-users
FAQ: http://curl.haxx.se/docs/faq.html
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2009-03-12

These mail archives are generated by hypermail.

donate! Page updated November 12, 2010.
web site info

File upload with ASP.NET