Which Java library should I use for authentication through Facebook, Gmail, local auth, etc.?
Asked Answered
A

3

8

Which Java library do you recommend to implement authentication in a Java web app (just servlets & JSPs)? We want to offer the most common authentication providers (Facebook, Yahoo, Gmail, etc.) and also local account registration.

I have found SocialAuth but it looks pretty new and I don't know if there are better alternatives. In addition, it looks like SocialAuth will request access to users contacts which I don't need and could annoy our users.

Thanks!

Adolphus answered 14/12, 2010 at 16:39 Comment(0)
S
2

You can checkout the newer version of SocialAuth, u can set the level of permissions to be asked from the users.

Stibnite answered 10/6, 2011 at 14:39 Comment(0)
B
0

Spring Security is a good starting point to get a flexible authentication system in your project.

http://static.springsource.org/spring-security/site/

There is a spring-security-facebook plugin that will integrate facebook auth.

http://code.google.com/p/spring-security-facebook/

I'm not sure about the others specifically. If you are talking about OpenID then spring security supports that.

Belindabelisarius answered 14/12, 2010 at 16:50 Comment(3)
But as I said it is a plain Servlets + JSP application. We are not using Spring. We would like to use a standalone library, just for authentication.Betts
It is possible to use spring security and spring without any of the web mvc stuff. Though, it would almost be more trouble to avoid all of the dependencies then it is worth not adopting it all. The the facebook spring security module uses a java facebook library that you could leverage. code.google.com/p/facebook-java-apiBelindabelisarius
Looking at SocialAuth, it looks more up your ally then anything else I know of.Belindabelisarius
A
0

I ended up using openid4java to integrate Google and Yahoo OpenId, and plain HttpClient calls to integrate OAuth based services (Facebook and Hotmail).

Adolphus answered 10/5, 2011 at 15:36 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.