mirror of
https://github.com/kvcache-ai/AgentENV.git
synced 2026-11-05 01:17:36 +00:00
[GH-ISSUE #450] Admin authentication header differs between OpenAPI and server implementation #112
Labels
No labels
bug
documentation
enhancement
enhancement
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
kvcache-ai/AgentENV#112
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @guozy18 on GitHub (Oct 29, 2026).
Original GitHub issue: https://github.com/kvcache-ai/AgentENV/issues/450
Documentation problem
Incorrect
Location
src/api/openapi.yml (AdminApiKeyAuth); src/api/impls/auth.rs
Current content or problem
GET /nodes is documented with
X-Admin-Token, but the server checksx-api-key. The authentication adapter ignores the supplied header-name argument, so clients following the schema receive 401 even with the correct key.With the same valid key:
X-Admin-Token: <key>→ HTTP 401x-api-key: <key>→ HTTP 200This mismatch already exists on main; it was exposed by #341's snapshot-pull client.
Suggested correction
Choose one supported header and align the OpenAPI schema, server authentication, and clients. Add a regression test through the actual /nodes authentication path.
Additional context
Verified at
aed3eca2using unchanged Rust authentication code and the generated /nodes handler in an isolated HTTP harness (node-list payload stubbed). The original Go snapshot fetcher also received 401. This was not a full node deployment.The authentication implementation is unchanged from the PR base:
Contribution
I am only reporting the problem
Pre-submission checklist