[bug] Session traces persist API credentials in plaintext headers
メンテナーはふだん 1 日以内に返信
まだ誰も着手していません。
評価
- 難易度
- 3/5
- 見積もり時間
- 1〜2日
- 初心者へのやさしさ
- 72/100
- issue の種類
- バグ
- 明瞭さ
- 明確に書かれている
- 活発さ
- 活発
- 技術スタック
- typescript
- 領域
- security
調査の方向性
Start at buildTraceRecord and cloneRequestHeaders, then inspect FetchHttpTransport and SessionTraceStore, using the isolated production-transport regression test described in the issue. Verify that persisted trace JSON redacts authorization, x-api-key, and response cookies across header casing, response status, and streaming mode while credentials still reach the endpoint.
索引モデルが issue の本文から書いたものです。
説明
Version and environment
main at 87c344501f5960cda6bf9f47eec5af0a4664cdba (1.0.0), Node.js 26.8.1, macOS 26.5.2 arm64.
Reproduction
- Create a
FetchHttpTransportwith a realSessionTraceStoretargeting a temporary storage root. - Send a request with complete trace metadata and dummy
authorization: Bearer fake-key-for-regression-only/x-api-key: fake-anthropic-keyheaders. Mock only the fetch response; do not use real credentials or call a model endpoint. - Read the generated
sessions/s1/trace/span1.json. - Both dummy credentials appear verbatim in
request.headers.
Expected behavior
Authentication credentials should reach the model endpoint but be redacted from persisted diagnostic headers, regardless of header-name casing, response status, or streaming mode.
Actual behavior and cause
buildTraceRecord copies request headers with cloneRequestHeaders without redaction. OpenAI-compatible requests contain a bearer token and Anthropic requests contain x-api-key. Session tracing is enabled by default in BUILTIN_CLI_DEFAULTS.
Trace files use mode 0600, so this is not a claim of unauthenticated remote access. The problem is that diagnostic files contain reusable API credentials and can disclose them if copied or shared. Response cookies should likewise be redacted from trace headers.
Verification
An isolated regression test using the production transport and filesystem trace store fails on current main because the saved JSON contains the dummy credential.
- Searched existing issues and PRs for duplicates.
- Read CONTRIBUTING.md.
- 主要言語
- TypeScript
- スター
- 850
- フォーク
- 62
- 平均マージ
- 1日 12時間
- マージ済み PR(30日)
- 43
環境構築
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートなし
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
stepfun-ai/Step-Code のほかの issue
-
area/build bug
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
stepfun-ai/Step-Code#190 · コメント 2 件 ·
メンテナーはふだん 1 日以内に返信
-
area/tools bug
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
stepfun-ai/Step-Code#186 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
area/tools bug
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
stepfun-ai/Step-Code#185 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
area/tools bug
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
stepfun-ai/Step-Code#184 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
bug
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
stepfun-ai/Step-Code#179 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
stepfun-ai/Step-Code の issue をすべて見る
似ている issue
-
難易度 1/5 1〜3時間 初心者へのやさしさ 70/100
siyuan-note/siyuan#20517 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 70/100
NaturalIntelligence/fast-xml-parser#890 · コメント 1 件 ·
メンテナーはふだん 3 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 62/100
zsviczian/obsidian-excalidraw-plugin#3000 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
pnpm/get.pnpm.io#68 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
nuxt-modules/better-auth#578 · コメント 2 件 ·
メンテナーはふだん 1 日以内に返信