Tuesday, 27 August 2013

Glassfish Digest Authentication

Glassfish Digest Authentication

i want to build RESTful webservices using JAX-RS (Jersey + Jackson,
Jackson for production of JSON).
I'm using Glassfish 4.0 as server and netbeans as the IDE.
The webservices are working fine but at the moment i don't have any
authentication.
so now i'm thinking about the digest authentication which hashes the
password, so that you never need to transmit the password in plain text.
And additionally i want to use https, so that the data is encrypted.
I understood the theorie. But i have no idea how i can do this in Netbeans
with Glassfish.
I saw some tutorials doing something in the admin-console of glassfish.
But isn't there a way to do it just in netbeans? Can't i define a realm in
netbeans which will be created when i deploy the application?
After creating the realm and stuff. I think i need to inject some kind of
an authenticated "user"-Object in all my resources (WebServices). But i
never did this before. And i'm looking for a good tutorial which describes
how i can set up the digest authentication and the injection trough
netbeans can do this with netbeans so that i can understand it well.

No comments:

Post a Comment