SShortSingh.
Back to feed

AgentGateway CEL Policy Bug: Separate Rules Act as OR, Not AND

0
·1 views

A developer building a CEL authorization policy for agentgateway discovered that listing multiple expressions under matchExpressions applies OR logic, not AND, meaning a request is allowed if any single condition is satisfied. In testing, a caller from a restricted jurisdiction (Iran) was incorrectly granted access because the model check passed, while an unapproved model request also slipped through because the country check passed. Neither misconfiguration triggered an error, and the policy status showed as healthy in both cases. The fix is to combine all conditions into a single matchExpressions entry joined with && operators, rather than using separate list items. The behavior is documented but easy to misread, making the bug particularly risky since it silently permits traffic that should be denied.

Read the full story at DEV Community

This is an AI-generated summary. ShortSingh links to the original source for the complete article.

Discussion (0)

Log in to join the discussion and vote.

Log in

Related stories

0
ProgrammingDEV Community ·

Hybrid Retrieval Combines Keyword and Semantic Search to Improve RAG Systems

Vector search, which finds documents based on semantic similarity, struggles with exact-match queries such as error codes, product IDs, and technical terms. Hybrid retrieval addresses this by combining multiple search methods — including keyword matching and semantic similarity — to improve information retrieval accuracy. For instance, a keyword search can directly locate a document containing 'ERR-1042', while semantic search handles conceptually related but differently worded queries. Complex questions, such as diagnosing a payment service failure after a deployment, may require pulling from several document types simultaneously, something a single search method cannot reliably handle. Hybrid retrieval systems tackle this by running multiple retrieval strategies in parallel and merging the results for a more complete answer.

0
ProgrammingDEV Community ·

Developer builds AI task router for OpenCode using TypeSafe's Jev model via OpenRouter

A developer has created a custom routing tool for OpenCode that uses TypeSafe's Jev AI model, accessed through the OpenRouter API, to classify implementation plans. The tool evaluates tasks against three criteria — coordination, uncertainty, and consequences — calculating complexity as the maximum of the first two. Based on this scoring, tasks are routed to either a 'lite' path for localized, straightforward changes or a 'build' path for complex, cross-cutting work requiring design judgment. The approach draws on published ideas around decomposed probabilistic questioning and structured JSON scoring vectors rather than single-shot problem solving. The complete source code, written in TypeScript as an OpenCode plugin, was shared publicly by the developer alongside the methodology.

0
ProgrammingDEV Community ·

Airport VS Code Extension Lets Developers Monitor Multiple AI Coding Agents at Once

A developer has released Airport, a free, open-source VS Code extension designed to simplify the management of multiple AI coding agents running in parallel. The tool addresses a common pain point where agents like Claude Code, Codex, and Devin become difficult to track across different projects and terminal windows. Airport provides a dedicated sidebar with live status indicators, showing which agent terminals require user attention and which are idle. It also includes features such as multi-workspace support, a dynamic files view, one-click agent launching, and session resume across workspace restarts. The extension is available on the VS Code Marketplace and on GitHub, and works by hooking into VS Code's shell integration API to monitor terminal output.

0
ProgrammingDEV Community ·

Why AI Agents Must Have an Execution Boundary Between Intent and Action

AI agents capable of modifying external systems pose a reliability and safety risk when their decisions directly trigger real-world side effects without structured controls. A core problem arises in scenarios like publishing a page, where a timed-out response can cause duplicate actions or unintended consequences if the agent retries without checks. The proposed solution is an execution boundary — a dedicated application layer that handles validation, authorization, policy enforcement, idempotency, approvals, and auditing separately from the AI model's reasoning. Rather than acting directly, the agent proposes a structured action object, and deterministic application code decides whether that action is permitted and safe to execute. This separation ensures the model contributes intent while the application retains full authority over consequential operations.

AgentGateway CEL Policy Bug: Separate Rules Act as OR, Not AND · ShortSingh