Skip to content
BoKSA

06: Network Management: SNMP and Beyond

06: Network Management: SNMP and Beyond

Course: Networking - Security Advanced · Updated: October 2026 Literature: K&R chapter 5: network management and configuration (SNMP, NETCONF/YANG) Related lab: Lab: SNMP, using the VM HvA-NE1-Debian-v1.2.ova

Learning objectives

After studying this article you can:

  • explain what network management is and why it is needed
  • describe the components of a network management architecture: managing server, managed device, agent, MIB, protocol
  • explain how SNMP works: versions, PDU types, MIB and OID tree, polling and traps
  • explain the security differences between SNMPv1/v2c and SNMPv3
  • describe the modern alternatives: NETCONF, RESTCONF, YANG, gNMI and streaming telemetry

1. What is network management?

"Network management includes the deployment, integration and coordination of the hardware, software, and human elements to monitor, test, poll, configure, analyze, evaluate, and control the network and element resources to meet the real-time, operational performance, and Quality of Service requirements at a reasonable cost." (Saydam & Magedanz, quoted in K&R)

In practice, network administrators want to:

  • detect failures (an interface goes down, a router stops responding)
  • monitor performance (link utilisation, errors, latency)
  • track changes and configure devices consistently
  • detect intrusions and abnormal traffic
  • plan capacity and meet Service Level Agreements (SLAs)

The classic FCAPS model groups these tasks: Fault, Configuration, Accounting, Performance and Security management.

2. The network management architecture

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
            +---------------------------+
            |   Managing server         |   ← human operator, dashboards, alerts
            |   (Network Management     |
            |    System, NMS)           |
            +-------------+-------------+
                          |  network management protocol (SNMP, NETCONF, gNMI)
        +-----------------+------------------+
        |                 |                  |
  +-----v-----+     +-----v-----+      +-----v-----+
  | agent     |     | agent     |      | agent     |
  | MIB data  |     | MIB data  |      | MIB data  |
  +-----------+     +-----------+      +-----------+
   managed device    managed device     managed device
   (router)          (switch)           (server, printer, UPS, ...)
Component Role
Managing server Application that collects data, shows dashboards and sends alerts (e.g. Zabbix, LibreNMS, PRTG, Prometheus)
Managed device Equipment that is managed: router, switch, host, firewall, printer, ...
Agent Process on the managed device that talks to the managing server
MIB Management Information Base: the data that can be read or changed on the device
Protocol How the server and agent communicate: SNMP, NETCONF, ...

3. SNMP: Simple Network Management Protocol

SNMP runs over UDP: port 161 for requests to the agent and port 162 for traps to the manager.

3.1 Two ways to communicate

  1. Request/response (polling): the manager asks for a value and the agent answers.
  2. Trap / notification: the agent tells the manager without being asked that something has happened (e.g. "link down").

3.2 SNMP PDU types

PDU type Direction Purpose
GetRequest manager → agent Read the value of one or more objects
GetNextRequest manager → agent Read the next object in the MIB tree (used to "walk" the tree)
GetBulkRequest (v2+) manager → agent Read a large block of data in one request
SetRequest manager → agent Change a value (configuration)
Response agent → manager Answer to a request
Trap / SNMPv2-Trap agent → manager Unsolicited notification
InformRequest manager/agent → manager Notification that is acknowledged

3.3 The MIB and OIDs

Every manageable object has a unique Object Identifier (OID), which is a path in a worldwide tree. The objects are defined in the SMI language (Structure of Management Information).

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
iso(1)
 └─ org(3)
     └─ dod(6)
         └─ internet(1)
             ├─ mgmt(2)
             │   └─ mib-2(1)
             │       ├─ system(1)        → sysDescr (1.3.6.1.2.1.1.1), sysUpTime, sysName ...
             │       ├─ interfaces(2)    → ifTable: ifDescr, ifInOctets, ifOutOctets ...
             │       ├─ ip(4)
             │       ├─ tcp(6)
             │       └─ udp(7)
             └─ private(4)
                 └─ enterprises(1)       → vendor-specific MIBs (Cisco = 9, ...)

Example with the net-snmp command-line tools (as in the lab):

1
2
3
4
5
6
7
# Read the system description with SNMPv3 (auth + encryption)
snmpget  -v3 -l authPriv -u monitor -a SHA-256 -A 'authpass' -x AES -X 'privpass' \
         192.168.56.10 SNMPv2-MIB::sysDescr.0

# Walk the interfaces table
snmpwalk -v3 -l authPriv -u monitor -a SHA-256 -A 'authpass' -x AES -X 'privpass' \
         192.168.56.10 IF-MIB::ifTable

3.4 SNMP versions

Version Year Security
SNMPv1 1990 A community string (a password sent in plain text, often public / private)
SNMPv2c 1996 Same community string model, plus GetBulk and 64-bit counters
SNMPv3 2002 (RFC 3411–3418) User-based Security Model (USM): authentication (HMAC), encryption (AES), protection against replay. View-based Access Control (VACM): which user may see or change which part of the MIB.

SNMPv3 security levels:

Level Authentication Encryption
noAuthNoPriv No No
authNoPriv Yes No
authPriv Yes Yes ← use this

4. Beyond SNMP: modern network management

SNMP is still everywhere for monitoring, but it was never popular for configuration. SetRequest is clumsy, it has no transactions, and MIBs are hard to work with. Since about 2010 the IETF and the industry have moved to model-driven management:

Technology Description
YANG (RFC 7950) A data-modelling language for configuration and state data. It plays the role that the MIB plays for SNMP. There are vendor-neutral models (IETF, OpenConfig) and vendor models.
NETCONF (RFC 6241) A protocol to read and change configuration, over SSH (or TLS), with XML encoding. It supports transactions: lock, edit-config, validate, commit, and rollback when something goes wrong.
RESTCONF (RFC 8040) The same YANG data through a REST/HTTPS API with JSON or XML. Easy to use from scripts.
gNMI / gRPC (OpenConfig) Google's management interface. It carries streaming telemetry: devices push data continuously instead of being polled.
Streaming telemetry Much higher resolution (sub-second) and scale than SNMP polling every 5 minutes
Network automation Ansible, Nornir, Terraform and NAPALM. Configuration is stored in Git ("infrastructure as code") and rolled out through CI/CD pipelines.
Observability stack Prometheus + Grafana, the Elastic stack and OpenTelemetry. They combine metrics, logs and flow data (NetFlow/IPFIX).

Example of a NETCONF transaction:

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
<rpc message-id="101" xmlns="urn:ietf:params:xml:ns:netconf:base:1.0">
  <edit-config>
    <target><candidate/></target>
    <config>
      <interfaces xmlns="urn:ietf:params:xml:ns:yang:ietf-interfaces">
        <interface>
          <name>eth0</name>
          <description>Uplink to core</description>
          <enabled>true</enabled>
        </interface>
      </interfaces>
    </config>
  </edit-config>
</rpc>
<!-- followed by <commit/> : the change becomes active atomically -->

5. Summary

  • Network management = monitoring + configuration + fault, performance and security management (FCAPS).
  • SNMP: manager, agent and MIB. Polling over UDP 161 and traps over UDP 162. OIDs form a global tree.
  • Only SNMPv3 with authPriv is secure. v1 and v2c send their "password" in plain text.
  • For configuration, the world has moved to YANG + NETCONF/RESTCONF/gNMI, automation and streaming telemetry.

References

Videos

Articles

Standards

  • RFC 3411–3418: SNMPv3 architecture, USM, VACM
  • RFC 7860: HMAC-SHA-2 authentication protocols in SNMPv3 USM
  • RFC 3826: AES cipher in SNMPv3 USM
  • RFC 6241: NETCONF · RFC 8040: RESTCONF · RFC 7950: YANG 1.1

Tools


Cyber Security

Why it matters

Network management systems hold the keys to the whole network. They can read and change the configuration of every device. That makes them a favourite target:

  • Default community strings: many devices still ship with public (read) and private (read-write). With a read-write community, an attacker can change routes, download the device configuration (including password hashes), or shut down interfaces.
  • Information disclosure: even read-only SNMP reveals a lot: the system description and software version (which helps an attacker find exploits), interfaces, routing tables, ARP tables, running processes, installed software and user accounts. This is a gold mine for reconnaissance (tools: onesixtyone, snmp-check, Metasploit).
  • Plain-text protocols: SNMPv1/v2c communities can be captured by anyone who can sniff the traffic (try it in Wireshark!).
  • Amplification DDoS: open SNMP agents on the Internet reflect small GetBulk requests as large responses towards a victim.
  • Vulnerabilities in agents: e.g. the Cisco IOS SNMP remote-code-execution bugs (CVE-2017-6736 and later), which have been exploited by state actors.
  • Supply-chain attacks on the NMS: the SolarWinds Orion compromise (2020) showed that a network-management platform can become a backdoor into thousands of organisations.
  • Living off the land: state actors (e.g. Volt Typhoon, Salt Typhoon) target network devices and management interfaces precisely because they are rarely monitored.

How to make it safe

  1. Use SNMPv3 with authPriv only: SHA-2 authentication (SHA-256 or stronger) and AES encryption. Disable SNMPv1/v2c completely. If v2c can't be avoided, use long random community strings and read-only access.
  2. Never use read-write SNMP unless you need it, and use NETCONF/RESTCONF over SSH/TLS for configuration changes. (Note: the 2017 lab used createUser ... MD5 with rwuser, which was fine for learning but should not be used in production.)
  3. Restrict access: allow SNMP only from the management server's IP addresses (ACLs on the device and firewall rules), and use VACM views to limit which part of the MIB can be read.
  4. Keep a separate management network: use out-of-band management (a separate VLAN/VRF, a jump host or bastion, and MFA). Never expose management interfaces (SNMP, SSH, web GUI) to the Internet.
  5. Patch and harden network devices, and remove unused services. Follow vendor hardening guides and CIS Benchmarks.
  6. Protect the NMS itself: keep it patched, give it minimal privileges, apply network segmentation, monitor it, and check the integrity of updates.
  7. Store configuration in Git, with review and change logs. Compare running configurations with the approved baseline to detect unauthorised changes.
  8. Use traps and telemetry for security: send authentication failures, configuration changes and link events to your SIEM (see article 17).

Extra references