How to fix: Consul HTTP API Reachable Without Authentication
The response carries the X-Consul-Index and X-Consul-Knownleader headers that Consul's HTTP API attaches to every catalog/health/KV query, together with a JSON body that is not an ACL-denied error, confirming the Consul agent's API is reachable and answering queries without a valid ACL token.
Why it matters
An open Consul API exposes the full service catalog (every service name, its healthy/unhealthy instances, and internal IP:port pairs), health check definitions, and, if the KV store is reachable too, any configuration values or secrets teams have stored there. This hands an attacker a live map of the internal network topology.
Consul is meant to be queried only by trusted internal clients, service mesh sidecars, and operators, with ACLs enabled and a token required on every request. When ACLs are disabled or a default-allow policy is used, any request from any source that can reach the agent's HTTP port succeeds.
How to fix it
- 1Enable Consul ACLs with a default-deny policy: set acl.enabled = true and acl.default_policy = "deny" in the agent configuration.
- 2Require a valid ACL token on every HTTP API request from clients and services.
- 3Bind the HTTP API to a private network interface (or 127.0.0.1 for local-only access) rather than 0.0.0.0.
- 4Put the Consul UI/API behind a firewall or security group that only allows the internal network and known operator IPs.
Code examples
Consul agent config: enable ACLs with default-deny
{
"acl": {
"enabled": true,
"default_policy": "deny",
"enable_token_persistence": true
},
"addresses": {
"http": "127.0.0.1"
}
}References
Detected automatically by VulnRadar. The check id is consul-api-exposed, stable across every scan so you can filter or diff on it.
More info disclosure checks
- MediumRails Session Cookie Missing HttpOnly Flag
- InfoServer header truncated
- InfoPHP session cookie naming exposes runtime
- Infoconfig.js / settings.js referenced (verify contents)
- Infoenv.js / environment.js referenced (verify contents)
- InfoSitemap.xml publicly accessible
- InfoOpenAPI schema version exposed in URL
- LowCORS exposes internal CDN hostname
Questions
- How severe is Consul HTTP API Reachable Without Authentication?
- VulnRadar rates this high severity in the info disclosure category. The severity is fixed per check, not scored per site, so the same finding is the same severity on every scan.
- Does VulnRadar check for this automatically?
- Yes. It runs as part of every scan under the check id consul-api-exposed, which stays the same between runs so you can filter, diff, or gate CI on it.
- Which standards does Consul HTTP API Reachable Without Authentication map to?
- It maps to CWE-306. In the OWASP Top 10 it falls under A07:2021.
Missing a check?
The detection set is open. If you know a misconfiguration this does not catch, propose it: the issue template asks for the threat model, how to detect it, the false-positive risk, and a test fixture, which is the same thing a maintainer would have to work out anyway.