Skip to content

[CTX-0330] feat(plugin-runtime): env grant gate + runtime error taxonomy + secret-tier hooks (#1091) - #1308

Merged
Xuepoo merged 1 commit into
mainfrom
ctx-0330/envsec
Sep 23, 2026
Merged

Xuepoo merged 1 commit into
mainfrom
ctx-0330/envsec

Conversation

@Xuepoo

@Xuepoo Xuepoo commented Sep 23, 2026

Copy link
Copy Markdown
Contributor

Priority: P1 | Area: plugin | Labels: feat,area:plugin,P1 | Milestone: v0.1.0 | RFC: OQ-055 | Task: CTX-0330

Relates to #1091 (NOT Closes — OQ evidence still maturing).

Wires adopted env/secret pieces into live paths:

  • env grant gate: new closed env.read:<KEY> capability (bitty-package canonical tables + host Env family, param-required, high-risk consent); bridge validates key shape then delegates through the deadline-checked path; services enforce per-key grants (fail-closed typed E_NOT_IMPLEMENTED until granted, desensitized); activation extracts keys with rollback before any VM exists (malformed -> Integrity, >64 -> LimitExceeded).
  • runtime error taxonomy: PluginRuntimeError gains Budget/Timeout/LimitExceeded with stable code() (E_BUDGET_EXCEEDED/E_TIMEOUT/E_DEF_LIMIT) + error_class() mirroring bridge classes.
  • secret-tier hooks: check_tier_access + TierAccess enforced at PluginHost::resolve_secret_with_tier with names-only audit (audit_tier_deny); HostEnv passes the gate (allowlist at bitty.env boundary), grant tiers need explicit consent.

Verification: cargo fmt clean; cargo check --workspace --all-targets; RUSTFLAGS=-D warnings cargo clippy --workspace --all-targets; cargo test --workspace (245 suites ok); cargo +1.85 check --workspace --all-targets.

Status framing stays candidate/non-authoritative; no normative tier admission or keyring/command execution.

@Xuepoo Xuepoo added this to the v0.1.0 milestone Sep 23, 2026
@Xuepoo Xuepoo added feat Feature P1 Priority: high area:plugin Area: plugin host labels Sep 23, 2026
@Xuepoo
Xuepoo merged commit 92e4983 into main Sep 23, 2026
15 checks passed
@Xuepoo
Xuepoo deleted the ctx-0330/envsec branch September 23, 2026 04:54
Xuepoo pushed a commit that referenced this pull request Sep 23, 2026
Xuepoo added a commit that referenced this pull request Sep 23, 2026
…5/057/068/083/085) (#1310)

* [CTX-0719] feat(sec): wire adopted trust/role/credential/lease/wheel seams (OQ-054/055/057/068/083/085)

* [CTX-0719] fix(sec): cover CapabilityFamily::Env from #1308 in trust matrix

---------

Co-authored-by: reviewer <[email protected]>
Co-authored-by: hermes-planner <hermes-planner@local>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:plugin Area: plugin host feat Feature P1 Priority: high

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant