GCWing / GCWing/OpenBitFun

[Security]: session JSON artifacts are written world-readable on unix (0o644 default umask)

クローズ 初心者向け
#2,605 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

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

主要言語
Rust
スター
2.3k
フォーク
231
平均マージ
2時間 49分
マージ済み PR(30日)
589

説明

Summary: On unix, session JSON artifacts written through JsonFileStore (session transcripts, metadata, token usage) are published with permissions inherited from the process umask — typically 0o644 — making prompt/output content world-readable on multi-user hosts.

Area: Agent runtime / core

Reproduction or evidence: src/crates/services/services-core/src/json_store.rs:306 writes the payload to a temp file (fs::write) and renames it into place without any permission tightening; the file contains no set_permissions/PermissionsExt/0o600 logic anywhere. On a unix host with default umask 022, the published artifact is world-readable (-rw-r--r--).

Environment: BitFun version/commit 32f2427697ee16f253ee6119860a03255c0b3e47 (origin/main); reproducible on any unix host with default umask (verified by code-path analysis; unix CI matrix exercises the fixed behavior).

コントリビューションガイド

コントリビューションガイドを開く

はじめの一歩

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

調査の方向性

src/crates/services/services-core/src/json_store.rs:306 から開始し、Unix 上で JsonFileStore がセッションアーティファクトを書き込み、名前を変更する方法を追跡します。0o22 の umask 下で最終的なファイルモードを確認し、セッション JSON ファイルが全ユーザーから読み取り可能ではなく、Unix のチェックに合格した時点で完了を確認します。

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

評価

技術スタック
rust
領域
backend, security
issue の種類
バグ
難易度
2/5
見積もり時間
1〜3時間
活発さ
活発
明瞭さ
明確に書かれている
初心者へのやさしさ
78/100

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

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