mirror of
https://github.com/openai/codex.git
synced 2026-10-30 19:18:49 +00:00
## What changed - Recognize the `codex_strict_auto_review` MCP elicitation marker and route marked approval requests through the configured automatic reviewer. - Accept only canonical automatic-review approvals and fail closed without a user prompt when review is unavailable, denied, malformed, disallowed by policy, or requests persistence. - Validate Codex Apps approval metadata against the active MCP invocation and build the review request from the trusted invocation details. ## Testing - Add unit coverage for strict review decisions, malformed markers, reviewer failures, explicit policy denials, and lifecycle cleanup. - Add app-server round-trip coverage for approvals, denials, configuration constraints, spoofed metadata, persistent requests, and subsequent turns. GitOrigin-RevId: af73b45a9b63118f25f6429d95b3222c5dbb59fb
21 lines
1.1 KiB
Rust
21 lines
1.1 KiB
Rust
pub const APPROVAL_KIND_KEY: &str = "codex_approval_kind";
|
|
pub const APPROVAL_KIND_MCP_TOOL_CALL: &str = "mcp_tool_call";
|
|
pub const APPROVAL_KIND_TOOL_SUGGESTION: &str = "tool_suggestion";
|
|
pub const REQUEST_TYPE_KEY: &str = "codex_request_type";
|
|
pub const REQUEST_TYPE_APPROVAL_REQUEST: &str = "approval_request";
|
|
pub const STRICT_AUTO_REVIEW_KEY: &str = "codex_strict_auto_review";
|
|
pub const APPROVALS_REVIEWER_KEY: &str = "approvals_reviewer";
|
|
pub const PERSIST_KEY: &str = "persist";
|
|
pub const PERSIST_SESSION: &str = "session";
|
|
pub const PERSIST_ALWAYS: &str = "always";
|
|
pub const SOURCE_KEY: &str = "source";
|
|
pub const SOURCE_CONNECTOR: &str = "connector";
|
|
pub const CONNECTOR_ID_KEY: &str = "connector_id";
|
|
pub const CONNECTOR_NAME_KEY: &str = "connector_name";
|
|
pub const CONNECTOR_DESCRIPTION_KEY: &str = "connector_description";
|
|
pub const TOOL_NAME_KEY: &str = "tool_name";
|
|
pub const TOOL_TITLE_KEY: &str = "tool_title";
|
|
pub const TOOL_DESCRIPTION_KEY: &str = "tool_description";
|
|
pub const TOOL_PARAMS_KEY: &str = "tool_params";
|
|
pub const TOOL_PARAMS_DISPLAY_KEY: &str = "tool_params_display";
|