SlideShare a Scribd company logo
@nabeelxy
10/26/2014
Wouldn’t it be cool when I
tweet, it automatically gets
posted in my FB wall?
Tweet
Bob Twitter App
Automatically post in
Bob’s FB wall
How does the Twitter App writes in
Bob’s FB wall? I mean how does it get
write access to Bob’s FB wall?
Tom, Twitter App Manager
Jim, Twitter App Dev
Let’s store Bob’s FB username
and password in his Twitter
App account. Then the app
can login and post in his FB
wall. The problem solved!
It works. But it is not a good idea
to store username and password
as it involves a lot of risks.
Besides, Bob won’t like to give his
username/password to our app
considering the fact that it take a
while for users to trust our app.
Jill, App Dev
I totally agree. This is actually
called Password Anti-Pattern!
At all cost, we should avoid it.
Sam, App Dev
We get more access than we want
with username/password as well.
Users will not like it. Further, this
is bad from the point of view of
liability when things go wrong.
Sam, App Dev
Further, if users change
their FB password, it
breaks our app.
If users want to stop cross
posting in FB, they will always
have to come to our app or
change their FB password.
Alright, asking for username and
password is not good for Bob as well as
us. So, what can we do about it?
Tom, Twitter App Manager
Basically the problem is that we need a
way for our users to give us write
authorization to their FB walls?
Ali, App Dev
I was thinking that this problem is
strikingly similar to the valet parking
situation. I want to get my new car valet
parked but I am at the same time hesitant
to give my car key to them.
The car industry came with this idea of valet
keys that has limited capabilities. For example,
that valet key allows to drive a car only a short
distance and most of the add-on functions in
the car are disabled for that special key.
So, now I can give my valet key (instead of
the original key) to valet park without
worrying too much about it.
So, this sounds like a valet key
would map to a short-lived token
just like those in Kerberos
protocol, even though Kerberos is
for authentication?
Jim, Twitter App Dev
Yes, indeed. There is in fact a
token based delegated
authorization mechanism
called OAuth.
Good news is that FB
is actually supporting
OAuth for such
access.
Sam, App Dev
OAuth sounds great. Sam, could you
give us some details of it?
Tom, Twitter App Manager Sam, App Dev
Sure.
 Password Anti-Pattern
 Give resource owner’s username and password to client
in order to access the resource server on behalf of the
resource owner
 Dangers of using this pattern
 Expanded access and risk (exposure of
username/password to third-party client)
 Limited reliability when passwords are changed
 Revocation challenges
 First Solutions
 Google’s AuthSub
 Yahoo’s BBAuth
 A delegated authorization protocol
 Provides the ability for these applications to access a
user’s data securely, without requiring the user to take
the scary step of handing over an account password
 Introduced in 2007
 Increased developer experience and increased
confidence in security due to a common protocol for
handling API authorization
 Not backward compatible with OAuth 1.0
 New flows
 Signatures are replaced by HTTPS (bearer tokens)
 Simplified signatures
 Short-lived tokens
 Separation of roles for authorization server and
resource server
 Resource server
 The server that hosts user owned resources protected by
OAuth
 An API provider such as Google, Facebook, etc.
 Resource owner
 An application user
 Has the ability to grant access to their own data hosted on a
resource server
 Client
 An application making API calls to perform certain action on
protected resources on behalf of the resource owner with
resource owner’s authorization
 Authentication server
 Often, it is same as the resource server
Tweet
Bob Twitter App
Automatically post in
Bob’s FB wall
CLIENT
RESOURCE SERVER
RESOURCE OWNER
AUTHORIZATION SERVER
 Server-side web application
 Client side web application running in the web
browser
 Native application
 Authorization code
 For apps with backend servers
 Implicit grant for browser based client side
applications (no backend server)
 Resource owner password based grants
 Only for very trusted applications (usually for first-party
applications only)
 Client credentials
 For application access (i.e. client is an application)
 Authorization flow sequence diagrams
 Implementing authorization code flow
 OAuth for mobile applications
 Getting Started with OAuth 2.0

More Related Content

PDF
Introduction to OAuth 2.0 - Part 1
PDF
Introduction to OAuth 2.0 - Part 2
ODP
Technology / Open Source @ Creative Commons (CC Salon SF, August 2009)
PPT
External Data Access with jQuery
PDF
Bot Framework with Xamarin Forms
PDF
What is REST API? REST API Concepts and Examples | Edureka
PPTX
DirectLineAPI - Xamarin.Forms App and Bot Framework Integration
PPTX
Introduction to OAuth 2.0 - the technology you need but never really learned
Introduction to OAuth 2.0 - Part 1
Introduction to OAuth 2.0 - Part 2
Technology / Open Source @ Creative Commons (CC Salon SF, August 2009)
External Data Access with jQuery
Bot Framework with Xamarin Forms
What is REST API? REST API Concepts and Examples | Edureka
DirectLineAPI - Xamarin.Forms App and Bot Framework Integration
Introduction to OAuth 2.0 - the technology you need but never really learned

What's hot (20)

PDF
OAuth big picture
KEY
OAuth using PHP5
PDF
OAuth for your API - The Big Picture
PPTX
Introduction to OAuth
PPT
Oauth2.0
PPTX
Integrating External APIs with WordPress
PDF
Integrating WordPress With Web APIs
PPTX
PPTX
Using ArcGIS with OAuth 2.0 - Esri DevSummit Dubai 2013
PDF
A How-to Guide to OAuth & API Security
PPTX
The State of OAuth2
ODP
Mohanraj - Securing Your Web Api With OAuth
PPTX
Being A Salesforce Jedi
PDF
Implementing OAuth with PHP
PDF
OAuth2 and LinkedIn
PDF
Social Connections VI Prague - An introduction to ibm connections as an appde...
KEY
LinkedIn OAuth: Zero To Hero
PPTX
Nom Nom: Consuming REST APIs
PDF
A 4 line login - line platform
PPTX
Consuming & embedding external content in WordPress
OAuth big picture
OAuth using PHP5
OAuth for your API - The Big Picture
Introduction to OAuth
Oauth2.0
Integrating External APIs with WordPress
Integrating WordPress With Web APIs
Using ArcGIS with OAuth 2.0 - Esri DevSummit Dubai 2013
A How-to Guide to OAuth & API Security
The State of OAuth2
Mohanraj - Securing Your Web Api With OAuth
Being A Salesforce Jedi
Implementing OAuth with PHP
OAuth2 and LinkedIn
Social Connections VI Prague - An introduction to ibm connections as an appde...
LinkedIn OAuth: Zero To Hero
Nom Nom: Consuming REST APIs
A 4 line login - line platform
Consuming & embedding external content in WordPress
Ad

Viewers also liked (20)

PPT
Oracle Transparent Data Encryption (TDE) 12c
KEY
OAuth Introduction
ZIP
OAuth
PDF
Monage.io identity presentation 3.22.17 v3
PPTX
Securing the modern data centre
PPTX
Securing IaaS Applications
PPT
OAuth 2.0 and OpenId Connect
PDF
OAuth 2.0 & OpenID Connect @ OpenSource Conference 2011 Tokyo #osc11tk
PPTX
Deep Dive DMG (september update)
PPTX
Authorization for Internet of Things using OAuth 2.0
PDF
'Embedding' a meta state machine
PDF
The Future is Now: The ForgeRock Identity Platform, Early 2017 Release
PDF
Modern Security with OAuth 2.0 and JWT and Spring by Dmitry Buzdin
PDF
NFV SDN for carriers
PPTX
NIC 2017 Azure AD Identity Protection and Conditional Access: Using the Micro...
PDF
Java secure development part 1
PPTX
OpenID Connect - a simple[sic] single sign-on & identity layer on top of OAut...
PDF
OpenID Connect Explained
PPT
Introduction to Tokenization
PDF
OAuth - Open API Authentication
Oracle Transparent Data Encryption (TDE) 12c
OAuth Introduction
OAuth
Monage.io identity presentation 3.22.17 v3
Securing the modern data centre
Securing IaaS Applications
OAuth 2.0 and OpenId Connect
OAuth 2.0 & OpenID Connect @ OpenSource Conference 2011 Tokyo #osc11tk
Deep Dive DMG (september update)
Authorization for Internet of Things using OAuth 2.0
'Embedding' a meta state machine
The Future is Now: The ForgeRock Identity Platform, Early 2017 Release
Modern Security with OAuth 2.0 and JWT and Spring by Dmitry Buzdin
NFV SDN for carriers
NIC 2017 Azure AD Identity Protection and Conditional Access: Using the Micro...
Java secure development part 1
OpenID Connect - a simple[sic] single sign-on & identity layer on top of OAut...
OpenID Connect Explained
Introduction to Tokenization
OAuth - Open API Authentication
Ad

Similar to Introduction to OAuth 2.0 - Part 1 (20)

PPTX
Oauth2 and OWSM OAuth2 support
PDF
1000 ways to die in mobile oauth
PPTX
Devteach 2017 OAuth and Open id connect demystified
KEY
OAuth Android Göteborg
PPTX
OAuth
PPTX
OAuth
PPTX
OAuth 2.0
PDF
OAuth and why you should use it
PDF
OAuth Hacks A gentle introduction to OAuth 2 and Apache Oltu
PPTX
An Introduction to OAuth2
PPTX
OAuth2 + API Security
PDF
Saadhvi Summit - oAuth Standards
PDF
Stateless token-based authentication for pure front-end applications
PPTX
Api security
PDF
De la bonne utilisation de OAuth2
PPTX
O auth 2.0 authorization framework
PDF
Keeping Pace with OAuth’s Evolving Security Practices.pdf
PDF
OAuth 1.0
PDF
Securing APIs with OAuth 2.0
PDF
The Current State of OAuth 2
Oauth2 and OWSM OAuth2 support
1000 ways to die in mobile oauth
Devteach 2017 OAuth and Open id connect demystified
OAuth Android Göteborg
OAuth
OAuth
OAuth 2.0
OAuth and why you should use it
OAuth Hacks A gentle introduction to OAuth 2 and Apache Oltu
An Introduction to OAuth2
OAuth2 + API Security
Saadhvi Summit - oAuth Standards
Stateless token-based authentication for pure front-end applications
Api security
De la bonne utilisation de OAuth2
O auth 2.0 authorization framework
Keeping Pace with OAuth’s Evolving Security Practices.pdf
OAuth 1.0
Securing APIs with OAuth 2.0
The Current State of OAuth 2

More from Nabeel Yoosuf (8)

PDF
Building RESTful Applications
PPT
API Façade Pattern
PDF
Privacy Preserving Access Control for Third Party Data Management Systems
PDF
Efficient privacy preserving publish subscribe systems
PDF
Access Control: Principles and Practice
PDF
Efficient Filtering in Pub-Sub Systems using BDD
PDF
Pub-Sub Systems and Confidentiality/Privacy
PDF
A Structure Preserving Approach for Securing XML Documents
Building RESTful Applications
API Façade Pattern
Privacy Preserving Access Control for Third Party Data Management Systems
Efficient privacy preserving publish subscribe systems
Access Control: Principles and Practice
Efficient Filtering in Pub-Sub Systems using BDD
Pub-Sub Systems and Confidentiality/Privacy
A Structure Preserving Approach for Securing XML Documents

Recently uploaded (20)

PDF
Machine learning based COVID-19 study performance prediction
PPTX
Big Data Technologies - Introduction.pptx
PDF
Unlocking AI with Model Context Protocol (MCP)
PDF
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...
PDF
Spectral efficient network and resource selection model in 5G networks
PDF
The Rise and Fall of 3GPP – Time for a Sabbatical?
PPTX
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
PDF
Review of recent advances in non-invasive hemoglobin estimation
PDF
Mobile App Security Testing_ A Comprehensive Guide.pdf
PDF
Profit Center Accounting in SAP S/4HANA, S4F28 Col11
PDF
cuic standard and advanced reporting.pdf
PPTX
sap open course for s4hana steps from ECC to s4
PDF
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
PDF
Electronic commerce courselecture one. Pdf
PDF
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
PDF
Encapsulation_ Review paper, used for researhc scholars
PDF
Encapsulation theory and applications.pdf
PDF
How UI/UX Design Impacts User Retention in Mobile Apps.pdf
PDF
Reach Out and Touch Someone: Haptics and Empathic Computing
PDF
Optimiser vos workloads AI/ML sur Amazon EC2 et AWS Graviton
Machine learning based COVID-19 study performance prediction
Big Data Technologies - Introduction.pptx
Unlocking AI with Model Context Protocol (MCP)
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...
Spectral efficient network and resource selection model in 5G networks
The Rise and Fall of 3GPP – Time for a Sabbatical?
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
Review of recent advances in non-invasive hemoglobin estimation
Mobile App Security Testing_ A Comprehensive Guide.pdf
Profit Center Accounting in SAP S/4HANA, S4F28 Col11
cuic standard and advanced reporting.pdf
sap open course for s4hana steps from ECC to s4
Blue Purple Modern Animated Computer Science Presentation.pdf.pdf
Electronic commerce courselecture one. Pdf
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
Encapsulation_ Review paper, used for researhc scholars
Encapsulation theory and applications.pdf
How UI/UX Design Impacts User Retention in Mobile Apps.pdf
Reach Out and Touch Someone: Haptics and Empathic Computing
Optimiser vos workloads AI/ML sur Amazon EC2 et AWS Graviton

Introduction to OAuth 2.0 - Part 1

  • 2. Wouldn’t it be cool when I tweet, it automatically gets posted in my FB wall? Tweet Bob Twitter App Automatically post in Bob’s FB wall
  • 3. How does the Twitter App writes in Bob’s FB wall? I mean how does it get write access to Bob’s FB wall? Tom, Twitter App Manager Jim, Twitter App Dev Let’s store Bob’s FB username and password in his Twitter App account. Then the app can login and post in his FB wall. The problem solved!
  • 4. It works. But it is not a good idea to store username and password as it involves a lot of risks. Besides, Bob won’t like to give his username/password to our app considering the fact that it take a while for users to trust our app. Jill, App Dev I totally agree. This is actually called Password Anti-Pattern! At all cost, we should avoid it. Sam, App Dev
  • 5. We get more access than we want with username/password as well. Users will not like it. Further, this is bad from the point of view of liability when things go wrong. Sam, App Dev Further, if users change their FB password, it breaks our app. If users want to stop cross posting in FB, they will always have to come to our app or change their FB password.
  • 6. Alright, asking for username and password is not good for Bob as well as us. So, what can we do about it? Tom, Twitter App Manager Basically the problem is that we need a way for our users to give us write authorization to their FB walls?
  • 7. Ali, App Dev I was thinking that this problem is strikingly similar to the valet parking situation. I want to get my new car valet parked but I am at the same time hesitant to give my car key to them. The car industry came with this idea of valet keys that has limited capabilities. For example, that valet key allows to drive a car only a short distance and most of the add-on functions in the car are disabled for that special key. So, now I can give my valet key (instead of the original key) to valet park without worrying too much about it.
  • 8. So, this sounds like a valet key would map to a short-lived token just like those in Kerberos protocol, even though Kerberos is for authentication? Jim, Twitter App Dev Yes, indeed. There is in fact a token based delegated authorization mechanism called OAuth. Good news is that FB is actually supporting OAuth for such access. Sam, App Dev
  • 9. OAuth sounds great. Sam, could you give us some details of it? Tom, Twitter App Manager Sam, App Dev Sure.
  • 10.  Password Anti-Pattern  Give resource owner’s username and password to client in order to access the resource server on behalf of the resource owner  Dangers of using this pattern  Expanded access and risk (exposure of username/password to third-party client)  Limited reliability when passwords are changed  Revocation challenges  First Solutions  Google’s AuthSub  Yahoo’s BBAuth
  • 11.  A delegated authorization protocol  Provides the ability for these applications to access a user’s data securely, without requiring the user to take the scary step of handing over an account password  Introduced in 2007  Increased developer experience and increased confidence in security due to a common protocol for handling API authorization
  • 12.  Not backward compatible with OAuth 1.0  New flows  Signatures are replaced by HTTPS (bearer tokens)  Simplified signatures  Short-lived tokens  Separation of roles for authorization server and resource server
  • 13.  Resource server  The server that hosts user owned resources protected by OAuth  An API provider such as Google, Facebook, etc.  Resource owner  An application user  Has the ability to grant access to their own data hosted on a resource server  Client  An application making API calls to perform certain action on protected resources on behalf of the resource owner with resource owner’s authorization  Authentication server  Often, it is same as the resource server
  • 14. Tweet Bob Twitter App Automatically post in Bob’s FB wall CLIENT RESOURCE SERVER RESOURCE OWNER AUTHORIZATION SERVER
  • 15.  Server-side web application  Client side web application running in the web browser  Native application
  • 16.  Authorization code  For apps with backend servers  Implicit grant for browser based client side applications (no backend server)  Resource owner password based grants  Only for very trusted applications (usually for first-party applications only)  Client credentials  For application access (i.e. client is an application)
  • 17.  Authorization flow sequence diagrams  Implementing authorization code flow  OAuth for mobile applications
  • 18.  Getting Started with OAuth 2.0

Editor's Notes

  • #13: http://hueniverse.com/2010/05/15/introducing-oauth-2-0/ When OAuth 1.0 was developed in 2007, it was decided that cryptographic signatures were necessary to support the security of APIs. At the time, many top API providers hosted their APIs at vanilla HTTP endpoints, without SSL/TLS protection. Over the years, SSL/TLS became a more common way of protecting APIs and the need for signatures decreased in the eyes of some members of the security community. In Oauth 2.0 - transition: Signature  HTTPS Combining the perception of low API adoption due to the complexity of cryptography in OAuth 1.0 and the greater prevalence of SSL/TLS support for APIs led to the development of the OAuth Web Resource Authorization Profiles (WRAP) specification. OAuth WRAP is the predecessor to OAuth 2.0—it eliminated the complex signature requirements and introduced the use of bearer tokens.