Published on January 18, 2025
SNMP (Simple Network Management Protocol) enables network administrators to manage devices such as routers, switches, and servers. A key component of SNMP is the Management Information Base (MIB), a hierarchical database used to monitor and manage network devices.
The following table highlights important MIB values and their corresponding functions in a Windows environment. These values are crucial for obtaining insights into system performance, active processes, and other device metrics:
MIB Value | Description |
---|---|
1.3.6.1.2.1.25.1.6.0 | System Processes |
1.3.6.1.2.1.25.4.2.1.2 | Running Programs |
1.3.6.1.2.1.25.4.2.1.4 | Processes Path |
1.3.6.1.2.1.25.2.3.1.4 | Storage Units |
1.3.6.1.2.1.25.6.3.1.2 | Software Name |
1.3.6.1.4.1.77.1.2.25 | User Accounts |
1.3.6.1.2.1.6.13.1.3 | TCP Local Ports |
To identify devices with SNMP services, use the following Nmap command to scan for open SNMP ports (default is UDP port 161):
sudo nmap -sU --open -p 161 {target-range} -oG open-snmp.txt
This command outputs a list of hosts with open SNMP ports, which can then be further analyzed for vulnerabilities.
Once an open SNMP port is discovered, you can use snmpwalk
to query specific MIB values and gather detailed information. Below are essential snmpwalk commands:
snmpwalk -c public -v1 {target-IP} 1.3.6.1.2.1.25.4.2.1.2
snmpwalk -c public -v1 {target-IP} 1.3.6.1.4.1.77.1.2.25
snmpwalk -c public -v1 {target-IP} 1.3.6.1.2.1.25.6.3.1.2
snmpwalk -c public -v1 {target-IP} 1.3.6.1.2.1.6.13.1.3
Onesixtyone is a tool designed to perform brute force attacks on SNMP community strings. To use this tool, you need two files: a list of IP addresses and a file containing potential community strings. Here's an example usage:
echo public > community
echo private >> community
echo manager >> community
for ip in $(seq 1 254); do echo 192.168.50.$ip; done > ips
onesixtyone -c community -i ips
This will scan the specified IP range and attempt to match community strings. Once valid SNMP services are identified, further enumeration can be performed using snmpwalk
or similar tools.
snmpwalk
to query key MIB values for system insights.SNMP enumeration is a powerful technique for gathering network data. Properly understanding its capabilities and ensuring secure configurations can significantly enhance network management and penetration testing efforts.