Share
Embed
20231109 OpenID TechNight vol.20 「OpenID Federation」
「OpenID Federation」
OpenID TechNight vol.20 ~ 分散型 ID 技術勉強会 ~ 2023/11/09(木)
OpenID Foundation Japan
November 09, 2023
Annual Pro sale · Save $30
Have presentations of your own?
Share with private links, password protection, and more control over your work.
Transcript
31 slides
-
R. Hedberg, Ed. M.B. Jones A.Å. Solberg J. Bradley G.
De Marco V. Dzhuvinov indepedent Self-Issued Consulting Sikt Yubico indepedent Connect2id Appendix D. Document History [[ To be removed from the final specification ]] -30 • ...... • Fixed #1727: Changed specification name from "OpenID Connect Federation" to "OpenID Federation". Workgroup: OpenID Connect Working Group Published: 5 October 2023 Authors: OpenID Federation 1.0 – draft 30 ドラフト30で仕様の名称が 『OpenID Connect Federation』から 『OpenID Federation』に変更された。 -
https://gainforum.org/GAINWhitePaper.pdf GAIN Global Assured Identity Network GAIN (Global Assured Identity
Network) は インターネット上に信頼性の⾼いデジタル アイデンティティネットワークを構築する プロジェクトです。 150名以上の関連分野の専⾨家が集まり、 GAIN DIGITAL TRUSTという⽩書を 執筆し、2021年9⽉に公開しました。 GAINの実現可能性を検証するため GAIN PoC Community Group が作られました。 -
現在のエコシステムのアーキテクチャ (1/4) オープンバンキングはイギリスで 始まり、世界に広がっていきました。 各国は独⾃のエコシステムを構築し、 複数のサービスと複数のアプリが 接続できるようにしました。 サービスとアプリは、OAuth 2.0 と
OpenID Connect で技術詳細が定義 されている認可サーバとOAuth クラ イアントを実装しました。 英国 オープン バンキング オーストラリア 消費者データ権 ブラジル オープン ファイナンス サウジアラビア オープン バンキング -
現在のエコシステムのアーキテクチャ (2/4) 典型的な実装ではOAuthクライアントは⼀度に⼀つの認可サーバにのみ 所属します。そのような関係を持たない認可サーバとOAuthクライアン トはやりとりできません。 そのため、複数のサービス とやりとりしたいアプリは、 各サービスの認可サーバと ⼀つずつ関係を築く必要が あります。
サービス 認可サーバ サービス 認可サーバ サービス 認可サーバ アプリ OAuthクライアント OAuthクライアント アプリ OAuthクライアント OAuthクライアント -
現在のエコシステムのアーキテクチャ (3/4) この関係を築くため、アプリケーションは動的クライアント登録という 仕組みを使い、⾃⾝を各認可サーバに登録します。 サービス 認可サーバ アプリ OAuth クライアント 動的クライアント
登録エンドポイント クライアントのメタデータ クライアントのメタデータと識別⼦ クライアント識別⼦ サービス 認可サーバ OAuth クライアント 動的クライアント 登録エンドポイント クレイアントのメタデータ クライアントのメタデータと識別⼦ クライアント識別⼦ -
現在のエコシステムのアーキテクチャ (4/4) 認可を受けていない者によるクライアント登録を 防ぐため、実世界のシステムでは何らかの対策が 講じられます。 ⼀例として、動的クライアント登録リクエストに 中央の権威機関が発⾏したソフトウェアステート メントを含めることを要求する⽅法があります。 サービス 認可サーバ
アプリ OAuth クライアント 動的クライアント 登録エンドポイント クライアントのメタデータ + ソフトウェアステートメント クライアントのメタデータと識別⼦ クライアント識別⼦ 中央 権威機関 ソフトウェア ステートメント 発⾏ -
アプリ オープンバンキングディレクトリ 鍵ペア ソフトウェアステートメント クライアント情報 署名 クライアント情報 秘密鍵でクライアント 情報に署名し、ソフト ウェアステートメント
を⽣成する。 秘密鍵 署名 ソフトウェアステートメント発⾏API JWKセットエンドポイント 公開鍵を含む JWK セット ① ② ③ 認可サーバ ソフトウェア ステートメント発⾏ ソフトウェア ステートメント要求 クライアント登録エンドポイント ソフトウェアステートメント クライアント情報 署名 { "keys": [ ....., ]} 公開鍵 公開鍵 公開鍵 ソフトウェアステートメント クライアント情報 署名 検証 ⑤ ⑥ JWKセット送信 JWKセット要求 ソフトウェアステートメント および追加のクライアントメ タデータを含む動的クライア ント登録リクエスト ④ ⑦ -
採⽤された世界標準仕様 • OpenID Connect Federation 1.0 • OpenID Connect for
Identity Assurance 1.0 GAIN POCフェーズ1 • OpenID for Verifiable Credential Issuance • SD-JWT-based Verifiable Credentials (SD-JWT VC) • OAuth 2.0 Attestation-Based Client Authentication GAIN POCフェーズ2 -
クライアントA-1 クライアントA-2 クライアントA-3 認可サーバA 管理下 (直接的関係) クライアントB-1 クライアントB-2 クライアントB-3 認可サーバB
管理下 (直接的関係) 中間 権威機関A トラスト アンカーA 信頼 トラストチェーンにより確⽴される関係 OpenID Federation 概要 トラスト アンカーB 中間 権威機関B 認可 認可 認可 信頼 認可 トラストチェーン トラストチェーン -
認可サーバA クライアントB-1 認可サーバがクライアントを受け⼊れるためのトラストチェーン クライアントが認可サーバを受け⼊れるためのトラストチェーン クライアントB-1 トラスト アンカーA 認可 中間 権威機関A
認可 トラストチェーン 認可サーバA 中間 権威機関B 認可 トラスト アンカーB 認可 トラストチェーン 信頼 信頼 -
トラストチェーン 末端エンティティ ⾃⾝が発⾏する、 ⾃⾝のメタデータ を記述したもの。 中間権威機関が、 下位エンティティ を認可しているこ とを⽰すもの。 トラストアンカー
が、下位エンティ ティを認可してい ることを⽰すもの。 トラストアンカー ⾃⾝が発⾏する、 ⾃⾝のメタデータ を記述したもの。 発⾏ 発⾏ 発⾏ エンティティ ステートメント エンティティ ステートメント エンティティ ステートメント エンティティ ステートメント エンティティ コンフィギュレーション エンティティ コンフィギュレーション 末端エンティティ Leaf Entity 中間権威機関 Intermediate Authority トラストアンカー Trust Anchor トラストチェーンの構成要素 フェデレーション エンティティ群 -
TRUST CHAIN Leaf Entity LEの秘密鍵 LEの公開鍵 署名 署名 IAの秘密鍵 IAの公開鍵
署名 署名 TAの秘密鍵 TAの公開鍵 署名 署名 署名 署名 Intermediate Authority Trust Anchor 発⾏ 発⾏ 発⾏ { "iss": , } LEの識別⼦ "sub": , LEの識別⼦ "jwks":[ ], ... LEの公開鍵 IAの識別⼦ { "iss": , } "sub": , LEの識別⼦ LEの公開鍵 "jwks":[ ], ... { "iss": , } TAの識別⼦ IAの識別⼦ "sub": , IAの公開鍵 "jwks":[ ], ... { "iss": , } TAの識別⼦ TAの識別⼦ "sub": , TAの公開鍵 "jwks":[ ], ... -
トラストチェーン解決 末端エンティティ コンフィギュレーション エンドポイント 中間権威機関 フェッチエンドポイント トラストチェーン トラストアンカー フェッチエンドポイント 末端エンティティの
エンティティ コンフィギュレーション 中間権威機関が発⾏する エンティティ ステートメント トラストアンカーが 発⾏するエンティティ ステートメント -
TRUST CHAIN Leaf Entity /123/.well-known/openid-federation https://rp.example.com Intermediate Authority /.well-known/openid-federation {
"iss":"https://ia.example.com", "sub":"https://ia.example.com", "metadata":{ "federation_entity":{ "federation_fetch_endpoint": "https://ia.example.com/fetch", ... }, }, "authority_hints":[ "https://ta.example.com" ], entity configuration Trust Anchor /.well-known/openid-federation https://ta.example.com { "iss":"https://ta.example.com", "sub":"https://ta.example.com", "metadata":{ "federation_entity":{ "federation_fetch_endpoint": "https://ta.example.com/fetch", entity configuration 例:末端エンティティの識別⼦が https://rp.example.com/123 の場合 entity configuration { "iss":"https://rp.example.com/123", "sub":"https://rp.example.com/123", "authority_hints":[ "https://ia.example.com" ], "jwks":[ ], LEの公開鍵 { "iss":"https://ia.example.com", "sub":"https://rp.example.com/123", "jwks":[ ], LEの公開鍵 { "iss":"https://ta.example.com", "sub":"https://ia.example.com", "jwks":[ ], IAの公開鍵 https://ia.example.com sub= https://rp.example.com/123 /fetch sub=https://ia.example.com /fetch -
エンティティのメタデータ エンティティ /.well-known/ openid-federation { ..., "metadata": { "エンティティタイプ識別⼦": {
} } } エンティティコンフィギュレーション メタデータ エンティティタイプ識別⼦ • openid_relying_party • openid_provider • oauth_authorization_server • oauth_client • oauth_resource • federation_entity • openid_credential_issuer -
{ "iss":"https://idp.example.com", "sub":"https://idp.example.com", "authority_hints":[ "https://ia.example.com" ], "jwks":[ ], "metadata":{ "openid_provider":{
"issuer":"https://idp.example.com", "authorization_endpoint": "https://idp.example.com/authorize", "token_endpoint": "https://idp.example.com/token", "userinfo_endpoint": "https://idp.example.com/userinfo", ... } }, ... } /.well-known/openid-federation https://idp.example.com entity configuration identity provider's public key entity configuration of an identity provider OpenIDプロバイダの エンティティコンフィギュレーションの例 -
{ "iss":"https://rp.example.com/123", "sub":"https://rp.example.com/123", "authority_hints":[ "https://ia.example.com" ], "jwks":[ ], "metadata":{ "openid_relying_party":{
"redirect_uris":[ "https://rp.example.com/123/callback" ], "response_types":[ "code" ], ... } }, ... } /123/.well-known/openid-federation https://rp.example.com entity configuration relying party's public key entity configuration of a relying party OpenIDリライングパーティの エンティティコンフィギュレーションの例 -
{ "iss":"https://ia.example.com", "sub":"https://ia.example.com", "authority_hints":[ "https://ta.example.com" ], "jwks":[ ], "metadata":{ "federation_entity":{
"federation_fetch_endpoint": "https://ia.example.com/fetch", "federation_list_endpoint": "https://ia.example.com/list", "federation_resolve_endpoint": "https://ia.example.com/resolve", ... } }, ... } /.well-known/openid-federation https://ia.example.com entity configuration intermediate authority's public key entity configuration of an intermediate authority 中間権威機関の エンティティコンフィギュレーションの例 -
{ "iss":"https://ta.example.com", "sub":"https://ta.example.com", "jwks":[ ], "metadata":{ "federation_entity":{ "federation_fetch_endpoint": "https://ta.example.com/fetch", "federation_list_endpoint":
"https://ta.example.com/list", "federation_resolve_endpoint": "https://ta.example.com/resolve", ... } }, ... } /.well-known/openid-federation https://ta.example.com entity configuration trust anchor's public key entity configuration of a trust anchor トラストアンカーの エンティティコンフィギュレーションの例 -
エンティティID https://relying-party.authlete.net/5899463614448063 の クライアントを受け⼊れるためにトラストチェーンの解決を⾏う。 ① エンティティコンフィギュレーションを取得する。 $ curl -s https://relying-party.authlete.net/5899463614448
063/.well-known/openid-federation "authority_hints": [ "https://trust-anchor.authlete.net/" ], 返ってくるJWTのペイロード部分には "authority_hints" が含まれている。 "authority_hints" 配列には上位権威機関群(中間権威機関や トラストアンカー)が列挙されている。 (名前から推察できるように、この例では直接の上位機関がトラストアンカーとなっている。) -
②上位権威機関のエンティティコンフィギュレーションを取得する。 $ curl -s https://trust-anchor.authlete.net/.well-known/op enid-federation "metadata": { "federation_entity": {
"federation_list_endpoint": "https://trust-anchor.authlete.net/list/", "federation_fetch_endpoint": "https://trust-anchor.authlete.net/fetch/" } } ペイロード部分には "federation_fetch_endpoint" が含まれている。 "federation_fetch_endpoint" で⽰されるエンドポイントから エンティティステートメントを取得できる。 -
③エンティティステートメントを取得する。 $ curl -s https://trust-anchor.authlete.net/fetch/?sub=htt ps://relying-party.authlete.net/5899463614448063 "iss": "https://trust-anchor.authlete.net/", "sub": "https://relying-party.authlete.net/5899463614448063",
"jwks": { "keys": [ { ... } ] } 返ってくるJWTのペイロード部分を⾒ると、iss (issuer) が上位権威 機関で、sub (subject) が末端エンティティであることが分かる。 jwks.keys には末端エンティティの公開鍵が含まれている。 -
OpenID Federation 1.0 仕様: 解説: https://openid.net/specs/openid-federation-1_0.html https://www.authlete.com/developers/oidcfed/ Global Assured Identity
Network (GAIN) ホワイトペーパー: 中間報告 (⾮公式): https://gainforum.org/GAINWhitePaper.pdf https://qiita.com/TakahikoKawasaki/items/3c65d546627e9e1fabd0 OpenID for Verifiable Credential Issuance (OID4VCI) 仕様ドラフト: 解説: https://openid.github.io/OpenID4VCI/openid-4- verifiable-credential-issuance-wg-draft.html https://www.authlete.com/ja/developers/oid4vci/ -
質疑応答 川﨑 貴彦 (かわさき たかひこ) Authlete 社代表取締役社⻑。ソフトウェアエンジニア。1997 年に慶應⼤学 総合政策学部を卒業後、⺠間企業 4
社に勤めた後 2009 年に独⽴。ネット ワークやデータベース、Java 仮想マシン、モバイルアプリ、分散システム 等の業務に携わってきた。Web API セキュリティやシングルサインオンの ための世界標準技術であるOAuth 2.0 / OpenID Connect の実装を部品化・ SaaS 化する独⾃アーキテクチャを考案し、2015 年に Authlete 社を創業。 ⾦融業界 API 化の世界的な潮流に乗って国内外で顧客を獲得し、持続可能 な事業として確⽴。現在は世界標準仕様策定活動に参画して実装に落とし 込む作業をしている。 株式会社 Authlete (オースリート) 2015 年 9 ⽉創業。OAuth/OIDC の実装を Web API 化し、SaaS として提供。独⾃ アーキテクチャと実装の網羅性、最新仕様への対応の早さで世界的競争⼒を持つ。 2023 年 9 ⽉にシリコンバレーの連続起業家を CEO に迎え⽶国市場進出を本格化。 ੵۃ࠾༻த