Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
自サークルのIdPからログアウトできるようになるまで
Search
taiseiue
October 05, 2026
Programming
160
1
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
自サークルのIdPからログアウトできるようになるまで
Kyoto.js 25
で発表した資料です
taiseiue
October 05, 2026
More Decks by taiseiue
See All by taiseiue
同人サークルを作って 8年経った僕らの現在地
taiseiue
0
290
RustでもVJしたい!
taiseiue
0
110
“⾞が通れるほど⼤きな”セキュリティーホールを抑えながらログインしたい
taiseiue
0
630
Kotlinのデフォルト引数の話
taiseiue
0
130
.NETの上でお手製の言語を動かす技術
taiseiue
0
130
AIの力でお手軽Chrome拡張機能作り
taiseiue
0
500
振り向き美人
taiseiue
0
45
Tadpole operators
taiseiue
0
96
(自作の)プログラミング言語ができるまで
taiseiue
1
700
Other Decks in Programming
See All in Programming
Zero-Tap Sign-In対応、結局何をすればいいの?
mitohato14
0
1.5k
S3 TablesのIcebergデータに、AIエージェントからアクセスしてみた / 20261016developersio2026joetsu-accessing-iceberg-in-s3tables-via-agent
kasacchiful
PRO
0
260
AIで開発が速くなった先で、開発チームは何を目指すか
shihochan
1
2k
AWS CDKを理解するために公式の定義を深掘って解説してみる / Understanding AWS CDK by Digging into Its Official Definition
akihisaikeda
1
140
SODA - FACT BOOK(EN)
sodainc
1
200
FactoryBotをやめればRSpecは速くなるのか?
yuta_onishi_97
0
1.5k
React Native経験者が Flutterを30⽇間触って驚いたこと
3saito
0
140
JIS keyboard support in Omarchy
lef237
0
180
Web Framework Benchmark Battle 2026, Any%
a_matsuda
3
3.1k
Apple Intelligenceとオンデバイス時代の到来
yahir0
0
190
AI Augmentation Techniques with Liberty
ivargrimstad
1
310
Railsのためのパスキー実践入門 〜マルチテナントSaaSでの意思決定〜
utakaha
4
2.8k
Featured
See All Featured
State of Search Keynote: SEO is Dead Long Live SEO
ryanjones
0
340
Navigating Algorithm Shifts & AI Overviews - #SMXNext
aleyda
1
1.7k
The Language of Interfaces
destraynor
162
27k
SEO for Brand Visibility & Recognition
aleyda
0
4.8k
Building Better People: How to give real-time feedback that sticks.
wjessup
371
20k
Agile that works and the tools we love
rasmusluckow
331
22k
Impact Scores and Hybrid Strategies: The future of link building
tamaranovitovic
0
480
Building AI with AI
inesmontani
PRO
1
1.4k
Navigating the Design Leadership Dip - Product Design Week Design Leaders+ Conference 2024
apolaine
2
500
[Rails World 2026] Durable orchestration on Rails: from continuation to workflow
palkan
2
1k
Skip the Path - Find Your Career Trail
mkilby
1
280
The Spectacular Lies of Maps
axbom
PRO
1
1.1k
Transcript
自サークルのIdPから ログアウトできるようになるまで taiseiue 2026/10/5 Kyoto.js #25
JavaScript
https://www.nicovideo.jp/watch/sm1122515
https://dic.pixiv.net/a/ブラクラ
window.self • 上村太成 a.k.a. taiseiue • Kyoto.cs / CKP学生部 •
趣味: TS / Go / C# でない: TS / Go / Perl • 京都産業大学 / はてな マネーフォワード
前半の話 自サークルのIdPから ログアウトできるようになるまで 後半の話 taiseiue 今日はあんまりしない話 2026/10/5 Kyoto.js #25
None
None
None
None
None
None
自サークルのIdPから ログアウトできるようになるまで taiseiue 2026/10/5 Kyoto.js #25
https://speakerdeck.com/taiseiue/discord-oidc-proxy
https://speakerdeck.com/taiseiue/discord-oidc-proxy
https://speakerdeck.com/taiseiue/discord-oidc-proxy
https://speakerdeck.com/taiseiue/discord-oidc-proxy
一見さんもログインしてもらいたい
ロールベースのアクセス制御もしたい
fl Cloud areを挟めないサービスもある
オレオレアカウントを作る
オレオレアカウントを作る ↑たぶんやらない方がいい選択↑
None
None
None
None
😭
世間では最近ory stackが人気 https://www.ory.com/
世間では最近ory stackが人気 https://www.ory.com/
ory stackのいいところ • セルフホストできる • コンポーネントに分かれていて、 それぞれHeadlessなのでカスタムしやすい
https://www.ory.sh/docs/ecosystem/projects
アプリケーションはログインすると き、はじめory/hydraに遷移する
アプリケーションはログインすると き、はじめory/hydraに遷移する アプリケーションから見ると ory/hydraがOpenID Providerに見えている
ory/hydraは誰がログインしているか 知らないのでory/kratosに 遷移させログインさせる
ory/hydraは誰がログインしているか 知らないのでory/kratosに 遷移させログインさせる ユーザーはここでory/kratosにログインする
ory/kratosから受け取った情報を元に アプリケーションにユーザー情報を返す ここでory/hydraはユーザーに情報を渡していいかの fl 許可取り(consent ow)も行っている
かっこいい!うちもこれで!!
でももうユーザーアカウントちょっとある
😭
ory/hydraは誰がログインしているか 知らないのでory/kratosに 遷移させログインさせる ユーザーはここでory/kratosにログインする https://www.ory.sh/docs/ecosystem/projects
ory/hydraは誰がログインしているか 知らないのでory/kratosに 遷移させログインさせる ユーザーはここでory/kratosにログインする https://www.ory.sh/docs/ecosystem/projects
ory/hydraは誰がログインしているか 知らないのでAuth0に 遷移させログインさせる ユーザーはここでAuth0にログインする https://www.ory.sh/docs/ecosystem/projects
そんなこんなでできました
None
クライアント アプリケーション RP=Relying Party
OP=OpenID Provider クライアント アプリケーション RP=Relying Party
クライアント アプリケーション アカウント設定画面 Next.js製
クライアント アプリケーション アカウント設定画面 Next.js製 スタッフ側管理画面 TanStack製
Auth0のIDからAccountDBを引いてアカウント情報をhydraに渡す Go製 クライアント アプリケーション アカウント設定画面 Next.js製 ユーザーのプロフィールなどは Auth0ではなくこっちに保存 スタッフ側管理画面 TanStack製
None
自サークルのIdPから ログアウトできるようになるまで taiseiue 2026/10/5 Kyoto.js #25
ログアウトって何する処理でしょう?
CookieとかSession消したらよさそう
None
None
None
None
ここに残ったセッション情報で ログインし続けられてしまう
https://openid.net/specs/openid-connect-rpinitiated-1̲0.html
None
アプリケーションがログアウトする ときにOPのセッションを失効させる
アプリケーションがログアウトする ときにOPのセッションを失効させる
None
None
None
まだログインしたまま
https://www.ory.com/docs/hydra/guides/logout
None
hydraはログアウトしてよいかユーザーに尋ねるので、 これを利用してapps/coreがAuth0からもログアウトさせる
hydraはログアウトしてよいかユーザーに尋ねるので、 これを利用してapps/coreがAuth0からもログアウトさせる
ここはstate-lessだよ
ここはstate-lessだよ
ここはstate-lessだよ
ここはstate-lessだよ
ログアウト成功 ここはstate-lessだよ
アレ... ログアウト成功 ここはstate-lessだよ
他のアプリケーションからも ログアウトされていてほしい ログアウト成功 ここはstate-lessだよ アレ...
https://openid.net/specs/openid-connect-backchannel-1̲0.html
hydraがログアウト時に他のアプリケーションに back-channel logoutして周る ここはstate-lessだよ
None
ここはstate-lessだよ
ログアウト成功! ここはstate-lessだよ
わかったこと • 認証認可の不具合はコンポーネント単体よりも 境界面で起きる • 認証認可を設計するとき、どこに状態があるか を最初に洗い出すと良い
自サークルのIdPから ログアウトできるようになるまで taiseiue 2026/10/5 Kyoto.js #25
時間余ったとき用
None
None