0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

OpenID Connect Back-Channel Logout 1.0 - draft 06 メモ

Last updated at Posted at 2021-09-19
  • SLOの調査にあたって、Open ID Connect Back-Channel Logout について調べたためメモしておく。

RP-initiated LogoutとBack-Channel Logout

  • RP-initiated Logoutは、RP が、ユーザーエージェントをOPのログアウトエンドポイントにリダイレクトすることで、OPにエンドユーザーからログアウトすることを要求する機能。
  • Back-Channel Logoutは、OPからログアウトしたことをログイン中のRPにバックエンド間通信で通知する方法。

Back-Channel Logoutの流れ

(バックチャネルログアウトをサポートするOPは、ログイン中のRPを追跡し、バックチャネルログアウトURIでどのRPに接続してログアウトさせるかを把握しておく必要がある。)

(OP側でログアウトした後...)

1. OPはログアウトトークンをログインしたRPに送信する。

  • ログアウトトークンはapplication/x-www-form-urlencoded形式で logout_token パラメータに指定し、POSTメソッドで送信する。

    POST /backchannel_logout HTTP/1.1
    Host: rp.example.org
    Content-Type: application/x-www-form-urlencoded
    
    logout_token=eyJhbGci ... .eyJpc3Mi ... .T3BlbklE ..
    
  • クレーム

クレーム 必須/任意 説明
iss 必須 トークンの発行者
sub 任意 サブジェクトID
aud 必須 トークンの発行対象
iat 必須 発行日時
jti 必須 トークンのID
events 必須 JSONオブジェクト。メンバー名:http://schemas.openid.net/event/backchannel-logout。値:{}。
sid 任意 セッションID
      {
        "iss": "https://server.example.com",
        "sub": "248289761001",
        "aud": "s6BhdRkqt3",
        "iat": 1471566154,
        "jti": "bWJq",
        "sid": "08a5019c-17e1-4977-8f42-65a12843ea02",
        "events": {
          "http://schemas.openid.net/event/backchannel-logout": {}
          }
       }

2. RPは受信したログアウトトークンを検証して、ログアウトトークンで指定されたセッションを無効化する。

  • ログアウトトークンの検証に成功した場合はステータスコード 200 、失敗した場合は 400 を返却する。

Security Considerations

  • DoS攻撃を防ぐためにログアウトトークンの署名検証を行う。
  • OPは、キャプチャされたログアウトトークンを再利用されないようにログアウトトークンに短い有効期限を使用することが推奨される。

参考

0
0
1

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?