Skip to content
This repository was archived by the owner on Jun 1, 2023. It is now read-only.

Commit 6e28120

Browse files
committed
Made port_logout_redirect_uri OP specific.
1 parent 5e174c8 commit 6e28120

File tree

2 files changed

+8
-5
lines changed

2 files changed

+8
-5
lines changed

flask_rp/conf.yaml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ clients:
9696
redirect_uris:
9797
- 'https://{domain}:{port}/authz_cb/flop'
9898
post_logout_redirect_uris:
99-
- "https://{domain}:{port}/session_logout"
99+
- "https://{domain}:{port}/session_logout/flop"
100100
frontchannel_logout_uri: "https://{domain}:{port}/fc_logout/flop"
101101
frontchannel_logout_session_required: True
102102
backchannel_logout_uri: "https://{domain}:{port}/bc_logout/flop"
@@ -120,11 +120,13 @@ clients:
120120
# rp_iframe_path: "templates/rp_iframe.html"
121121
bobcat:
122122
client_id: client3
123-
client_secret: 2222222222222222222222222222222222222222
123+
client_secret: 'abcdefghijklmnop'
124124
client_preferences: *id001
125125
issuer: http://127.0.0.1:8080/
126126
jwks_uri: 'static/jwks.json'
127127
redirect_uris: ['https://{domain}:{port}/authz_cb/bobcat']
128+
post_logout_redirect_uris:
129+
- "https://{domain}:{port}/session_logout/bobcat"
128130
services: *id002
129131
request_args:
130132
claims:

flask_rp/views.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -211,10 +211,11 @@ def session_change():
211211

212212

213213
# post_logout_redirect_uri
214-
@oidc_rp_views.route('/session_logout')
215-
def session_logout():
214+
@oidc_rp_views.route('/session_logout/<op_hash>')
215+
def session_logout(op_hash):
216+
_rp = get_rp(op_hash)
216217
logger.debug('post_logout')
217-
return "Post logout"
218+
return "Post logout from {}".format(_rp.service_context.issuer)
218219

219220

220221
# RP initiated logout

0 commit comments

Comments
 (0)