Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Email login via perl script

Status
Not open for further replies.

GezH

Programmer
Aug 7, 2002
68
Hello all.

Do you think it's possible to write a script which will simulate a login to an email client, such as Hotmail, gmail, yahoo etc?

I was thinking along the lines of some kind of HTTP request which passed in the username and password, then tested the reponse code (authorized, forbidden etc) to see whether the login was valid or not.

Any ideas?

PS I'm not a hacker! I want to learn about HTTP and authorization and thought this would be fun - I'm sure there are plenty of programs out there for that sort of thing, if you were so inclined...
 
Thanks - looks like some fun things to try out there.

I am currently working on a Windows PC. Am I able to run 'tar' files on ActivePerl for windows, or will I have to setup a linux environment?
 
You use the Perl Package Manager (PPM) that comes with activeperl to install modules. Not all modules are ported over to use on Windows but there are a large number. I suggest using the PPM GUI instead of the command line interface to PPM. Activeperl comes with a ton of documentation or you can read the documentation online at the activestate website.

------------------------------------------
- Kevin, perl coder unexceptional! [wiggle]
 
You can also try strawberry perl ( which uses the standard CPAN interface and supposedly can install the CPAN listed modules. But you have to completely uninstall any other version of perl you currently have installed on your Windows box before trying to use a different version of perl otherwise things will just get nasty.

------------------------------------------
- Kevin, perl coder unexceptional! [wiggle]
 
Thanks for the StrawberryPerl tip, it looks good.

However I'm having problems installing the required dependency modules, and I'm not sure whether it's a problem specific to the release or just a general Perl thing.

I'm trying to install OpenSSL using the cpan client, and I get the following error:


CPAN.pm: Going to build O/OE/OESI/OpenSSL-0.09.tar.gz

Checking if your kit is complete...
Looks good
Writing Makefile for OpenSSL
cp OpenSSL/Digest.pm blib\lib/OpenSSL/Digest.pm
cp OpenSSL/PKCS7.pm blib\lib/OpenSSL/PKCS7.pm
cp OpenSSL/PKCS12.pm blib\lib/OpenSSL/PKCS12.pm
cp OpenSSL/Cipher.pm blib\lib/OpenSSL/Cipher.pm
cp OpenSSL/Name.pm blib\lib/OpenSSL/Name.pm
cp OpenSSL/RSA.pm blib\lib/OpenSSL/RSA.pm
cp OpenSSL/X509.pm blib\lib/OpenSSL/X509.pm
cp OpenSSL/Rand.pm blib\lib/OpenSSL/Rand.pm
cp OpenSSL.pm blib\lib/OpenSSL.pm
cp OpenSSL/CRL.pm blib\lib/OpenSSL/CRL.pm
cp OpenSSL/BN.pm blib\lib/OpenSSL/BN.pm
AutoSplitting blib\lib/OpenSSL/BN.pm (blib\lib\auto\OpenSSL\BN)
cp OpenSSL/HMAC.pm blib\lib/OpenSSL/HMAC.pm
C:\strawberry\perl\bin\perl.exe C:\strawberry\perl\lib\ExtUtils\xsubpp -typemap C:\strawberry\perl\lib\ExtUtils\typemap -typemap typemap OpenSSL.xs > OpenSSL.xsc && C:\strawberry\perl\bin\perl.exe -MExtUtils::Command -e mv OpenSSL.xsc OpenSSL.c
gcc -c -I. -s -O2 -DWIN32 -DHAVE_DES_FCRYPT -DPERL_IMPLICIT_CONTEXT -DPERL_IMPLICIT_SYS -fno-strict-aliasing -DPERL_MSVCRT_READFIX -s -O2 -DVERSION=\"0.09\" -DXS_VERSION=\"0.09\" "-IC:\strawberry\perl\lib\CORE" OpenSSL.c
OESI/OpenSSL-0.09.tar.gz
C:\strawberry\c\bin\dmake.EXE -- NOT OK
Running make test
Can't test without successful make
Running make install
Make had returned bad status, install seems impossible
 
Do you have dmake.exe installed?

C:\strawberry\c\bin\dmake.EXE

------------------------------------------
- Kevin, perl coder unexceptional! [wiggle]
 
Yes... except that the actual file is lower case (dmake.exe) but I assume that doesn't matter?
 
Is this vista? Check the permissions on that file.

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
[noevil]
Travis - Those who say it cannot be done are usually interrupted by someone else doing it; Give the wrong symptoms, get the wrong solutions;
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top