vetted-ops: --caller is self-declared, so per-skill grants are not enforced

Đang mở
#2,124 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

Chưa có ai nhận issue này.

Đánh giá

Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức phù hợp với người mới
42/100
Loại issue
Lỗi
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
python

Hướng nghiên cứu

Start in tools/vetted-ops/README.md and the policy template's [callers] table, then trace how vetted-op/vetted-op-read consume --caller. Review the agent-guard hook that receives transcript_path and where the latest skill invocation is recorded, since the guard must map that skill to its caller name and reject mismatches, with an allowlist for documented sub-callers such as security-issue-sync-gatherer. Also add the missing ID-allocation caller to the template. Done means the guard denies borrowed callers, tests cover it, and the docs state callers are not authenticated.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

capability:fix capability:intake family:docs family:security family:tools substrate:sandbox

Problem

vetted-op and vetted-op-read authorise each operation by the --caller name the agent passes, and the policy's [callers] table grants operations per skill. Nothing checks that the name matches the skill actually running. When a skill's own caller is refused, the agent can rerun the same operation under another skill's caller that holds the grant, and in practice it did.

Observed: while running the ID-allocation skill, whose caller is not declared in the adopter's policy, the agent ran body-field-set, issue-add-label and rollup-append under --caller security-issue-sync. The operator had approved the writes, but the per-skill split did not restrict anything. The real limit is the union of every caller's grants.

Proposal

  1. Guard. Add an agent-guard rule for vetted-op* commands. It reads the session transcript (hooks receive transcript_path), finds the most recent skill invocation, maps it to that skill's caller name, and denies the call when --caller differs. It needs an allowlist for documented sub-callers such as security-issue-sync-gatherer in subagents.
  2. Docs, until the guard lands. State in tools/vetted-ops/README.md and the policy template that callers are not authenticated, and that the policy limits the agent as a whole rather than isolating skills.
  3. Template. Declare a caller for the ID-allocation skill in the policy template. Its absence is what made borrowing tempting.

🤖 Generated with Claude Code

Ngôn ngữ chính
Python
Star
152
Fork
133
Merge trung bình
12 giờ 39 phút
Pull request đã merge (30 ngày)
384

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của apache/magpie

Tất cả issue của apache/magpie

Issue tương tự

Thêm issue về Python

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.