A Fabric Connect token whose user was dropped answers 403 until a reload

オープン
#1,981 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

まだ誰も着手していません。

評価

難易度
3/5
見積もり時間
1〜2日
初心者へのやさしさ
56/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
活発
技術スタック
typescript

調査の方向性

Start with src/integrations/api/retryExpiredOperationToken.ts and trace how the interceptor handles 401 responses and re-mints a Fabric Connect token. Check how operation errors expose USER_HAS_NO_PERMS and the token user's name; the issue says this specific 403 should trigger one recovery attempt. Done means this case recovers once while unrelated 403 responses do not, and the affected recovery behavior is covered by a test.

索引モデルが issue の本文から書いたものです。

説明

Studio gets stuck when the user behind its Fabric Connect token is deleted:

  • Studio recovers a direct Fabric Connect token only on a 401 (src/integrations/api/retryExpiredOperationToken.ts:19).
  • The in-cluster guard skips re-establishing a connection that is already resolved (checkClusterInstanceAuthenticationBeforeLoad, the checkForFabricConnect && !hasResolvedFabricConnect branch).
  • Harper resolves a still-valid JWT for a dropped user to a principal with no role (harper v5.3.2 security/user.ts:576-581, 518-526).
  • Every operation then answers 403 OP_AUTH_PERMS_ERROR, with unauthorized_access: ["User <name> has no role or permissions..."] (utility/operation_authorization.ts:765), until a reload mints a new token.

#1979 closes the Finish Setup route into this state. Dropping the Fabric Connect principal any other way still reaches it, for example from the Users page or from another client. Fabric Connect resolves to Harper's first super user.

Fix idea: in the token-recovery interceptor, treat that specific 403 like an expired token and re-mint once. The specific 403 is USER_HAS_NO_PERMS naming the token's own user.

Found while root-causing #1979.

🤖 Generated by Anthropic Claude Code (Claude Opus 5.5); posted via @dawsontoth.

主要言語
TypeScript
スター
5
フォーク
4
平均マージ
2日 13時間
マージ済み PR(30日)
60

環境構築

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

HarperFast/studio のほかの issue

HarperFast/studio の issue をすべて見る

似ている issue

TypeScript の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。