For the complete documentation index, see llms.txt. This page is also available as Markdown.

Pentesting Prometheus

Prometheus commonly exposes HTTP on TCP/9090. If unauthenticated, it can leak version, runtime flags, scrape targets, config paths, and debug endpoints.

Discovery

Nmap/WhatWeb indicators:

9090/tcp open  http  Golang net/http server
| http-title: Prometheus Time Series Collection and Processing Server
|_Requested resource was /graph
http://TARGET:9090/graph
Title[Prometheus Time Series Collection and Processing Server]

Useful Endpoints

Version and runtime details:

http://TARGET:9090/status

Observed useful values:

Working directory: /
Configuration reload: Successful
Storage retention: 15d
version: 2.32.1
buildUser: root@54b6dbd48b97
goVersion: go1.17.5

Targets:

Observed target output:

Metrics and flags:

Debug endpoints:

Config File Locations

If you have file read through another service, check the systemd service first to find Prometheus paths:

Observed service:

Then read the config:

Useful paths from that service:

Metasploit Gather

Metasploit can dump Prometheus config and target data:

Useful output:

Example leaked config:

Last updated