SlideShare ist ein Scribd-Unternehmen logo
1 von 12
Downloaden Sie, um offline zu lesen
© 2015 Takashi Yahata (@paoneJP)
OAuth & OpenID Connect
入門のための入門
Takashi Yahata - @paoneJP
2015/7/31
2015/7/31 1
© 2015 Takashi Yahata (@paoneJP) 2015/7/31 2
OAuth って何?
© 2015 Takashi Yahata (@paoneJP) 2015/7/31 3
OpenID Connect って何?
© 2015 Takashi Yahata (@paoneJP)
トラディッショナルなアプリ連携
2015/7/31 4
ファイアウォールの中で組織内の人が
組織内のPCで
組織内のアプリ同士が連携して
© 2015 Takashi Yahata (@paoneJP) 2015/7/31 5
イマドキなアプリ連携
インターネットのあらゆるところから
正規のユーザーも、そうでない人も
いろんなデバイスを使って
3rd party のアプリと
連携して
© 2015 Takashi Yahata (@paoneJP)
 3rd party アプリにあなたの認証情報を渡してアプリを利用
 3rd party アプリは 「あなたの権限」 で 「すべての機能」 を実行可能
 3rd party アプリの利用停止はパスワードの変更で
 もちろんパスワードを設定した全アプリの変更対応が必要
OAuthがないとき
2015/7/31 6
© 2015 Takashi Yahata (@paoneJP)
 3rd party アプリがあなたに成り代わって
機能を使うとき
 あなたに 「必要な権限」 の同意を取って
 機能にアクセスするためのトークンを
受け取って
 必要な機能を利用する
 3rd party アプリの利用停止は、
トークンを失効することで、アプリ
ごとに停止ができる
OAuthがあるとき
2015/7/31 7
© 2015 Takashi Yahata (@paoneJP)
 OAuth では、ほとんどの実装で Bearer Token (無記名トークン) を使用。
 OAuth で認証、という実装は、Bearer Token でユーザー情報が取れる
APIにアクセスして、情報が取れれば認証OKとするもの。
 トークンの盗用、トークンの再利用を防げなければ、安全には使えない。
OAuthで認証する?え?
2015/7/31 8
© 2015 Takashi Yahata (@paoneJP)
 OAuth2.0 のフローを使って
 認証結果に関する情報を含む
 発行者の検証ができる
 IDトークンを取得して
 認証連携を実現する
OAuth2.0 + Identity Layer = OpenID Connect
2015/7/31 9
{
"kid": "1e9gdk7",
"alg": "RS256"
}
{
"iss": "http://server.example.com",
"sub": "248289761001",
"aud": "s6BhdRkqt3",
"nonce": "n-0S6_WzA2Mj",
"exp": 1311281970,
"iat": 1311280970,
"at_hash": "77QmUPtjPfzWtF2AnpK9RQ"
}
[signature]
eyJraWQiOiIxZTlnZGs3IiwiYWxnIjoiUlMyNTYifQ.ewogIml
zcyI6ICJodHRwOi8vc2VydmVyLmV4YW1wbGUuY29tIiwKICJzd
WIiOiAiMjQ4Mjg5NzYxMDAxIiwKICJhdWQiOiAiczZCaGRSa3F
0MyIsCiAibm9uY2UiOiAibi0wUzZfV3pBMk1qIiwKICJleHAiO
iAxMzExMjgxOTcwLAogImlhdCI6IDEzMTEyODA5NzAsCiAiYXR
faGFzaCI6ICI3N1FtVVB0alBmeld0RjJBbnBLOVJRIgp9.F9gR
ev0Dt2tKcrBkHy72cmRqnLdzw9FLCCSebV7mWs7o_sv2O5s6zM
ky2kmhHTVx9HmdvNnx9GaZ8XMYRFeYk8L5NZ7aYlA5W56nsG1i
WOou_-gji0ibWIuuf4Owaho3YSoi7EvsTuLFz6tq-dLyz0dKAB
MDsiCmJ5wqkPUDTE3QTXjzbUmOzUDli-gCh5QPuZAq0cNW3pf_
2n4zpvTYtbmj12cVcxGIMZby7TMWESRjQ9_o3jvhVNcCGcE0KA
QXejhA1ocJhNEvQNqMFGlBb6_0RxxKjDZ-Oa329eGDidOvvp0h
5hoES4a8IuGKS7NOcpp-aFwp0qVMDLI-Xnm-Pg
© 2015 Takashi Yahata (@paoneJP)
 http://datatracker.ietf.org/wg/oauth/documents/
 RFC6749 The OAuth 2.0 Authorization Framework
 RFC6750 The OAuth 2.0 Authorization Framework: Bearer Token Usage
OAuthを学ぶ
2015/7/31 10
© 2015 Takashi Yahata (@paoneJP)
 http://openid.net/developers/specs/
 OpenID Connect Core 1.0
 http://datatracker.ietf.org/wg/oauth/documents/
 RFC7519 JSON Web Token (JWT)
 http://datatracker.ietf.org/wg/jose/documents/
 Cryptography
 PublicKey, Hash, …
OpenID Connectを学ぶ
2015/7/31 11
© 2015 Takashi Yahata (@paoneJP)
続く …
2015/7/31 12

Weitere ähnliche Inhalte

Empfohlen

How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
ThinkNow
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
Kurio // The Social Media Age(ncy)
 

Empfohlen (20)

Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsProduct Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage Engineerings
 
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
 
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfAI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
 
Skeleton Culture Code
Skeleton Culture CodeSkeleton Culture Code
Skeleton Culture Code
 
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
 
How to have difficult conversations
How to have difficult conversations How to have difficult conversations
How to have difficult conversations
 
Introduction to Data Science
Introduction to Data ScienceIntroduction to Data Science
Introduction to Data Science
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best Practices
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project management
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
 
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
Unlocking the Power of ChatGPT and AI in Testing - A Real-World Look, present...
 
12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at Work12 Ways to Increase Your Influence at Work
12 Ways to Increase Your Influence at Work
 

OAuth & OpenID Connect 入門のための入門

  • 1. © 2015 Takashi Yahata (@paoneJP) OAuth & OpenID Connect 入門のための入門 Takashi Yahata - @paoneJP 2015/7/31 2015/7/31 1
  • 2. © 2015 Takashi Yahata (@paoneJP) 2015/7/31 2 OAuth って何?
  • 3. © 2015 Takashi Yahata (@paoneJP) 2015/7/31 3 OpenID Connect って何?
  • 4. © 2015 Takashi Yahata (@paoneJP) トラディッショナルなアプリ連携 2015/7/31 4 ファイアウォールの中で組織内の人が 組織内のPCで 組織内のアプリ同士が連携して
  • 5. © 2015 Takashi Yahata (@paoneJP) 2015/7/31 5 イマドキなアプリ連携 インターネットのあらゆるところから 正規のユーザーも、そうでない人も いろんなデバイスを使って 3rd party のアプリと 連携して
  • 6. © 2015 Takashi Yahata (@paoneJP)  3rd party アプリにあなたの認証情報を渡してアプリを利用  3rd party アプリは 「あなたの権限」 で 「すべての機能」 を実行可能  3rd party アプリの利用停止はパスワードの変更で  もちろんパスワードを設定した全アプリの変更対応が必要 OAuthがないとき 2015/7/31 6
  • 7. © 2015 Takashi Yahata (@paoneJP)  3rd party アプリがあなたに成り代わって 機能を使うとき  あなたに 「必要な権限」 の同意を取って  機能にアクセスするためのトークンを 受け取って  必要な機能を利用する  3rd party アプリの利用停止は、 トークンを失効することで、アプリ ごとに停止ができる OAuthがあるとき 2015/7/31 7
  • 8. © 2015 Takashi Yahata (@paoneJP)  OAuth では、ほとんどの実装で Bearer Token (無記名トークン) を使用。  OAuth で認証、という実装は、Bearer Token でユーザー情報が取れる APIにアクセスして、情報が取れれば認証OKとするもの。  トークンの盗用、トークンの再利用を防げなければ、安全には使えない。 OAuthで認証する?え? 2015/7/31 8
  • 9. © 2015 Takashi Yahata (@paoneJP)  OAuth2.0 のフローを使って  認証結果に関する情報を含む  発行者の検証ができる  IDトークンを取得して  認証連携を実現する OAuth2.0 + Identity Layer = OpenID Connect 2015/7/31 9 { "kid": "1e9gdk7", "alg": "RS256" } { "iss": "http://server.example.com", "sub": "248289761001", "aud": "s6BhdRkqt3", "nonce": "n-0S6_WzA2Mj", "exp": 1311281970, "iat": 1311280970, "at_hash": "77QmUPtjPfzWtF2AnpK9RQ" } [signature] eyJraWQiOiIxZTlnZGs3IiwiYWxnIjoiUlMyNTYifQ.ewogIml zcyI6ICJodHRwOi8vc2VydmVyLmV4YW1wbGUuY29tIiwKICJzd WIiOiAiMjQ4Mjg5NzYxMDAxIiwKICJhdWQiOiAiczZCaGRSa3F 0MyIsCiAibm9uY2UiOiAibi0wUzZfV3pBMk1qIiwKICJleHAiO iAxMzExMjgxOTcwLAogImlhdCI6IDEzMTEyODA5NzAsCiAiYXR faGFzaCI6ICI3N1FtVVB0alBmeld0RjJBbnBLOVJRIgp9.F9gR ev0Dt2tKcrBkHy72cmRqnLdzw9FLCCSebV7mWs7o_sv2O5s6zM ky2kmhHTVx9HmdvNnx9GaZ8XMYRFeYk8L5NZ7aYlA5W56nsG1i WOou_-gji0ibWIuuf4Owaho3YSoi7EvsTuLFz6tq-dLyz0dKAB MDsiCmJ5wqkPUDTE3QTXjzbUmOzUDli-gCh5QPuZAq0cNW3pf_ 2n4zpvTYtbmj12cVcxGIMZby7TMWESRjQ9_o3jvhVNcCGcE0KA QXejhA1ocJhNEvQNqMFGlBb6_0RxxKjDZ-Oa329eGDidOvvp0h 5hoES4a8IuGKS7NOcpp-aFwp0qVMDLI-Xnm-Pg
  • 10. © 2015 Takashi Yahata (@paoneJP)  http://datatracker.ietf.org/wg/oauth/documents/  RFC6749 The OAuth 2.0 Authorization Framework  RFC6750 The OAuth 2.0 Authorization Framework: Bearer Token Usage OAuthを学ぶ 2015/7/31 10
  • 11. © 2015 Takashi Yahata (@paoneJP)  http://openid.net/developers/specs/  OpenID Connect Core 1.0  http://datatracker.ietf.org/wg/oauth/documents/  RFC7519 JSON Web Token (JWT)  http://datatracker.ietf.org/wg/jose/documents/  Cryptography  PublicKey, Hash, … OpenID Connectを学ぶ 2015/7/31 11
  • 12. © 2015 Takashi Yahata (@paoneJP) 続く … 2015/7/31 12