Repository navigation
feat: サインアウト時のサーバー側トークン失効に対応 - #49
Merged
Merged
Conversation
Co-Authored-By: Claude <noreply@anthropic.com>
Co-Authored-By: Claude <noreply@anthropic.com>
Co-Authored-By: Claude <noreply@anthropic.com>
Co-Authored-By: Claude <noreply@anthropic.com>
Co-Authored-By: Claude <noreply@anthropic.com>
Co-Authored-By: Claude <noreply@anthropic.com>
Co-Authored-By: Claude <noreply@anthropic.com>
Co-Authored-By: Claude <noreply@anthropic.com>
Co-Authored-By: Claude <noreply@anthropic.com>
Co-Authored-By: Claude <noreply@anthropic.com>
Co-Authored-By: Claude <noreply@anthropic.com>
Co-Authored-By: Claude <noreply@anthropic.com>
Co-Authored-By: Claude <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
概要
Misskey 2026.9.0 で、アプリのアクセストークン(MiAuth / OAuth)が
/api/i/revoke-tokenで自身を失効できるようになったことへの対応。signOut/signOutAllが既定でサーバー上のトークンを失効させてから端末上のトークンを削除する形に変更し、単独で失効させるためのMisskeyTokenRevocationClientを追加。変更内容
MisskeyTokenRevocationClientを追加revokeは例外を投げず、TokenRevocationResult(revoked/alreadyInvalid/unsupported/failed)を返すrevoked、401AUTHENTICATION_FAILED→alreadyInvalid、400ACCESS_DENIEDと 404 →unsupported、それ以外 →failed)。本文が不正な JSON の場合もステータスで分類timeoutは、注入されたDioのインターセプターを含むリクエスト全体の期限MisskeyAuthManager.signOut/signOutAllにmode(SignOutMode)とtimeoutを追加revokeAndDelete(既定): 失効を試み、結果にかかわらず端末から削除revokeOrKeep: 失効を確認できた場合のみ削除。unsupported/failedは残すlocalOnly: 失効せずに削除(従来の挙動)signOutAllは全アカウントを並列に失効させ、timeoutは呼び出し時点からの共通の期限。結果は一覧の順で返し、削除はすべて試みてから最初のエラーを投げるSignOutResult/List<SignOutResult>に変更revocationを追加。既定ではマネージャーのdioを使うSecureTokenStore.listが、読み出せないトークンがあっても例外を投げないよう修正(メタ情報なしで一覧に含める)unsupported/failedのときに SnackBar を表示(6言語)CHANGELOG.mdの[Unreleased]に追記。既定で失効する点と戻り値の型の変更は**Breaking:**確認
dart format --output=none --set-exit-if-changed ./dart analyze --fatal-infosflutter test(ルート 166件、example 9件)flutter pub publish --dry-run(警告 0 件)docsのビルド(6言語)