Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

how to automate logins into password protected sites

by coontie (Sexton)
on Nov 08, 2005 at 16:36 UTC ( [id://506792]=perlquestion: print w/replies, xml ) Need Help??

coontie has asked for the wisdom of the Perl Monks concerning the following question:

Hello, all. There're data files that are periodically posted on client's website. The page is password protected with the standard username|password boxes inside the page itself (meaning, it's NOT a popup box a la .htaccess directive). Similar to how hotmail/gmail/ny times/amazon login works. What's the best way to automate login into sites like these? Is there a pkg already out there that does that? Thank you.
  • Comment on how to automate logins into password protected sites

Replies are listed 'Best First'.
Re: how to automate logins into password protected sites
by Corion (Patriarch) on Nov 08, 2005 at 16:40 UTC

    You want to look into WWW::Mechanize, which makes automating complex website interactions much easier. Also useful might be HTTP::Recorder or my own module, WWW::Mechanize::Shell, which both allow you to interact with the website in a different way and produce a Perl script that replays your actions again.

Re: how to automate logins into password protected sites
by marto (Cardinal) on Nov 08, 2005 at 16:39 UTC
    Hi coontie,

    Take a look at the WWW::Mechanize module.
    The documentation covers filling in and submitting forms on webpages.
    This has been covered many times in the past. A Super Search before posting never goes a miss.

    Hope this helps.

    Martin
Re: how to automate logins into password protected sites
by Fletch (Bishop) on Nov 08, 2005 at 16:40 UTC

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://506792]
Approved by DrWhy
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others perusing the Monastery: (3)
As of 2024-04-20 00:40 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found