Skip to content

Preserve fail-closed LLM gateway admission evidence behind contextual-orchestrator #89

Description

@seonghobae

Problem and authority boundary

Wardnet must preserve fail-closed credential/admission, framing, header-minimization and streaming security behavior at its LLM-facing gateway seam without becoming the model/provider-routing authority.

contextual-orchestrator (CO) is the canonical owner of production LLM provider/model discovery, routing/fallback, concrete model selection, provider credentials and provider-specific transport differences. Wardnet must not own a LiteLLM deployment surface, virtual-key authority, provider/model/group selector, provider credential registry, or direct paid-provider fallback.

Wardnet remains responsible for the gateway/security-control side of the seam: fail-closed admission of the request/credential class required by a released CO contract, bounded request/framing validation, header minimization, security evidence, credential non-disclosure, safe streaming relay where Wardnet actually proxies a released CO interface, and denial before upstream work when Wardnet policy fails.

Current preservation lane — 2026-09-05

PR #88 remains open at exact 98a935e4b058d0500d520425b8ebf6ff4106aa1b and GitHub now correctly records it as Draft. It is non-mergeable by architecture in its current direct-LiteLLM shape and remains a preservation lane rather than the production integration vehicle.

Fresh contextual-orchestrator GitHub Release inventory is still empty. Wardnet therefore has no immutable compatible CO API/client/schema Agent to pin. A mutable CO branch/head, sibling checkout, direct provider SDK, or copied routing implementation is not an acceptable substitute.

Do not close #88 merely because its architecture is superseded. Preserve and later transfer every still-valid Wardnet-owned delta, test, fixture, security rationale and hostile proof before a successor retires it.

Evidence that must survive reconstruction

  • bounded Authorization/request credential grammar and fail-closed missing/duplicate/wrong-scheme/malformed/non-ASCII/oversized handling;
  • zero-upstream-hit negative tests for invalid credential classes;
  • no submitted credential or masked fragment in errors/events/audit/support/telemetry;
  • narrow request-header forwarding with cookies, management credentials, forwarding/proxy, host, framing and unrelated trace baggage stripped;
  • redirects and ambient proxies disabled where Wardnet owns the HTTP boundary;
  • request path/query/method and bounded-body preservation required by the released upstream contract;
  • streaming response relay without whole-response buffering;
  • safe correlation/rate-limit metadata only when the released upstream contract permits it;
  • stable property tests and fuzz coverage for the same untrusted credential/request grammar;
  • existing non-LLM Wardnet route behavior remains unchanged.

Historical LiteLLM/provider-specific implementation details are preservation evidence only. They do not become current architecture authority.

Replacement contract after CO release

When contextual-orchestrator publishes an immutable compatible release, reconstruct the Wardnet consumer slice from fresh protected Wardnet main through an Anti-Corruption Layer.

  1. Consume only the released CO API/client/schema Agent and bind exact version/digest/provenance.
  2. Remove direct LiteLLM/provider/model/group/paid-fallback authority from Wardnet.
  3. Keep model/provider selection absent from Wardnet-owned domain/API state unless CO exposes an opaque capability/request field that grants no provider authority.
  4. Fail closed when the required CO release/schema/capability/provenance is absent, stale, malformed, incompatible or unverifiable.
  5. Transfer the Wardnet-owned security regressions above against the actual released CO boundary and prove zero direct provider/LiteLLM calls from Wardnet.
  6. Keep GitHub Actions model-backed use on the organization-owned orchestrator/free gateway contract only; no provider/model/group/paid fallback pin belongs in Wardnet.
  7. Update the Wardnet Context Map/ADR/SECURITY/THREAT_MODEL/TRACEABILITY/CHANGELOG and the sole product-gap writer with released-contract evidence rather than mutable source claims.
  8. Reacquire every exact-current-head CI/security/coverage/package/SBOM/provenance/review/thread/governance gate after reconstruction. draft(architecture): preserve credential-guard evidence pending CO release #88 predecessor evidence does not transfer.

Explicit non-goals

  • Wardnet does not authenticate provider virtual-key existence, revocation, budget, team or model scope.
  • Wardnet does not manufacture or repair a provider credential.
  • Wardnet does not choose a concrete model/provider or silently fall back to a paid provider.
  • Wardnet does not embed contextual-orchestrator or copy its routing implementation.
  • This issue does not weaken non-LLM gateway authentication or generic request-security controls.

Completion gate

Close only after an immutable compatible CO release exists and a protected-main Wardnet successor consumes it through a versioned ACL with every still-valid #88 Wardnet-owned security delta demonstrably transferred or specifically proven obsolete. The successor must have one unchanged exact head with terminal repository/security/coverage/package/SBOM/provenance/review/thread/governance evidence. No mutable foreign dependency, self/model approval, routine bypass, force push, gate weakening or predecessor-evidence reuse.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area: accessibilityAccessibility and assistive-technology supportarea: authAuthentication, authorization, identity, or tenant isolationarea: ci-cdCI, GitHub Actions, checks, release, or supply chainarea: securitySecurity boundary, hardening, or vulnerability preventionpriority: mediumNormal-priority or P2 workstatus: triagedOpen issue has an organization taxonomy assignmenttype: featureNew or expanded product capability

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions