Automatic login a website

H

hennakapoor

Hi
I am trying to think of a solution for logging automatically into a
website say mail.yahoo.com.
The user provides the username and the password and the website address
and the application should log automatically into it.
I realize that there may not be a general purpose solution.
Nevertheless, I was curious to figure out if this can be done for
mail.yahoo.com.
The place where I am getting stuck is this:
mail.yahoo.com does a javascript md5 of the username and password and
then sends it in a POST.
How do I do that in an application i.e.
a) the application should download the webpage (done)
b) the application should then parse the webpage and extract
javascript(done...partially)
c) the application should then run javascript interpreter to execute
the relevant md5 javascript (not done...do I have to include a
javascript interpreter in the application then?)
d) the application should then send a POST with the processed data(can
be done...)

Step (b) is pretty complex and I don't think I will be able to do it as
a general purpose solution
Are there any other suggestions to achieve this goal?
I used to think that automatic login should be pretty simple given that
automatic form filling is available everywhere. However, am facing
problems at every step. Thanks for any suggestions
 
E

Erwin Moller

hennakapoor said:
Hi
I am trying to think of a solution for logging automatically into a
website say mail.yahoo.com.
The user provides the username and the password and the website address
and the application should log automatically into it.
I realize that there may not be a general purpose solution.
Nevertheless, I was curious to figure out if this can be done for
mail.yahoo.com.
The place where I am getting stuck is this:
mail.yahoo.com does a javascript md5 of the username and password and
then sends it in a POST.
How do I do that in an application i.e.
a) the application should download the webpage (done)
b) the application should then parse the webpage and extract
javascript(done...partially)
c) the application should then run javascript interpreter to execute
the relevant md5 javascript (not done...do I have to include a
javascript interpreter in the application then?)
d) the application should then send a POST with the processed data(can
be done...)

Step (b) is pretty complex and I don't think I will be able to do it as
a general purpose solution
Are there any other suggestions to achieve this goal?
I used to think that automatic login should be pretty simple given that
automatic form filling is available everywhere. However, am facing
problems at every step. Thanks for any suggestions

Hi,

Didn't you mean to send this posting to a javaSCRIPT newsgroup instead?
Try comp.lang.javascript next time. :)

A for your problem:
Why don't you use the md5-js-routine to hash the usename/password and send
it directly to mail.yahoo.com without intermediate steps?

Regards,
Erwin Moller
 
H

hennakapoor

Didn't you mean to send this posting to a javaSCRIPT newsgroup
instead?
Try comp.lang.javascript next time. :)

A for your problem:
Why don't you use the md5-js-routine to hash the usename/password and send
it directly to mail.yahoo.com without intermediate steps?

Yes I think I should post it to comp.lang.javascript also? The reason I
posted in this group is because the utilities that I had come across
that behave in somewhat similar (not *exactly*) are all written in Java
and I initially started on the assumption that Java will have some
classes to support this.

The reason I cannot hardcode md5-js-routine in my code is because then
it will not be general purpose code. mail.yahoo.com was an example of
the kind of the problem that I am facing which is parse the webpage and
then execute any javascript if included in the webpage
 
E

Erwin Moller

hennakapoor said:
Yes I think I should post it to comp.lang.javascript also? The reason I
posted in this group is because the utilities that I had come across
that behave in somewhat similar (not *exactly*) are all written in Java
and I initially started on the assumption that Java will have some
classes to support this.

The reason I cannot hardcode md5-js-routine in my code is because then
it will not be general purpose code. mail.yahoo.com was an example of
the kind of the problem that I am facing which is parse the webpage and
then execute any javascript if included in the webpage

Hi hennakapoor,

Are you REALLY trying to create software that can 'bypass' the original
setup, regardless how it was implemented in JS?
I mean, you want your code to work by examining the 'raw' JS and mimic its
behaviour?
Even when it was created to make thing difficult?

That requires quite a bit of really smart advanched parsing.

Completely beyond my grasp I must admit...
:-/

Or maybe you have some smart trick I don't see??

I hope somebody else can help you.

Good luck!

Regards,
Erwin Moller
 
H

hennakapoor

Thanks for your response. You are correct in your assessment that this
will require smart advanced parsing. That is exactly where I was stuck
and was trying to figure out alternatives. Now that you have echoed the
same view- I guess the problem has to be resolved in an alternative
way.

I am now thinking of creating a small automatic form filler software.
Plenty of these exist e.g. check roboform. The solution using this will
be fairly cumbersome - but that is the best that can be had under the
circumstances.

The latest problem (I always have a problem at hand:))
How do the form filling software determine which text field gets what
data i.e. a typical form filling software will ask the user to enter
the username / address / password etc. Whenever it goes to a website
(ANY website) that requires these data - it tries to supply the
relevant data to the most appropriate text field. How does it decide
that?

Am posting it to this newsgroup since again most of these software seem
to be java based and also I could not find a more relevant place. If
anyone can point me to a more relevant location - that will also help
Thanks
 
Joined
May 31, 2006
Messages
1
Reaction score
0
Hi,
I am facing the same problem but with google,
Please let me know how did you fix the problem, thank you very much...
I searched lot of forums but no code or help available

All the best
 
Joined
Apr 1, 2008
Messages
1
Reaction score
0
Problem!

hennakapoor said:
Thanks for your response. You are correct in your assessment that this
will require smart advanced parsing. That is exactly where I was stuck
and was trying to figure out alternatives. Now that you have echoed the
same view- I guess the problem has to be resolved in an alternative
way.

I am now thinking of creating a small automatic form filler software.
Plenty of these exist e.g. check roboform. The solution using this will
be fairly cumbersome - but that is the best that can be had under the
circumstances.

The latest problem (I always have a problem at hand:))
How do the form filling software determine which text field gets what
data i.e. a typical form filling software will ask the user to enter
the username / address / password etc. Whenever it goes to a website
(ANY website) that requires these data - it tries to supply the
relevant data to the most appropriate text field. How does it decide
that?

Am posting it to this newsgroup since again most of these software seem
to be java based and also I could not find a more relevant place. If
anyone can point me to a more relevant location - that will also help
Thanks

Erwin Moller wrote:

> Hi hennakapoor,
>
> Are you REALLY trying to create software that can 'bypass' the

original
> setup, regardless how it was implemented in JS?
> I mean, you want your code to work by examining the 'raw' JS and

mimic its
> behaviour?
> Even when it was created to make thing difficult?
>
> That requires quite a bit of really smart advanched parsing.
>
> Completely beyond my grasp I must admit...
> :-/
>
> Or maybe you have some smart trick I don't see??
>
> I hope somebody else can help you.
>
> Good luck!
>
> Regards,
> Erwin Moller







Hi,
actually i am a fresher to all this, and dont know much about scripting!. i use .net enviroment to make applications in C#..so i wanted to know about how to get auto logged in into a web site?? means like clicking a link and then the ID and Password is aleady provided somewhere, so get in.

can u help me on the topic??
Thank you very much in advance!!!
hope to get your reply!!
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,768
Messages
2,569,574
Members
45,051
Latest member
CarleyMcCr

Latest Threads

Top