SlideShare a Scribd company logo
Nomura Research Institute
#osw17
Future Proofing the OAuth 2.0 Authorization
Code Grant Protocol by the application of BCM
Principles
July 14, 2017
Nat Sakimura
Nomura Research Institute
© 2016 by Nomura Research Institute. All rights reserved.
Nomura Research Institute
Nat Sakimura
(Co-)Author of:
 OpenID Connect Core 1.0
 JSON Web Token [RFC7519]
 JSON Web Signature [7515]
 OAuth PKCE [RFC7636]
 OAuth JAR [forthcoming]
 Etc.
(Co-)Editor of:
 ISO/IEC 29184 Guidelines for online notice and consent
 ISO/IEC 29100 AMD: Privacy Framework
 ISO/IEC 27551 Requirements for attribute based
unlinkable entity authentication
 Etc.
• Research Fellow,
Nomura Research Institute
• Chairman of the Board,
OpenID Foundation
• Chair, Financial API WG
• Head of Japanese delegation to
ISO/IEC JTC 1/SC 27/WG5
• Liaison Officer SC 27/WG5 --
OECD/SPDE
• https://nat.Sakimura.org
• @_nat_en (English)
• @_nat (Japanese)
• Linked.in/natsakimura
• https://www.linkedin.co
m/in/natsakimura
• https://ja.wikipedia.org/
wiki/崎村夏彦
.. and an amateur flutist
(https://youtu.be/3gTCQhTcXL0)
© 2016 by Nomura Research Institute. All rights reserved.
Nomura Research Institute
BCM Principles
P1 Positional tagging. Cryptographic
message components should contain
information that uniquely identities
their origin. In particular, the
information should identify the
protocol, the protocol variant, the
message number, and the particular
position within the message, from
which the component was sent.
P2 Inclusion of identities and their roles.
Each cryptographic message
component should include information
about the identities of all the agents
involved in the protocol run and their
roles, unless there is a compelling
reason to do otherwise.
3 Criteria
(a)Unique Source
Identifier
(b)Protocol + version +
msg identifier
(c)Full list of actor/roles
Basin, D., Cremers, C., Meier, S.: Provably Repairing the ISO/IEC 9798
Standard for Entity Authentication. Journal of Computer Security - Security and Trust
Principles archive Volume 21 Issue 6, 817-846 (2013)
(a)
(b)
(c)
© 2016 by Nomura Research Institute. All rights reserved.
Nomura Research Institute
Let’s apply!
4
Let’s Play!
© 2016 by Nomura Research Institute. All rights reserved.
Nomura Research Institute
RFC6749 OAuth – code grant protocol msgs
Authorization Request
Authorization Response
Token Request
Token Response
Assume:
 a network attacker as (e.g. Browser malware)
the crypto & TLS are not broken
pure RFC6749 – Three parties static OAuth 2.0
5
UA
Clien
t
AS
© 2016 by Nomura Research Institute. All rights reserved.
Nomura Research Institute
So, how is RFC6749 (Naïve implementation) doing?
Message Parameters (a) Unique
Source Identifier
(b) Protocol +
version identifier
(c) Full list of
actor/roles
Authorization
Request
response type
client id
redirect uri
scope
state
Authorization
Response
code
state
other extension
parameters
Token Request grant type
code
redirect uri
client
credential/client id
.
Token Response access token
token_type
expires_in
refresh_token
others
6
Combination of
parameters are unique
for each message type =
(b) Good!
Legend
Required Parameter
Optional Parameter
Recommended Parameter
But the good ends here.
© 2016 by Nomura Research Institute. All rights reserved.
Nomura Research Institute
So, how is RFC6749 (Naïve implementation) doing?
Message Parameters (a) Unique
Source Identifier
(b) Protocol +
version identifier
(c) Full list of
actor/roles
Authorization
Request
response type
client id
redirect uri
scope
state
Client ID is not
globally unique.
Tampering
possible
List of params as
identifier, but it is
not integrity
protected
No.
Authorization
Response
code
state
other extension
parameters
No source
identifier
As above No
Token Request grant type
code
redirect uri
client
credential/client id
Client ID is not
globally unique.
OK (as long as
there is no OAuth
3.0)
No.
Token Response access token
token_type
expires_in
refresh_token
others
No source
identifier
As above No.
7
© 2016 by Nomura Research Institute. All rights reserved.
Nomura Research Institute
8
It’s a sad
state.
© 2016 by Nomura Research Institute. All rights reserved.
Nomura Research Institute
Could be tightened up
Message Parameters (a) Unique
Source Identifier
(b) Protocol +
version identifier
(c) Full list of
actor/roles
Authorization
Request
response type
client id
redirect uri
scope
state
Unique redirect
URI + Client ID
Request signing (a) + state as the
UA identifier /
TBID as UA
identifier
Authorization
Response
code
state
other extension
parameters
Unique redirect
URI
Response signing (a) + client_id +
state as the UA
identifier / TBID as
UA identifier
Token Request grant type
code
redirect uri
client
credential/client id
Unique redirect
URI + Client ID
OK (as long as
there is no OAuth
3.0)
(a) + state as the
UA identifier /
TBID as UA
identifier
Token Response access token
token_type
expires_in
refresh_token
others
Unique redirect
URI
As above (a) + client_id +
state as the UA
identifier / TBID as
UA identifier
9
© 2016 by Nomura Research Institute. All rights reserved.
Nomura Research Institute
Integrity protect the AuthZ Request/Response
• draft-ietf-oauth-jwsreq aka
OAuth JAR
AuthZ
Request
• Use ID Token as a
dethatched signature.
• Include new parameter
`s_hash` in the ID Token.
AuthZ
Response
10
© 2016 by Nomura Research Institute. All rights reserved.
Nomura Research Institute
Comparison
Message Original
Parameters
Modified Parameters Original Integrity
Protection
Modified Integrity
Protection
Authorization
Request
response type
client id
redirect uri
scope
state
response type
client id
redirect uri (uniqeue)
scope
state/tbid
None JAR
Authorization
Response
code
state
extension
params
code
state
redirect uri (uniqeue)
client id
state/tbid
extension params
None ID Token + s_hash
Token Request grant type
code
redirect uri
client cred/id
grant type
code
redirect uri (uniqeue)
client cred/id
state/tbid
TLS TLS
Token Response access token
token_type
expires_in
refresh_token
others
access token
token_type
expires_in
refresh_token
others
TLS TLS
11
© 2016 by Nomura Research Institute. All rights reserved.
Nomura Research Institute
BCM Principles Satisfied!
12
© 2016 by Nomura Research Institute. All rights reserved.
Nomura Research Institute
13
© 2016 by Nomura Research Institute. All rights reserved.
Nomura Research Institute
14
Science
needed!

More Related Content

PDF
170724 JP/UK Open Banking Summit English Translation
PPTX
Introduction to the FAPI Read & Write OAuth Profile
PDF
OpenID Foundation FAPI WG: June 2017 Update
PDF
Introduction to 
the FAPI Read & Write OAuth Profile - Jan 2018 Updates
PPTX
OpenID Foundation Foundation Financial API (FAPI) WG
PDF
アプリ開発で知っておきたい認証技術 - OAuth 1.0 + OAuth 2.0 + OpenID Connect -
PDF
Implementing WebAuthn & FAPI supports on Keycloak
PPTX
Modern Authentication for ASP.NET Core with IdentityServer 4 (Progressive .NE...
170724 JP/UK Open Banking Summit English Translation
Introduction to the FAPI Read & Write OAuth Profile
OpenID Foundation FAPI WG: June 2017 Update
Introduction to 
the FAPI Read & Write OAuth Profile - Jan 2018 Updates
OpenID Foundation Foundation Financial API (FAPI) WG
アプリ開発で知っておきたい認証技術 - OAuth 1.0 + OAuth 2.0 + OpenID Connect -
Implementing WebAuthn & FAPI supports on Keycloak
Modern Authentication for ASP.NET Core with IdentityServer 4 (Progressive .NE...

What's hot (13)

PPTX
Code on the chain! An introduction in writing smart contracts and tooling for...
PDF
OAuth 2.0 Updates #technight
PDF
Consideration on Holder-of-Key Bound Token < from Financial-grade API (FAPI) ...
PDF
Double Server Public Key Encryption with Keyword Search for Secure Cloud Storage
PPTX
The JSON-based Identity Protocol Suite
PDF
OAuth and OpenID Connect for Microservices
PDF
Identity and the quest for Self-Sovereign Identity - Daniel Hardman
PPTX
Lightweight Zero-trust Network Implementation and Transition with Keycloak an...
PPTX
Modern Authentication with OpenID Connect and IdentityServer 4 (umBristol - J...
PDF
Verifiable Credentials 101 for SSI and Decentralized Digital Identity - Tyler...
PPTX
Apache con@home 2021_sha
PDF
Nordic APIs - Building a Secure API
PDF
Incorporating OAuth: How to integrate OAuth into your mobile app
Code on the chain! An introduction in writing smart contracts and tooling for...
OAuth 2.0 Updates #technight
Consideration on Holder-of-Key Bound Token < from Financial-grade API (FAPI) ...
Double Server Public Key Encryption with Keyword Search for Secure Cloud Storage
The JSON-based Identity Protocol Suite
OAuth and OpenID Connect for Microservices
Identity and the quest for Self-Sovereign Identity - Daniel Hardman
Lightweight Zero-trust Network Implementation and Transition with Keycloak an...
Modern Authentication with OpenID Connect and IdentityServer 4 (umBristol - J...
Verifiable Credentials 101 for SSI and Decentralized Digital Identity - Tyler...
Apache con@home 2021_sha
Nordic APIs - Building a Secure API
Incorporating OAuth: How to integrate OAuth into your mobile app
Ad

Similar to Future Proofing the OAuth 2.0 Authorization Code Grant Protocol by the application of BCM Principles (20)

PDF
What the Heck is OAuth and OpenID Connect? Connect.Tech 2017
PPTX
Financial Grade OAuth & OpenID Connect
PDF
AllTheTalks.Online 2020: "Basics of OAuth 2.0 and OpenID Connect"
PDF
RFC6749 et alia 20130504
PDF
What the Heck is OAuth and OpenID Connect - DOSUG 2018
PDF
What the Heck is OAuth and Open ID Connect? - UberConf 2017
PDF
Demystifying OAuth 2.0
PDF
What the Heck is OAuth and OpenID Connect - RWX 2017
PDF
Flaws in Oauth 2.0 Can Oauth be used as a Security Server
PDF
OAuth Base Camp
PPTX
The Client is not always right! How to secure OAuth authentication from your...
PDF
OpenID Foundation Workshop at EIC 2018 - Introduction to the FAPI Read & Writ...
PPTX
Intro to OAuth2 and OpenID Connect
PDF
Draft Ietf Oauth V2 12
PDF
OpenID Connect "101" Introduction -- October 23, 2018
PDF
OAuth in the Real World featuring Webshell
PDF
JDD2015: Security in the era of modern applications and services - Bolesław D...
PDF
Oauth Nightmares Abstract OAuth Nightmares
PDF
What the Heck is OAuth and OpenID Connect? Connect.Tech 2017
Financial Grade OAuth & OpenID Connect
AllTheTalks.Online 2020: "Basics of OAuth 2.0 and OpenID Connect"
RFC6749 et alia 20130504
What the Heck is OAuth and OpenID Connect - DOSUG 2018
What the Heck is OAuth and Open ID Connect? - UberConf 2017
Demystifying OAuth 2.0
What the Heck is OAuth and OpenID Connect - RWX 2017
Flaws in Oauth 2.0 Can Oauth be used as a Security Server
OAuth Base Camp
The Client is not always right! How to secure OAuth authentication from your...
OpenID Foundation Workshop at EIC 2018 - Introduction to the FAPI Read & Writ...
Intro to OAuth2 and OpenID Connect
Draft Ietf Oauth V2 12
OpenID Connect "101" Introduction -- October 23, 2018
OAuth in the Real World featuring Webshell
JDD2015: Security in the era of modern applications and services - Bolesław D...
Oauth Nightmares Abstract OAuth Nightmares
Ad

More from Nat Sakimura (20)

PPTX
FAPI and beyond - よりよいセキュリティのために
PDF
OpenID in the Digital ID Landscape: A Perspective From the Past to the Future
PDF
金融 API 時代のセキュリティ: OpenID Financial API (FAPI) WG
PPTX
ブロックチェーン〜信頼の源泉の民主化のもたらす変革
PDF
API Days 2016 Day 1: OpenID Financial API WG
PPTX
OpenID Foundation Foundation Financial API (FAPI) WG
PPTX
車輪は丸くなったか?~デジタル・アイデンティティの標準化動向とそのゴール
PDF
OAuth SPOP @ IETF 91
PPTX
Oidc how it solves your problems
PPTX
Transient client secret extension
PDF
Introduction to OpenID Connect
PPTX
Nc 30 sakimura-distribution_0604
PPTX
Smartphone Native Application OP
PPTX
Open idとcyber空間
PDF
サイバー空間上の信頼フレームワークとパーソナルデータ経済
PPTX
Closing Note
PPTX
20110706 PIDSプロジェクト中間報告
PPTX
Open id specifications_work_update-tokyo_2011
PPTX
国民ID制度とトラスト・フレームワーク
PPT
Introduction to OpenID TX proposed extension
FAPI and beyond - よりよいセキュリティのために
OpenID in the Digital ID Landscape: A Perspective From the Past to the Future
金融 API 時代のセキュリティ: OpenID Financial API (FAPI) WG
ブロックチェーン〜信頼の源泉の民主化のもたらす変革
API Days 2016 Day 1: OpenID Financial API WG
OpenID Foundation Foundation Financial API (FAPI) WG
車輪は丸くなったか?~デジタル・アイデンティティの標準化動向とそのゴール
OAuth SPOP @ IETF 91
Oidc how it solves your problems
Transient client secret extension
Introduction to OpenID Connect
Nc 30 sakimura-distribution_0604
Smartphone Native Application OP
Open idとcyber空間
サイバー空間上の信頼フレームワークとパーソナルデータ経済
Closing Note
20110706 PIDSプロジェクト中間報告
Open id specifications_work_update-tokyo_2011
国民ID制度とトラスト・フレームワーク
Introduction to OpenID TX proposed extension

Recently uploaded (20)

PDF
MIND Revenue Release Quarter 2 2025 Press Release
PDF
cuic standard and advanced reporting.pdf
PDF
Unlocking AI with Model Context Protocol (MCP)
PDF
Mobile App Security Testing_ A Comprehensive Guide.pdf
PDF
Profit Center Accounting in SAP S/4HANA, S4F28 Col11
PDF
Per capita expenditure prediction using model stacking based on satellite ima...
PDF
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...
PPTX
Big Data Technologies - Introduction.pptx
PDF
Diabetes mellitus diagnosis method based random forest with bat algorithm
PPT
“AI and Expert System Decision Support & Business Intelligence Systems”
PPTX
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
PPTX
Detection-First SIEM: Rule Types, Dashboards, and Threat-Informed Strategy
PDF
Encapsulation theory and applications.pdf
PPTX
20250228 LYD VKU AI Blended-Learning.pptx
PDF
NewMind AI Weekly Chronicles - August'25 Week I
PPTX
Spectroscopy.pptx food analysis technology
PDF
Agricultural_Statistics_at_a_Glance_2022_0.pdf
PDF
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
PDF
Optimiser vos workloads AI/ML sur Amazon EC2 et AWS Graviton
PPTX
MYSQL Presentation for SQL database connectivity
MIND Revenue Release Quarter 2 2025 Press Release
cuic standard and advanced reporting.pdf
Unlocking AI with Model Context Protocol (MCP)
Mobile App Security Testing_ A Comprehensive Guide.pdf
Profit Center Accounting in SAP S/4HANA, S4F28 Col11
Per capita expenditure prediction using model stacking based on satellite ima...
Architecting across the Boundaries of two Complex Domains - Healthcare & Tech...
Big Data Technologies - Introduction.pptx
Diabetes mellitus diagnosis method based random forest with bat algorithm
“AI and Expert System Decision Support & Business Intelligence Systems”
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
Detection-First SIEM: Rule Types, Dashboards, and Threat-Informed Strategy
Encapsulation theory and applications.pdf
20250228 LYD VKU AI Blended-Learning.pptx
NewMind AI Weekly Chronicles - August'25 Week I
Spectroscopy.pptx food analysis technology
Agricultural_Statistics_at_a_Glance_2022_0.pdf
7 ChatGPT Prompts to Help You Define Your Ideal Customer Profile.pdf
Optimiser vos workloads AI/ML sur Amazon EC2 et AWS Graviton
MYSQL Presentation for SQL database connectivity

Future Proofing the OAuth 2.0 Authorization Code Grant Protocol by the application of BCM Principles

  • 1. Nomura Research Institute #osw17 Future Proofing the OAuth 2.0 Authorization Code Grant Protocol by the application of BCM Principles July 14, 2017 Nat Sakimura Nomura Research Institute
  • 2. © 2016 by Nomura Research Institute. All rights reserved. Nomura Research Institute Nat Sakimura (Co-)Author of:  OpenID Connect Core 1.0  JSON Web Token [RFC7519]  JSON Web Signature [7515]  OAuth PKCE [RFC7636]  OAuth JAR [forthcoming]  Etc. (Co-)Editor of:  ISO/IEC 29184 Guidelines for online notice and consent  ISO/IEC 29100 AMD: Privacy Framework  ISO/IEC 27551 Requirements for attribute based unlinkable entity authentication  Etc. • Research Fellow, Nomura Research Institute • Chairman of the Board, OpenID Foundation • Chair, Financial API WG • Head of Japanese delegation to ISO/IEC JTC 1/SC 27/WG5 • Liaison Officer SC 27/WG5 -- OECD/SPDE • https://nat.Sakimura.org • @_nat_en (English) • @_nat (Japanese) • Linked.in/natsakimura • https://www.linkedin.co m/in/natsakimura • https://ja.wikipedia.org/ wiki/崎村夏彦 .. and an amateur flutist (https://youtu.be/3gTCQhTcXL0)
  • 3. © 2016 by Nomura Research Institute. All rights reserved. Nomura Research Institute BCM Principles P1 Positional tagging. Cryptographic message components should contain information that uniquely identities their origin. In particular, the information should identify the protocol, the protocol variant, the message number, and the particular position within the message, from which the component was sent. P2 Inclusion of identities and their roles. Each cryptographic message component should include information about the identities of all the agents involved in the protocol run and their roles, unless there is a compelling reason to do otherwise. 3 Criteria (a)Unique Source Identifier (b)Protocol + version + msg identifier (c)Full list of actor/roles Basin, D., Cremers, C., Meier, S.: Provably Repairing the ISO/IEC 9798 Standard for Entity Authentication. Journal of Computer Security - Security and Trust Principles archive Volume 21 Issue 6, 817-846 (2013) (a) (b) (c)
  • 4. © 2016 by Nomura Research Institute. All rights reserved. Nomura Research Institute Let’s apply! 4 Let’s Play!
  • 5. © 2016 by Nomura Research Institute. All rights reserved. Nomura Research Institute RFC6749 OAuth – code grant protocol msgs Authorization Request Authorization Response Token Request Token Response Assume:  a network attacker as (e.g. Browser malware) the crypto & TLS are not broken pure RFC6749 – Three parties static OAuth 2.0 5 UA Clien t AS
  • 6. © 2016 by Nomura Research Institute. All rights reserved. Nomura Research Institute So, how is RFC6749 (Naïve implementation) doing? Message Parameters (a) Unique Source Identifier (b) Protocol + version identifier (c) Full list of actor/roles Authorization Request response type client id redirect uri scope state Authorization Response code state other extension parameters Token Request grant type code redirect uri client credential/client id . Token Response access token token_type expires_in refresh_token others 6 Combination of parameters are unique for each message type = (b) Good! Legend Required Parameter Optional Parameter Recommended Parameter But the good ends here.
  • 7. © 2016 by Nomura Research Institute. All rights reserved. Nomura Research Institute So, how is RFC6749 (Naïve implementation) doing? Message Parameters (a) Unique Source Identifier (b) Protocol + version identifier (c) Full list of actor/roles Authorization Request response type client id redirect uri scope state Client ID is not globally unique. Tampering possible List of params as identifier, but it is not integrity protected No. Authorization Response code state other extension parameters No source identifier As above No Token Request grant type code redirect uri client credential/client id Client ID is not globally unique. OK (as long as there is no OAuth 3.0) No. Token Response access token token_type expires_in refresh_token others No source identifier As above No. 7
  • 8. © 2016 by Nomura Research Institute. All rights reserved. Nomura Research Institute 8 It’s a sad state.
  • 9. © 2016 by Nomura Research Institute. All rights reserved. Nomura Research Institute Could be tightened up Message Parameters (a) Unique Source Identifier (b) Protocol + version identifier (c) Full list of actor/roles Authorization Request response type client id redirect uri scope state Unique redirect URI + Client ID Request signing (a) + state as the UA identifier / TBID as UA identifier Authorization Response code state other extension parameters Unique redirect URI Response signing (a) + client_id + state as the UA identifier / TBID as UA identifier Token Request grant type code redirect uri client credential/client id Unique redirect URI + Client ID OK (as long as there is no OAuth 3.0) (a) + state as the UA identifier / TBID as UA identifier Token Response access token token_type expires_in refresh_token others Unique redirect URI As above (a) + client_id + state as the UA identifier / TBID as UA identifier 9
  • 10. © 2016 by Nomura Research Institute. All rights reserved. Nomura Research Institute Integrity protect the AuthZ Request/Response • draft-ietf-oauth-jwsreq aka OAuth JAR AuthZ Request • Use ID Token as a dethatched signature. • Include new parameter `s_hash` in the ID Token. AuthZ Response 10
  • 11. © 2016 by Nomura Research Institute. All rights reserved. Nomura Research Institute Comparison Message Original Parameters Modified Parameters Original Integrity Protection Modified Integrity Protection Authorization Request response type client id redirect uri scope state response type client id redirect uri (uniqeue) scope state/tbid None JAR Authorization Response code state extension params code state redirect uri (uniqeue) client id state/tbid extension params None ID Token + s_hash Token Request grant type code redirect uri client cred/id grant type code redirect uri (uniqeue) client cred/id state/tbid TLS TLS Token Response access token token_type expires_in refresh_token others access token token_type expires_in refresh_token others TLS TLS 11
  • 12. © 2016 by Nomura Research Institute. All rights reserved. Nomura Research Institute BCM Principles Satisfied! 12
  • 13. © 2016 by Nomura Research Institute. All rights reserved. Nomura Research Institute 13
  • 14. © 2016 by Nomura Research Institute. All rights reserved. Nomura Research Institute 14 Science needed!