DEV Community

kozhevniko
kozhevniko

Posted on

snmp_exporter can turn a web request into a network-management probe

snmp_exporter can turn a web request into a network-management probe

The SNMP exporter lets Prometheus scrape devices that speak SNMP. It listens on a web port, commonly 9116, and uses target parameters to choose the device it will query. The exporter is a useful bridge between modern monitoring and older network equipment. It is also a small service with access to management credentials and device reachability.

The measurements

The count-only queries from November 5, 2026 returned:

Query Matches UTC time
port="9116" 3 2026-11-05T00:40:47Z
app="snmp_exporter" 0 2026-11-05T00:40:49Z
http.body="snmp_exporter_build_info" 1 2026-11-05T00:40:52Z

All queries succeeded. The application fingerprint did not identify the service. The port and body counts are small enough for an owner-by-owner review, but they remain candidate observations, not verified exposures.

The exporter sits between two networks

Prometheus calls the exporter over HTTP. The exporter then sends SNMP requests to a target device using a configured module. The module chooses authentication and privacy settings, OIDs, and timeouts. The target parameter may be supplied through Prometheus relabeling or a direct request.

An exposed exporter endpoint can reveal which device address was queried and how long the probe took. It can also cause the exporter to send requests from its own network position. Restrict the endpoint to the Prometheus server and review which target values it accepts.

Use SNMPv3 with authentication and privacy where the device supports it. Store credentials in a protected file and avoid logging the community string or authentication keys. The exporter's configuration should be loaded from a version-controlled, non-world-readable path.

The device side matters

SNMP access may expose interface names, system descriptions, routing data, and device health. A read-only community string can still disclose the network map. A write-capable credential raises the consequence substantially. Use an account or community with the minimum view required by the monitoring template.

Apply an access list on the monitored device so only the exporter can query it. Keep the exporter's outbound path separate from the public internet. A host that can reach every management network is a high-value monitoring asset and should have a correspondingly narrow web surface.

Verify a target safely

Use an owned device and a read-only test OID. Confirm the exporter returns expected metrics, then confirm a request from an ordinary user network is denied. Review the web logs for target values and source addresses. Do not send SNMP queries to unrelated devices or use default community strings as a discovery method.

If the endpoint was reachable from an untrusted network, preserve the exporter's logs and the device's SNMP access logs. Look for query volume or target changes. Rotate credentials if the host or configuration was exposed, then validate that the device still accepts the exporter from the approved address.

The counts are small, but the trust relationship is larger than the port suggests. Inventory the exporter, the devices it can query, the credential scope, and the network path before deciding that a three-match result is harmless.

References

Top comments (0)