5

I'm looking for a solution to login to a website using a java program.

I found a good script over here:

http://www.dreamincode.net/forums/blog/114/entry-2715-login-to-a-website-from-java/

But the trouble is with handling cookies? How can I get the cookie info. send by the server? Thanks

3 Answers 3

4

Handling cookies using the java.net.* API

Sign up to request clarification or add additional context in comments.

1 Comment

@ ayush, thanks for the help it helped!!!! the method I was looking for was getHeaderField() of URLConnection class
1

Check JAAS , to use it for automatic log-in and if you are using IBM WebSphere check "Trust Association Interceptor"

Comments

0

Use HtmlUnit Framework. or Apache httpclient framework.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.