A-M baby
This commit is contained in:
parent
764da6cbbb
commit
db842d013d
19005 changed files with 197040 additions and 7 deletions
19
Task/HTTPS-Authenticated/Perl/https-authenticated.pl
Normal file
19
Task/HTTPS-Authenticated/Perl/https-authenticated.pl
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
use LWP::UserAgent qw();
|
||||
my $ua = LWP::UserAgent->new;
|
||||
my $netloc = 'http://www.buddhism-dict.net/cgi-bin/xpr-dealt.pl:80';
|
||||
$ua->credentials(
|
||||
$netloc,
|
||||
'CJK-E and Buddhist Dictionaries', # basic realm
|
||||
'guest', # user
|
||||
'', # empty pw
|
||||
);
|
||||
my $response = $ua->get($netloc);
|
||||
|
||||
use WWW::Mechanize qw();
|
||||
my $mech = WWW::Mechanize->new;
|
||||
$mech->get('https://login.yahoo.com/');
|
||||
$mech->submit_form(with_fields => {
|
||||
login => 'XXXXXX',
|
||||
passwd => 'YYYYYY',
|
||||
'.persistent' => 'y', # tick checkbox
|
||||
});
|
||||
Loading…
Add table
Add a link
Reference in a new issue