[lug] Off topic: java form-based authentication in a client program
Michael J. Hammel
mjhammel at graphics-muse.org
Wed Aug 30 17:23:01 MDT 2006
On Wed, 2006-08-30 at 16:47 -0600, bgiles at coyotesong.com wrote:
> Web services description language, iirc.
That sounds right.
> If you're doing web services you should have libraries that already handle
> all of the grunt work.
All the WSDL generation is automated through Axis in the build. The way
I've been looking at this is that the WSDL stuff is just a fancy
wrapping around the RPC mechanisms so my client can make a call to a
class method that is actually on the server without having to do a bunch
of manual connections, etc. I see everything from a C perspective (my
primary language), so maybe this isn't the right way to view this.
Looking at our client (which I haven't done much until today) it appears
that we used to use methods of the org.apache.axis.client.Stub interface
for logging in. We have a class that extends the Stub class and then
simply calls setUsername and setPassword (it was set up for BASIC
authentication). Then we call a method in our stub class to do
processing. I guess that when the call to our method is made, the login
information is passed along with it and used each time. Sounds like
with form-based authentication I need to login first using HttpClient
(or similar ) and then save the session information in the stub class
instead of passing username/password manually with each method call to a
service on the server.
Does that sound about right? Do I just save the session information in
a "session" property? There is a maintainSessionSet field in the Stub
class but nothing for saving the session directly.
I'm reading up on HttpClient now. The first thing I noticed was the it
doesn't explicitly support form-based authentication. It only
explicitly supports BASIC, DIGEST and NTLM.
> Establishing connections, marshalling and
> unmarshalling objects between POJOs and XML, etc. You have the Sun JWSDP
> (Java web services development p???), right?
Um. I dunno. I got Java 1.4 and JBOSS. Not sure where to look for
JWSDP.
--
Michael J. Hammel Senior Software Engineer
mjhammel at graphics-msue.org http://graphics-muse.org
------------------------------------------------------------------------------
Somewhere in Texas...a village is missing its idiot.
-- Anyone but Bush in 2004 --
More information about the LUG
mailing list