You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
docs(cpex): align demo + docs with MCP-frame authorization-error rendering
After merging PR #501 (shared MCP rejection renderer, httpx/render.go), cpex
denials on the HTTP proxies render as an MCP JSON-RPC 2.0 error frame at HTTP 200
for classified MCP requests (code -32000, error.data.error=cpex.<code>), and fall
back to plain 403/502 only for non-MCP requests. The demo and docs still
described the old transport-level 403. Truth them up:
- Chat agent (agent.py): format_tool_response reads the cpex code from
error.data.error (was error.data.violation, which the renderer never emits).
Verified live in-container against a real deny frame. Fix a stale '-> 403'
comment.
- Scenarios 02/05/06/07/08/09: headers + notes now expect HTTP 200 + JSON-RPC
error frame (error.data.error=cpex.*), not HTTP 403. Re-ran all 9: deny frames
match.
- README: taint S3 line now says denied via MCP JSON-RPC error frame.
- CHAT-WALKTHROUGH.md: fix all four deny sections (code -32001 -> -32000,
data.violation -> data.error with the real cpex codes).
- Plugin docs (plugins/cpex/README.md, docs/cpex-plugin.md): the deny/error
wire shape is now described as listener-dependent (MCP frame at 200 vs plain
403/502). Also correct the stale 'body modifications aren't re-serialized'
limitation: re-serialization is implemented; the real limitation is that
multi-part rewrites fail closed.
Signed-off-by: Frederico Araujo <frederico.araujo@ibm.com>
| `config_file` | empty | path to CPEX YAML; mounted from a ConfigMap in production |
236
-
| `fail_open` | `false` | on a CPEX internal error: deny with 502 (false) or continue (true) |
236
+
| `fail_open` | `false` | on a CPEX internal error: deny (false) or continue (true). The rejection renders per the listener — MCP error frame for MCP requests, else HTTP 502 (see Decisions and denials) |
237
237
| `worker_threads` | `0` | CPEX tokio worker pool size; 0 lets CPEX pick |
238
238
| `bypass_paths` | health + `.well-known` | URL path globs that skip CPEX entirely |
239
239
| `bypass_hosts` | keycloak / SPIRE / observability | host globs that skip CPEX, outbound only |
@@ -256,19 +256,41 @@ The plugin maps the CPEX outcome onto AuthBridge's five-value invocation
256
256
vocabulary:
257
257
258
258
- **allow**: all sub-plugins continued, request proceeds untouched.
259
-
- **deny**: a sub-plugin returned a policy violation. Rejects with HTTP 403 and a
260
-
`cpex.<code>`violation code (`cpex.pii_detected`,
261
-
`cpex.session_tainted_secret`, and so on).
259
+
- **deny**: a sub-plugin returned a policy violation with a `cpex.<code>` code
260
+
(`cpex.pii_detected`, `cpex.session_tainted_secret`, and so on). The plugin
261
+
emits a `Reject`; how it appears on the wire is the listener's call, not the
262
+
plugin's (see below).
262
263
- **modify**: policy rewrote the body, headers, or labels. Changes are applied,
0 commit comments