[lug] Off topic: java form-based authentication in a client program

mohadib mohadib at openactive.org
Wed Aug 30 17:48:07 MDT 2006


On Wed, 2006-08-30 at 17:31 -0600, Michael J. Hammel wrote:
> On Wed, 2006-08-30 at 14:55 -0600, mohadib wrote:
> > URLConnection is the best way , but you can also use
> > the JDIC browser. The benefit of this is you can leverage the
> > browser and javascript. You dont have to show the browser.
> 
> According to this link:
> http://www.innovation.ch/java/HTTPClient/urlcon_vs_httpclient.html
> neither HTTPClient nor URLConnection support form-based authentication
> specifically, though I suppose it can be added to HttpClient.  It also
> looks like URLConnection does not support Cookies, which it seems I
> would need for form-based authentication.
> 
> Hmmm.  JDIC looks interesting.  I'll have to investigate this a bit
> more.  
> 
> Thanks for the tip!



I have a lib for cookies for urlconnection if you go that route.
Authentication is just another post right?

JDIC rocks. I use it for screen scrapping alot. Just pass it
some JS to eval. Its really cool.

good luck,
jd





More information about the LUG mailing list