Henrique Gonçalves
Henrique Gonçalves

Reputation: 1582

Set up a Java OAuth Provider

So, I am trying to set up an OAuth Provider in Java, but I just cannot get the hang of it. Everywhere I look I'm always redirected here (http://oauth.net/code) but there's no documentation. Could someone help me out, step by step, or reference me to a more direct guide? I'm even having trouble building the library. Can anyone help me please? Thank you very much.

Upvotes: 1

Views: 2362

Answers (2)

Jesvin Jose
Jesvin Jose

Reputation: 23078

Refer http://oauth.net/core/1.0a

To learn the workflow, refer http://hueniverse.com/oauth/guide/workflow/ and the Appendix A of the document.

Then chapters 3 and 4 to learn of all entities. For the actual workflow, read chapters 6 and 7 with their respective appendix entries.

Chapter 10 is a handy debug thing.


I guess you need to implement the datastore yourself, and I dont envy you :-)

Learn from the datastore for Oauth-PHP library . http://code.google.com/p/oauth-php/source/browse/trunk/library/store/mysql/mysql.sql . Refer all the oauth_server_* tables to get an idea of how to store data for an OAuth provider.


OAuth server and client libraries should abstract the rest.

Upvotes: 2

PrimosK
PrimosK

Reputation: 13918

I would suggest Spring Security OAuth for this kind of tasks.

You have two sample projects there:

  • sparklr - provider
  • tonr - consumer

Maybe the best way to learn would be investigating source code.

You can find additional info there...

Upvotes: 2

Related Questions