Articles

SNMP and network telemetry: polling, traps and the security levels that matter

Polling is a pull the manager starts; a trap or an inform is a push the agent starts.

Reading: 5 minNetworking

Article cover: SNMP and network telemetry: polling, traps and the security levels that matter

Essential answer. SNMP (Simple Network Management Protocol) is how a management station reads and changes the state of network devices. A manager polls an agent for named values; the agent can also push a notification when something happens. SNMP runs over UDP - the agent listens on port 161, the notification receiver on port 162 - and each message rides one datagram. Three frameworks exist: SNMPv1, SNMPv2c and SNMPv3. Only SNMPv3 defines message-level security and access control, through three ordered security levels: noAuthNoPriv, authNoPriv and authPriv.

The mental model: a manager, an agent, two directions

SNMP has two roles and two directions of traffic. An entity holding command generator or notification receiver applications is the manager; one holding command responder or notification originator applications is the agent. The manager pulls: it asks for named values and waits for a response. The agent pushes: when it decides an event is worth reporting, it sends a notification.

        POLL (pull)                          NOTIFY (push)
  manager            agent             agent            receiver
     |  GetRequest        |               |   Trap / Inform   |
     |  GetNextRequest    |               |                   |
     |  GetBulkRequest    |               |                   |
     |  SetRequest        |               |                   |
     |<-------- Response -|               |---- Response ----->|  Inform only

The values live in a Management Information Base (MIB), a virtual information store of managed objects. Each object is named by an OBJECT IDENTIFIER (OID), a numeric path, and a variable binding pairs that name with its value. The manager never reads device memory directly, only the objects the agent exposes.

Terms you need

An SNMP engine carries the message processing, security and access-control subsystems. A securityModel and a securityName say who is asking; a context names where the information lives. A PDU (Protocol Data Unit) is the operation a message carries. The securityLevel is attached to every message and has three ordered values: noAuthNoPriv, authNoPriv (authenticated) and authPriv (authenticated and encrypted).

Reading values by polling, step by step

  1. The manager sends a GetRequest-PDU naming the objects it wants; the agent answers with a Response-PDU holding the same names and their values.
  2. To walk a table whose rows it does not know, it sends GetNextRequest, which returns the lexicographic successor of the name given, repeating with the name just returned until the answer leaves the table.
  3. For bulk collection it sends GetBulkRequest, whose non-repeaters and max-repetitions fields ask for many rows in one exchange, returning N + (M x R) variable bindings.
  4. To change a value it sends SetRequest: every binding is validated first, then all are altered together.

RFC 3416 shows the walk on an address-translation table: GetNextRequest ( sysUpTime, ipNetToMediaPhysAddress, ipNetToMediaType ), then a Response carrying sysUpTime.0 = “123456”.

Notifications: trap versus inform

The agent pushes events with two PDUs. An SNMPv2-Trap-PDU is unconfirmed: the sender gets no acknowledgement, so it cannot tell a dropped notification from a quiet network. An InformRequest-PDU is confirmed: the receiver replies with a Response-PDU. Both begin with sysUpTime.0 and snmpTrapOID.0. Which target, version and credentials to use is the originator’s decision per notification; where that must be SNMP-manageable, RFC 3413 requires the SNMP-TARGET-MIB.

Where the security levels actually live

SNMPv3 adds message security and access control. The User-based Security Model (USM) gives the three levels meaning: at authNoPriv the message is authenticated, and only then is the timeliness check performed; at authPriv the scopedPDU is also encrypted. Authentication is HMAC-MD5-96 (must be supported) and HMAC-SHA-96 (should be); privacy is CBC-DES, the first privacy protocol defined, with CFB128-AES-128 added by RFC 3826. Replay is bounded by a 150-second time window and a designated authoritative engine per exchange - the receiver for a confirmed PDU, the sender for an unconfirmed one.

 securityLevel        authentication   privacy
 noAuthNoPriv              no            no
 authNoPriv               yes            no
 authPriv                 yes           yes
 ordered:  noAuthNoPriv  <  authNoPriv  <  authPriv

Access control is separate. The View-based Access Control Model (VACM) maps a securityModel and a securityName to a group, the group with a context and a securityLevel to an access entry, and that entry to three MIB views - read, write and notify - where a view is a set of view subtrees, each an OID prefix.

Limits and the common errors

The first error is to treat “SNMPv3” as a switch that makes management traffic secure. The framework allows noAuthNoPriv, and a message is protected only when the user is configured for it: a v3 user at noAuthNoPriv is no stronger than the older frameworks. The second is to trust a trap, which is unconfirmed by design - use an inform where delivery matters. The older frameworks rely on a community-based, model-dependent security ID; RFC 3411 names community names as one example and calls SNMPv2c experimental, but defines no message security or access control for them.

Telemetry is the wider frame. NIST SP 800-215 describes network monitoring tools that gather data for visibility and alerting and feed incident response and SOC work; the SNMP standards describe the exchange, not which metrics to collect.

Level and prerequisites

L3 - integration and technical control. The sheet assumes the L1 vocabulary on IPv4/IPv6 prefixes, UDP ports and the packet journey, and does not repeat it: the SNMP datagram rides the ordinary UDP path. Its siblings are the L3 syslog sheet, which owns event severity and log transport, and NetFlow/IPFIX, which owns flow telemetry. The new skill here is reading the request/response shape, telling polling from notification, and treating the security level as a per-message choice.

Where to go next

References

  • RFC 3411 - An Architecture for Describing Simple Network Management Protocol (SNMP) Management Frameworks (2002).
  • RFC 3413 - Simple Network Management Protocol (SNMP) Applications (2002).
  • RFC 3414 - User-based Security Model (USM) for version 3 of the Simple Network Management Protocol (SNMPv3) (2002).
  • RFC 3415 - View-based Access Control Model (VACM) for the Simple Network Management Protocol (SNMP) (2002).
  • RFC 3416 - Version 2 of the Protocol Operations for the Simple Network Management Protocol (SNMP) (2002).
  • RFC 3417 - Transport Mappings for the Simple Network Management Protocol (SNMP) (2002).
  • RFC 3826 - The Advanced Encryption Standard (AES) Cipher Algorithm in the SNMP User-based Security Model (2004).
  • NIST SP 800-215 - Guide to a Secure Enterprise Network Landscape (2022).
Nodrius Field Kit — cover

Get the Nodrius Field Kit

Enter your email and we'll send you the complete Field Kit: eight technical resources in one download.

Your email address is sent to Nodrius and used to deliver the Field Kit to you by email. Marketing messages are separate and optional: the checkbox does not affect your download, and you are only added to our updates list if you tick it. Privacy Policy.

Privacy & cookies

This site does not use cookies, analytics or tracking, and it does not profile you. There is nothing technical to switch off, so Accept and Reject change nothing about how the site works: either choice lets you browse everything normally.

The only difference is what your browser remembers: two entries in local storage — your choice here, so this notice is not shown again, and a marker that the Field Kit offer has already been made — so the offer is presented once and not on every page. They contain no identifier, they are not shared with anyone, and the site sets no cookie for either.

What we do with your data
How your email address is used when you ask for a Resource, how long it is kept and which rights you have — in the Privacy Policy.
What the site stores in your browser
Two entries in local storage — your choice on this notice and whether the Field Kit offer has been shown — and no cookies, no session storage, no third-party content: in the Cookie Policy.