Admin/control plane should emit Server: AISIX/<version> response header
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 157
- Forks
- 32
- Avg merge
- 1h 25m
- Merged PRs (30d)
- 145
Description
Context
PR #415 added Server: AISIX/<CARGO_PKG_VERSION> to every data plane response via a tower_http::SetResponseHeaderLayer::overriding(...) mounted on aisix-proxy::build_router. The independent audit on that PR surfaced a parallel gap on the admin/control plane:
aisix-admin's/metricsand admin endpoints today return noServerheader. Out of scope for #415 (DP-only contract), but the same arguments apply: clients/intermediaries identifying the gateway, and never leaking an upstreamServerif one ever bleeds through.
Smoke-test:
$ curl -sI http://127.0.0.1:<admin-port>/metrics
HTTP/1.1 200 OK
content-type: text/plain; ...
# no Server header
What this issue tracks
Mount an equivalent SetResponseHeaderLayer::overriding(header::SERVER, "AISIX/<CARGO_PKG_VERSION>") on aisix-admin::build_router so admin / metrics responses also carry the gateway identity. Cover with a lib-level test that asserts the header on a representative admin response (e.g. /metrics 200 and an admin-auth 401).
References
- PR #415 — data plane implementation, audit, and test pattern
- RFC 9110 §10.2.4 —
product/versionServer header format
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start in aisix-admin::build_router and compare its response-layer setup with the data-plane implementation from PR #415. Check the existing lib-level test structure, then cover /metrics and an admin-authenticated 401 response. Done means representative admin and metrics responses expose the AISIX version Server header while replacing any upstream value.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- api, backend
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Quiet
- Clarity
- Clearly specified
- Newbie friendliness
- 64/100