SlideShare a Scribd company logo
Copyright © 2013, Oracle and/or its affiliates. All rights reserved.1
OAuth 2.0 Overview
Oracle Asia Research and Development Center
Alice Liu(lzhmails@gmail.com)
Copyright © 2013, Oracle and/or its affiliates. All rights reserved.2
 OAuth 2.0 Overview
 3-Legged OAuth/ 2-Legged Oauth
 OAuth Workflow
Copyright © 2013, Oracle and/or its affiliates. All rights reserved.3
 OAuth Terms
– Client is an application accessing an API, can be a web app, app
inside a user agent, or a native app
– Resource Owner is a “user” who can authorize/grant access to API
resources
– Resource Server is the API host
– Authorization Server is the authorization PDP and STS
 OAuth 2.0 is relatively simple
– Get the token
– Use the token to access the protected resource
OAuth 2.0 Overview
OAuth 2.0 Authorization Server
Copyright © 2013, Oracle and/or its affiliates. All rights reserved.4
 In the traditional client-server authentication model, the client accesses a protected resource on the server
by authenticating with the server using the resource owner's credentials. In order to provide third-party
applications access to protected resources, the resource owner shares its credentials with the third-
party. This creates several problems and limitations.
 Third-party applications are required to store the resource-owner's credentials for future use, typically a
password in clear-text.
 Servers are required to support password authentication, despite the security weaknesses created by
passwords.
 Third-party applications gain overly broad access to the resource-owner's protected resources, leaving
resource owners without any ability to restrict duration or access to a limited subset of resources.
 Resource owners cannot revoke access to an individual third-party without revoking access to all third-
parties, and must do so by changing their password.
OAuth 2.0 Overview
OAuth 2.0 Authorization Server
Copyright © 2013, Oracle and/or its affiliates. All rights reserved.5
3-Legged OAuth
1) The resource owner connects to an OAuth Client
enabled service and requests it access resources at
a different site
2) The OAuth Client (requesting site) redirects the user
to the OAuth Authorization Server, which
authenticates the user and presents a consent page.
It then sends authorization code to the OAuth client
3) The OAuth Client uses the authorization code to
retrieve an OAuth Access Token from the OAuth
Authorization Server
4) The OAuth Client presents the Access Token to the
OAuth Resource Server
5) The Resource Server validates the token with the
Authorization Server
6) The Resource Server provides the requested content
to the OAuth Client
OAuth
Client
Resource
Owner/Agent/
Native App
OAuth
Resource
Server
OAuth
Authorizatio
n Server
2
3
6
4
1Requesting
Site Resource
Site
Copyright © 2013, Oracle and/or its affiliates. All rights reserved.6
2-Legged OAuth
 The requesting service (OAuth
Client) preregisters with the
OAuth Authorization Server and
receives client credentials
 The requesting service uses its
client credentials to connect to a
resource server
 The Resource server validates
the clients credentials and
provides the requested content
OAuth
Client
OAuth
Resource
Server
OAuth
Authorizati
on Server
2
3
1
Copyright © 2013, Oracle and/or its affiliates. All rights reserved.7
• OAuth allows resource owners to delegate resource access rights to
third-parties.
• No sharing of passwords with third-party apps
• Authorize to certain limited resources
• For a limited time
• Can revoke consent given to the third-party apps
• Where as sharing passwords approach with third-party apps
• Trust issues
• Unwanted level of access
• Not able to revoke etc.
OAuth 2.0 Overview
OAuth 2.0 Authorization Server
Copyright © 2013, Oracle and/or its affiliates. All rights reserved.8
OAuth Workflow
Consumer
(Client)
Service
Provider
(Resource
Server)
User
(Resource
Owner)
Ask for a Token with
OAuth
Responds with un-
Authorized request token
Redirects with
authorized request token
Requests exchange for
access token
Responds with
requested data
Ask for data with access
token
Ask for authorization
of request token
Redirect user to
content Access
page
Log-in and grant
permission
Copyright © 2013, Oracle and/or its affiliates. All rights reserved.9
Using OAuth 2.0 Authorization Code Flow
Copyright © 2013, Oracle and/or its affiliates. All rights reserved.10
OAuth Actors/What is OAuth 2.0?
Client Application
Resource Owner
Resource Server
OAuth Server
Accesses Resources
Login, Gives consent
Issues Tokens
Accesses Resources Data
Delegates Authorization
(e.g. photoprinting.com) (e.g. photos from “photos.com”)
Authenticates, Authorizes
Copyright © 2013, Oracle and/or its affiliates. All rights reserved.11
• Service Provider (Resource Server) the Service Provider controls all aspects of the
OAuth implementation. The Service Provider is the term used to describe the website or web-service where
the restricted resources are located. It can be a photo sharing site where users keep albums, an online
bank service, a micro blogging site, or any other service where ‘user’s private stuff’ is kept. OAuth does not
mandate that the Service Provider will also be the identity provider which means the Service Provider can
use its own usernames and passwords to authenticate users, or use other systems such as OpenID
• User (Resource Owner) the user is why OAuth exists and without users, there is no need for
OAuth. The users have ‘stuff’ they don’t want to make public on the Service Provider, but they do want to
share it with another site. However OAuth can be used with the two-legged scenarios involving clients and
server, without the need of user interaction.
• Consumer (Client) this is a fancy name for an application trying to access the User’s resources.
This can be a website, a desktop program, a mobile device, a set-top box, or anything else connected to the
web.
• Protected Resources the ‘stuff’ OAuth protects and allow access to. This can be data (photos,
documents, contacts etc.), activities (posting blog item, transferring funds) or any URL with a need for
access restrictions.
What is OAuth 2.0?
Copyright © 2013, Oracle and/or its affiliates. All rights reserved.12
 Access Token: Access tokens are credentials used to access protected resources. An
access token is a string representing an authorization issued to the client. The string is usually opaque to the
client. Tokens represent specific scopes and durations of access, granted by the resource owner, and
enforced by the resource server and authorization server.
 Refresh Token: Refresh tokens are credentials used to obtain access tokens. Refresh
tokens are issued to the client by the authorization server and are used to obtain a new access token when
the current access token becomes invalid or expires, or to obtain additional access tokens with identical or
narrower scope (access tokens may have a shorter lifetime and fewer permissions than authorized by the
resource owner).
What is OAuth 2.0?
Copyright © 2013, Oracle and/or its affiliates. All rights reserved.13
OAuth 2.0 Grant Types
• Authorization Code – usually clients running on web server
• Implicit – clients run directly in the browser like Javascript plugins
• Resource Owner – User Id/password of the user
• Client Credentials – client credentials
• Refresh Token – to refresh/get a new access token
• Assertion Framework
•Client Assertion ・(Authorization) Assertion ・Support multiple formats: JWT and SAML
• Extended Grants
•Depends on server and deployment needs
•E.g. for Oracle to support OAM tokens
Copyright © 2013, Oracle and/or its affiliates. All rights reserved.14
Typical 3-legged OAuth flow with Authorization Code
Grant Type
Background
Checker
Client
Resource
Server
Enterprise OAuth
Server
Token-claim registry
Scope registry
Policy store
User consent
orchestration
Get an “Access
token”
Obtain “Authorization
Grant”(User consent)
Use “Access Token” to
access a resource
Copyright © 2013, Oracle and/or its affiliates. All rights reserved.15
Questions
Copyright © 2013, Oracle and/or its affiliates. All rights reserved.16
References & Terminology
1. OAuth 2.0 Spec (Core/Classic) - http://tools.ietf.org/html/rfc6749
2. OAuth 2.0 Assertion Framework Spec - http://tools.ietf.org/html/draft-ietf-
oauth-assertions-11
3. OAuth 2.0 JWT Assertion Profile Spec - http://tools.ietf.org/html/draft-ietf-
oauth-jwt-bearer-05
4. OAuth 2.0でWebサービスの利用方法はどう変わるか
http://www.atmarkit.co.jp/fsmart/articles/oauth2/01.html
5. http://lzhairs.blogspot.jp/2013/09/2-legged-oauth-3-legged-oauth.html
Copyright © 2013, Oracle and/or its affiliates. All rights reserved.17
Copyright © 2013, Oracle and/or its affiliates. All rights reserved.18

More Related Content

What's hot (20)

PPTX
An Introduction to OAuth2
Aaron Parecki
 
PPTX
OAuth 2
ChrisWood262
 
PDF
OAuth 2.0 and OpenID Connect
Jacob Combs
 
PDF
Demystifying OAuth 2.0
Karl McGuinness
 
PPTX
API Security : Patterns and Practices
Prabath Siriwardena
 
PDF
Implementing OAuth
leahculver
 
PPTX
Radius server,PAP and CHAP Protocols
Dhananjay Aloorkar
 
PDF
OWASP Top 10 Web Application Vulnerabilities
Software Guru
 
PDF
REST API Authentication Methods.pdf
Rubersy Ramos García
 
PDF
Hacking and Defending APIs - Red and Blue make Purple.pdf
Matt Tesauro
 
PDF
OAuth 2.0
Uwe Friedrichsen
 
PPTX
LDAP - Lightweight Directory Access Protocol
S. Hasnain Raza
 
PPTX
Introduction to REST - API
Chetan Gadodia
 
PDF
Spring security oauth2
axykim00
 
PPTX
A2 - broken authentication and session management(OWASP thailand chapter Apri...
Noppadol Songsakaew
 
PDF
Jwt Security
Seid Yassin
 
PDF
Api security-testing
n|u - The Open Security Community
 
PPT
Understanding REST
Nitin Pande
 
An Introduction to OAuth2
Aaron Parecki
 
OAuth 2
ChrisWood262
 
OAuth 2.0 and OpenID Connect
Jacob Combs
 
Demystifying OAuth 2.0
Karl McGuinness
 
API Security : Patterns and Practices
Prabath Siriwardena
 
Implementing OAuth
leahculver
 
Radius server,PAP and CHAP Protocols
Dhananjay Aloorkar
 
OWASP Top 10 Web Application Vulnerabilities
Software Guru
 
REST API Authentication Methods.pdf
Rubersy Ramos García
 
Hacking and Defending APIs - Red and Blue make Purple.pdf
Matt Tesauro
 
OAuth 2.0
Uwe Friedrichsen
 
LDAP - Lightweight Directory Access Protocol
S. Hasnain Raza
 
Introduction to REST - API
Chetan Gadodia
 
Spring security oauth2
axykim00
 
A2 - broken authentication and session management(OWASP thailand chapter Apri...
Noppadol Songsakaew
 
Jwt Security
Seid Yassin
 
Api security-testing
n|u - The Open Security Community
 
Understanding REST
Nitin Pande
 

Viewers also liked (20)

PPTX
Beveiliging en REST services
Maurice De Beijer [MVP]
 
PDF
Managing Identity by Giving Up Control - Scott Morrison, SVP & Distinguished ...
CA API Management
 
PPTX
OAuth 2.0 and Mobile Devices: Is that a token in your phone in your pocket or...
Brian Campbell
 
PDF
04 june meetup - An overview of OAuth2 on Force.com projects
Aldo Fernandez
 
PDF
Auth in the extended enterprise - Keynote for MIT Legal Hack A Thon 2013
Justin Richer
 
PDF
Transforming organizations into platforms
Twobo Technologies
 
PDF
Synergies of Cloud Identity: Putting it All Together
Twobo Technologies
 
PDF
Designing an API
Twobo Technologies
 
PPTX
Incorporating OAuth
Twobo Technologies
 
PDF
Nordic APIs - Integrated Social Solutions for a Cloudy, Mobile World
Twobo Technologies
 
PDF
#dd12 OAuth for Domino Developers
Dominopoint - Italian Lotus User Group
 
PPTX
Introduction to the Emerging JSON-Based Identity and Security Protocols
Brian Campbell
 
PDF
SCIM presentation from CIS 2012
Twobo Technologies
 
PDF
Twobo LDAP Attribute Store for ADFS
Twobo Technologies
 
PDF
Neo-security Stack
Twobo Technologies
 
PPTX
The JSON-based Identity Protocol Suite
Twobo Technologies
 
PPTX
Principles and patterns for test driven development
Stephen Fuqua
 
PPTX
Postman Collection Format v2.0 (pre-draft)
Postman
 
PDF
Modern Security with OAuth 2.0 and JWT and Spring by Dmitry Buzdin
Java User Group Latvia
 
PDF
JavaOne 2014 - Securing RESTful Resources with OAuth2
Rodrigo Cândido da Silva
 
Beveiliging en REST services
Maurice De Beijer [MVP]
 
Managing Identity by Giving Up Control - Scott Morrison, SVP & Distinguished ...
CA API Management
 
OAuth 2.0 and Mobile Devices: Is that a token in your phone in your pocket or...
Brian Campbell
 
04 june meetup - An overview of OAuth2 on Force.com projects
Aldo Fernandez
 
Auth in the extended enterprise - Keynote for MIT Legal Hack A Thon 2013
Justin Richer
 
Transforming organizations into platforms
Twobo Technologies
 
Synergies of Cloud Identity: Putting it All Together
Twobo Technologies
 
Designing an API
Twobo Technologies
 
Incorporating OAuth
Twobo Technologies
 
Nordic APIs - Integrated Social Solutions for a Cloudy, Mobile World
Twobo Technologies
 
#dd12 OAuth for Domino Developers
Dominopoint - Italian Lotus User Group
 
Introduction to the Emerging JSON-Based Identity and Security Protocols
Brian Campbell
 
SCIM presentation from CIS 2012
Twobo Technologies
 
Twobo LDAP Attribute Store for ADFS
Twobo Technologies
 
Neo-security Stack
Twobo Technologies
 
The JSON-based Identity Protocol Suite
Twobo Technologies
 
Principles and patterns for test driven development
Stephen Fuqua
 
Postman Collection Format v2.0 (pre-draft)
Postman
 
Modern Security with OAuth 2.0 and JWT and Spring by Dmitry Buzdin
Java User Group Latvia
 
JavaOne 2014 - Securing RESTful Resources with OAuth2
Rodrigo Cândido da Silva
 
Ad

Similar to Introduction to OAuth2.0 (20)

PPTX
Oauth2 and OWSM OAuth2 support
Gaurav Sharma
 
PPTX
OAuth2 Implementation Presentation (Java)
Knoldus Inc.
 
PPTX
OAuth 2.0 - The fundamentals, the good , the bad, technical primer and commo...
Good Dog Labs, Inc.
 
PDF
Introduction to OAuth
Wei-Tsung Su
 
PDF
OAuth2
SPARK MEDIA
 
PDF
Spring Security
Knoldus Inc.
 
PPT
Oauth2.0
Yasmine Gaber
 
PDF
Stateless Auth using OAuth2 & JWT
Gaurav Roy
 
PPTX
OAuth
Tom Elrod
 
PDF
A technical insight into the concepts and terminologies behind oauth – an ope...
eSAT Journals
 
PDF
CIS13: Bootcamp: Ping Identity OAuth and OpenID Connect In Action with PingFe...
CloudIDSummit
 
PDF
CIS13: Introduction to OAuth 2.0
CloudIDSummit
 
PPTX
OAuth
Adi Challa
 
PPTX
Intro to OAuth2 and OpenID Connect
LiamWadman
 
PDF
Survey on Restful Web Services Using Open Authorization (Oauth)I01545356
IOSR Journals
 
PDF
A Survey on SSO Authentication protocols: Security and Performance
Amin Saqi
 
PPTX
OAuth2 Introduction
Arpit Suthar
 
PDF
API Security with OAuth2.0.
Kellton Tech Solutions Ltd
 
PDF
Rfc5849aut
Vishal Shah
 
PDF
Twitter Authentication
Vishal Shah
 
Oauth2 and OWSM OAuth2 support
Gaurav Sharma
 
OAuth2 Implementation Presentation (Java)
Knoldus Inc.
 
OAuth 2.0 - The fundamentals, the good , the bad, technical primer and commo...
Good Dog Labs, Inc.
 
Introduction to OAuth
Wei-Tsung Su
 
OAuth2
SPARK MEDIA
 
Spring Security
Knoldus Inc.
 
Oauth2.0
Yasmine Gaber
 
Stateless Auth using OAuth2 & JWT
Gaurav Roy
 
OAuth
Tom Elrod
 
A technical insight into the concepts and terminologies behind oauth – an ope...
eSAT Journals
 
CIS13: Bootcamp: Ping Identity OAuth and OpenID Connect In Action with PingFe...
CloudIDSummit
 
CIS13: Introduction to OAuth 2.0
CloudIDSummit
 
OAuth
Adi Challa
 
Intro to OAuth2 and OpenID Connect
LiamWadman
 
Survey on Restful Web Services Using Open Authorization (Oauth)I01545356
IOSR Journals
 
A Survey on SSO Authentication protocols: Security and Performance
Amin Saqi
 
OAuth2 Introduction
Arpit Suthar
 
API Security with OAuth2.0.
Kellton Tech Solutions Ltd
 
Rfc5849aut
Vishal Shah
 
Twitter Authentication
Vishal Shah
 
Ad

Recently uploaded (20)

PPTX
Iván Bornacelly - Presentation of the report - Empowering the workforce in th...
EduSkills OECD
 
PPTX
Marketing Management PPT Unit 1 and Unit 2.pptx
Sri Ramakrishna College of Arts and science
 
PPTX
PLANNING A HOSPITAL AND NURSING UNIT.pptx
PRADEEP ABOTHU
 
PPTX
How to Manage Wins & Losses in Odoo 18 CRM
Celine George
 
PDF
Wikinomics How Mass Collaboration Changes Everything Don Tapscott
wcsqyzf5909
 
PDF
IMPORTANT GUIDELINES FOR M.Sc.ZOOLOGY DISSERTATION
raviralanaresh2
 
PDF
Our Guide to the July 2025 USPS® Rate Change
Postal Advocate Inc.
 
PPTX
Natural Language processing using nltk.pptx
Ramakrishna Reddy Bijjam
 
PPTX
Building Powerful Agentic AI with Google ADK, MCP, RAG, and Ollama.pptx
Tamanna36
 
PPTX
grade 8 week 2 ict.pptx. matatag grade 7
VanessaTaberlo
 
PDF
COM and NET Component Services 1st Edition Juval Löwy
kboqcyuw976
 
PDF
Genomics Proteomics and Vaccines 1st Edition Guido Grandi (Editor)
kboqcyuw976
 
PPTX
Elo the Hero is an story about a young boy who became hero.
TeacherEmily1
 
PDF
Quiz Night Live May 2025 - Intra Pragya Online General Quiz
Pragya - UEM Kolkata Quiz Club
 
PDF
I3PM Industry Case Study Siemens on Strategic and Value-Oriented IP Management
MIPLM
 
PDF
Lean IP - Lecture by Dr Oliver Baldus at the MIPLM 2025
MIPLM
 
PDF
AI-assisted IP-Design lecture from the MIPLM 2025
MIPLM
 
PDF
WATERSHED MANAGEMENT CASE STUDIES - ULUGURU MOUNTAINS AND ARVARI RIVERpdf
Ar.Asna
 
PDF
TLE 8 QUARTER 1 MODULE WEEK 1 MATATAG CURRICULUM
denniseraya1997
 
PDF
Lesson 1 - Nature of Inquiry and Research.pdf
marvinnbustamante1
 
Iván Bornacelly - Presentation of the report - Empowering the workforce in th...
EduSkills OECD
 
Marketing Management PPT Unit 1 and Unit 2.pptx
Sri Ramakrishna College of Arts and science
 
PLANNING A HOSPITAL AND NURSING UNIT.pptx
PRADEEP ABOTHU
 
How to Manage Wins & Losses in Odoo 18 CRM
Celine George
 
Wikinomics How Mass Collaboration Changes Everything Don Tapscott
wcsqyzf5909
 
IMPORTANT GUIDELINES FOR M.Sc.ZOOLOGY DISSERTATION
raviralanaresh2
 
Our Guide to the July 2025 USPS® Rate Change
Postal Advocate Inc.
 
Natural Language processing using nltk.pptx
Ramakrishna Reddy Bijjam
 
Building Powerful Agentic AI with Google ADK, MCP, RAG, and Ollama.pptx
Tamanna36
 
grade 8 week 2 ict.pptx. matatag grade 7
VanessaTaberlo
 
COM and NET Component Services 1st Edition Juval Löwy
kboqcyuw976
 
Genomics Proteomics and Vaccines 1st Edition Guido Grandi (Editor)
kboqcyuw976
 
Elo the Hero is an story about a young boy who became hero.
TeacherEmily1
 
Quiz Night Live May 2025 - Intra Pragya Online General Quiz
Pragya - UEM Kolkata Quiz Club
 
I3PM Industry Case Study Siemens on Strategic and Value-Oriented IP Management
MIPLM
 
Lean IP - Lecture by Dr Oliver Baldus at the MIPLM 2025
MIPLM
 
AI-assisted IP-Design lecture from the MIPLM 2025
MIPLM
 
WATERSHED MANAGEMENT CASE STUDIES - ULUGURU MOUNTAINS AND ARVARI RIVERpdf
Ar.Asna
 
TLE 8 QUARTER 1 MODULE WEEK 1 MATATAG CURRICULUM
denniseraya1997
 
Lesson 1 - Nature of Inquiry and Research.pdf
marvinnbustamante1
 

Introduction to OAuth2.0

  • 1. Copyright © 2013, Oracle and/or its affiliates. All rights reserved.1 OAuth 2.0 Overview Oracle Asia Research and Development Center Alice Liu([email protected])
  • 2. Copyright © 2013, Oracle and/or its affiliates. All rights reserved.2  OAuth 2.0 Overview  3-Legged OAuth/ 2-Legged Oauth  OAuth Workflow
  • 3. Copyright © 2013, Oracle and/or its affiliates. All rights reserved.3  OAuth Terms – Client is an application accessing an API, can be a web app, app inside a user agent, or a native app – Resource Owner is a “user” who can authorize/grant access to API resources – Resource Server is the API host – Authorization Server is the authorization PDP and STS  OAuth 2.0 is relatively simple – Get the token – Use the token to access the protected resource OAuth 2.0 Overview OAuth 2.0 Authorization Server
  • 4. Copyright © 2013, Oracle and/or its affiliates. All rights reserved.4  In the traditional client-server authentication model, the client accesses a protected resource on the server by authenticating with the server using the resource owner's credentials. In order to provide third-party applications access to protected resources, the resource owner shares its credentials with the third- party. This creates several problems and limitations.  Third-party applications are required to store the resource-owner's credentials for future use, typically a password in clear-text.  Servers are required to support password authentication, despite the security weaknesses created by passwords.  Third-party applications gain overly broad access to the resource-owner's protected resources, leaving resource owners without any ability to restrict duration or access to a limited subset of resources.  Resource owners cannot revoke access to an individual third-party without revoking access to all third- parties, and must do so by changing their password. OAuth 2.0 Overview OAuth 2.0 Authorization Server
  • 5. Copyright © 2013, Oracle and/or its affiliates. All rights reserved.5 3-Legged OAuth 1) The resource owner connects to an OAuth Client enabled service and requests it access resources at a different site 2) The OAuth Client (requesting site) redirects the user to the OAuth Authorization Server, which authenticates the user and presents a consent page. It then sends authorization code to the OAuth client 3) The OAuth Client uses the authorization code to retrieve an OAuth Access Token from the OAuth Authorization Server 4) The OAuth Client presents the Access Token to the OAuth Resource Server 5) The Resource Server validates the token with the Authorization Server 6) The Resource Server provides the requested content to the OAuth Client OAuth Client Resource Owner/Agent/ Native App OAuth Resource Server OAuth Authorizatio n Server 2 3 6 4 1Requesting Site Resource Site
  • 6. Copyright © 2013, Oracle and/or its affiliates. All rights reserved.6 2-Legged OAuth  The requesting service (OAuth Client) preregisters with the OAuth Authorization Server and receives client credentials  The requesting service uses its client credentials to connect to a resource server  The Resource server validates the clients credentials and provides the requested content OAuth Client OAuth Resource Server OAuth Authorizati on Server 2 3 1
  • 7. Copyright © 2013, Oracle and/or its affiliates. All rights reserved.7 • OAuth allows resource owners to delegate resource access rights to third-parties. • No sharing of passwords with third-party apps • Authorize to certain limited resources • For a limited time • Can revoke consent given to the third-party apps • Where as sharing passwords approach with third-party apps • Trust issues • Unwanted level of access • Not able to revoke etc. OAuth 2.0 Overview OAuth 2.0 Authorization Server
  • 8. Copyright © 2013, Oracle and/or its affiliates. All rights reserved.8 OAuth Workflow Consumer (Client) Service Provider (Resource Server) User (Resource Owner) Ask for a Token with OAuth Responds with un- Authorized request token Redirects with authorized request token Requests exchange for access token Responds with requested data Ask for data with access token Ask for authorization of request token Redirect user to content Access page Log-in and grant permission
  • 9. Copyright © 2013, Oracle and/or its affiliates. All rights reserved.9 Using OAuth 2.0 Authorization Code Flow
  • 10. Copyright © 2013, Oracle and/or its affiliates. All rights reserved.10 OAuth Actors/What is OAuth 2.0? Client Application Resource Owner Resource Server OAuth Server Accesses Resources Login, Gives consent Issues Tokens Accesses Resources Data Delegates Authorization (e.g. photoprinting.com) (e.g. photos from “photos.com”) Authenticates, Authorizes
  • 11. Copyright © 2013, Oracle and/or its affiliates. All rights reserved.11 • Service Provider (Resource Server) the Service Provider controls all aspects of the OAuth implementation. The Service Provider is the term used to describe the website or web-service where the restricted resources are located. It can be a photo sharing site where users keep albums, an online bank service, a micro blogging site, or any other service where ‘user’s private stuff’ is kept. OAuth does not mandate that the Service Provider will also be the identity provider which means the Service Provider can use its own usernames and passwords to authenticate users, or use other systems such as OpenID • User (Resource Owner) the user is why OAuth exists and without users, there is no need for OAuth. The users have ‘stuff’ they don’t want to make public on the Service Provider, but they do want to share it with another site. However OAuth can be used with the two-legged scenarios involving clients and server, without the need of user interaction. • Consumer (Client) this is a fancy name for an application trying to access the User’s resources. This can be a website, a desktop program, a mobile device, a set-top box, or anything else connected to the web. • Protected Resources the ‘stuff’ OAuth protects and allow access to. This can be data (photos, documents, contacts etc.), activities (posting blog item, transferring funds) or any URL with a need for access restrictions. What is OAuth 2.0?
  • 12. Copyright © 2013, Oracle and/or its affiliates. All rights reserved.12  Access Token: Access tokens are credentials used to access protected resources. An access token is a string representing an authorization issued to the client. The string is usually opaque to the client. Tokens represent specific scopes and durations of access, granted by the resource owner, and enforced by the resource server and authorization server.  Refresh Token: Refresh tokens are credentials used to obtain access tokens. Refresh tokens are issued to the client by the authorization server and are used to obtain a new access token when the current access token becomes invalid or expires, or to obtain additional access tokens with identical or narrower scope (access tokens may have a shorter lifetime and fewer permissions than authorized by the resource owner). What is OAuth 2.0?
  • 13. Copyright © 2013, Oracle and/or its affiliates. All rights reserved.13 OAuth 2.0 Grant Types • Authorization Code – usually clients running on web server • Implicit – clients run directly in the browser like Javascript plugins • Resource Owner – User Id/password of the user • Client Credentials – client credentials • Refresh Token – to refresh/get a new access token • Assertion Framework •Client Assertion ・(Authorization) Assertion ・Support multiple formats: JWT and SAML • Extended Grants •Depends on server and deployment needs •E.g. for Oracle to support OAM tokens
  • 14. Copyright © 2013, Oracle and/or its affiliates. All rights reserved.14 Typical 3-legged OAuth flow with Authorization Code Grant Type Background Checker Client Resource Server Enterprise OAuth Server Token-claim registry Scope registry Policy store User consent orchestration Get an “Access token” Obtain “Authorization Grant”(User consent) Use “Access Token” to access a resource
  • 15. Copyright © 2013, Oracle and/or its affiliates. All rights reserved.15 Questions
  • 16. Copyright © 2013, Oracle and/or its affiliates. All rights reserved.16 References & Terminology 1. OAuth 2.0 Spec (Core/Classic) - http://tools.ietf.org/html/rfc6749 2. OAuth 2.0 Assertion Framework Spec - http://tools.ietf.org/html/draft-ietf- oauth-assertions-11 3. OAuth 2.0 JWT Assertion Profile Spec - http://tools.ietf.org/html/draft-ietf- oauth-jwt-bearer-05 4. OAuth 2.0でWebサービスの利用方法はどう変わるか http://www.atmarkit.co.jp/fsmart/articles/oauth2/01.html 5. http://lzhairs.blogspot.jp/2013/09/2-legged-oauth-3-legged-oauth.html
  • 17. Copyright © 2013, Oracle and/or its affiliates. All rights reserved.17
  • 18. Copyright © 2013, Oracle and/or its affiliates. All rights reserved.18