Book Image

RESTful Java Web Services, Second Edition

Book Image

RESTful Java Web Services, Second Edition

Overview of this book

Table of Contents (17 chapters)
RESTful Java Web Services Second Edition
Credits
About the Author
Acknowledgments
About the Reviewers
www.PacktPub.com
Preface
Index

Securing RESTful web services with OAuth


OAuth is an open standard for authorization, used by many enterprises and service providers to protect resources. OAuth solves a different security problem than what HTTP basic authentication has been used for. OAuth protocol allows client applications to access protected resources on behalf of the resource owner (typically, the application user).

If we look at the history of this protocol, the OAuth Version 1.0 was published as RFC 5849 in 2010. Later, the next evolution of OAuth, Version 2.0, was published as RFC 6749 in 2012. Note that these two versions are different in their implementations and do not have many things in common. In this section, we will see what the OAuth protocol and its details are. We will also discuss how a RESTful web service client can access OAuth-protected RESTful web APIs.

Understanding the OAuth 1.0 protocol

The OAuth protocol specifies a process for resource owners to authorize third-party applications to access their...