RFC 5343 INTERNET STANDARD SNMP · MANAGEMENT · DISCOVERY

Simple Network Management Protocol (SNMP) Context EngineID Discovery

A way for a network manager to learn the identifier of a remote agent before it can query it.

On rfc-editor.org ↗
PUBLISHED
September 2008
AUTHORS
J. Schoenwaelder
STREAM
IETF
BUILDS ON
RFC 3411 — SNMP architecture
LOCALENGINEID VALUE
8000000006 in hexadecimal
SNMPENGINEID LENGTH
Between 5 and 32 octets
FORMAT OCTET POSITION
Fifth octet
ASSIGNED FORMAT VALUE
6, local engine
IANA CONTROLLED FORMAT VALUES
1 to 127
ENTERPRISE SPECIFIC RANGE
128 to 255
DOI
10.17487/RFC5343

RFC text

Contents
Original text · RFC Editor View on rfc-editor.org ↗
Network Working Group                                   J. Schoenwaelder
Request for Comments: 5343                      Jacobs University Bremen
Updates: 3411                                             September 2008
Category: Standards Track


  Simple Network Management Protocol (SNMP) Context EngineID Discovery

Status of This Memo

   This document specifies an Internet standards track protocol for the
   Internet community, and requests discussion and suggestions for
   improvements.  Please refer to the current edition of the "Internet
   Official Protocol Standards" (STD 1) for the standardization state
   and status of this protocol.  Distribution of this memo is unlimited.

Abstract

   The Simple Network Management Protocol (SNMP) version three (SNMPv3)
   requires that an application know the identifier (snmpEngineID) of
   the remote SNMP protocol engine in order to retrieve or manipulate
   objects maintained on the remote SNMP entity.

   This document introduces a well-known localEngineID and a discovery
   mechanism that can be used to learn the snmpEngineID of a remote SNMP
   protocol engine.  The proposed mechanism is independent of the
   features provided by SNMP security models and may also be used by
   other protocol interfaces providing access to managed objects.

   This document updates RFC 3411.

Table of Contents

   1.  Introduction  . . . . . . . . . . . . . . . . . . . . . . . . . 2
   2.  Background  . . . . . . . . . . . . . . . . . . . . . . . . . . 2
   3.  Procedure . . . . . . . . . . . . . . . . . . . . . . . . . . . 3
     3.1.  Local EngineID  . . . . . . . . . . . . . . . . . . . . . . 4
     3.2.  EngineID Discovery  . . . . . . . . . . . . . . . . . . . . 4
   4.  IANA Considerations . . . . . . . . . . . . . . . . . . . . . . 5
   5.  Security Considerations . . . . . . . . . . . . . . . . . . . . 6
   6.  Acknowledgments . . . . . . . . . . . . . . . . . . . . . . . . 7
   7.  References  . . . . . . . . . . . . . . . . . . . . . . . . . . 7
     7.1.  Normative References  . . . . . . . . . . . . . . . . . . . 7
     7.2.  Informative References  . . . . . . . . . . . . . . . . . . 7

1.  Introduction

   To retrieve or manipulate management information using the third
   version of the Simple Network Management Protocol (SNMPv3) [RFC3410],
   it is necessary to know the identifier of the remote SNMP protocol
   engine, the so-called snmpEngineID [RFC3411].  While an appropriate
   snmpEngineID can in principle be configured on each management
   application for each SNMP agent, it is often desirable to discover
   the snmpEngineID automatically.

   This document introduces a discovery mechanism that can be used to
   learn the snmpEngineID of a remote SNMP protocol engine.  The
   proposed mechanism is independent of the features provided by SNMP
   security models.  The mechanism has been designed to coexist with
   discovery mechanisms that may exist in SNMP security models, such as
   the authoritative engine identifier discovery of the User-based
   Security Model (USM) of SNMP [RFC3414].

   This document updates RFC 3411 [RFC3411] by clarifying the IANA rules
   for the maintenance of the SnmpEngineID format registry.

   The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
   "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this
   document are to be interpreted as described in RFC 2119 [RFC2119].

2.  Background

   Within an administrative domain, an SNMP engine is uniquely
   identified by an snmpEngineID value [RFC3411].  An SNMP entity, which
   consists of an SNMP engine and several SNMP applications, may provide
   access to multiple contexts.

   An SNMP context is a collection of management information accessible
   by an SNMP entity.  An item of management information may exist in
   more than one context and an SNMP entity potentially has access to
   many contexts [RFC3411].  A context is identified by the snmpEngineID
   value of the entity hosting the management information (also called a
   contextEngineID) and a context name that identifies the specific
   context (also called a contextName).

   To identify an individual item of management information within an
   administrative domain, a four tuple is used consisting of

   1.  a contextEngineID,

   2.  a contextName,
   3.  an object type, and

   4.  its instance identification.

   The last two elements are encoded in an object identifier (OID)
   value.  The contextName is a character string (following the
   SnmpAdminString textual convention of the SNMP-FRAMEWORK-MIB
   [RFC3411]) while the contextEngineID is an octet string constructed
   according to the rules defined as part of the SnmpEngineID textual
   convention of the SNMP-FRAMEWORK-MIB [RFC3411].

   The SNMP protocol operations and the protocol data units (PDUs)
   operate on OIDs and thus deal with object types and instances
   [RFC3416].  The SNMP architecture [RFC3411] introduces the concept of
   a scopedPDU as a data structure containing a contextEngineID, a
   contextName, and a PDU.  The SNMP version 3 (SNMPv3) message format
   uses ScopedPDUs to exchange management information [RFC3412].

   Within the SNMP framework, contextEngineIDs serve as end-to-end
   identifiers.  This becomes important in situations where SNMP proxies
   are deployed to translate between protocol versions or to cross
   middleboxes such as network address translators.  In addition,
   snmpEngineIDs separate the identification of an SNMP engine from the
   transport addresses used to communicate with an SNMP engine.  This
   property can be used to correlate management information easily, even
   in situations where multiple different transports were used to
   retrieve the information or where transport addresses can change
   dynamically.

   To retrieve data from an SNMPv3 agent, it is necessary to know the
   appropriate contextEngineID.  The User-based Security Model (USM) of
   SNMPv3 provides a mechanism to discover the snmpEngineID of the
   remote SNMP engine, since this is needed for security processing
   reasons.  The discovered snmpEngineID can subsequently be used as a
   contextEngineID in a ScopedPDU to access management information local
   to the remote SNMP engine.  Other security models, such as the
   Transport Security Model (TSM) [TSM], lack such a procedure and may
   use the discovery mechanism defined in this memo.

3.  Procedure

   The proposed discovery mechanism consists of two parts, namely (i)
   the definition of a special well-known snmpEngineID value, called the
   localEngineID, which always refers to a local default context, and
   (ii) the definition of a procedure to acquire the snmpEngineID scalar
   of the SNMP-FRAMEWORK-MIB [RFC3411] using the special well-known
   local localEngineID value.

3.1.  Local EngineID

   An SNMP command responder implementing this specification MUST
   register their pduTypes using the localEngineID snmpEngineID value
   (defined below) by invoking the registerContextEngineID() Abstract
   Service Interface (ASI) defined in RFC 3412 [RFC3412].  This
   registration is done in addition to the normal registration under the
   SNMP engine's snmpEngineID.  This is consistent with the SNMPv3
   specifications since they explicitly allow registration of multiple
   engineIDs and multiple pduTypes [RFC3412].

   The SnmpEngineID textual convention [RFC3411] defines that an
   snmpEngineID value MUST be between 5 and 32 octets long.  This
   specification proposes to use the variable length format 3) of the
   SnmpEngineID textual convention and to allocate the reserved, unused
   format value 6, using the enterprise ID 0 for the localEngineID.  An
   ASN.1 definition for localEngineID would look like this:

               localEngineID OCTET STRING ::= '8000000006'H

   The localEngineID value always provides access to the default context
   of an SNMP engine.  Note that the localEngineID value is intended to
   be used as a special value for the contextEngineID field in the
   ScopedPDU.  It MUST NOT be used as a value to identify an SNMP
   engine; that is, this value MUST NOT be used in the snmpEngineID.0
   scalar [RFC3418] or in the msgAuthoritativeEngineID field in the
   securityParameters of the User-based Security Model (USM) [RFC3414].

3.2.  EngineID Discovery

   Discovery of the snmpEngineID is done by sending a Read Class
   protocol operation (see Section 2.8 of [RFC3411]) to retrieve the
   snmpEngineID scalar using the localEngineID defined above as a
   contextEngineID value.  Implementations SHOULD only perform this
   discovery step when it is needed.  In particular, if security models
   are used that already discover the remote snmpEngineID (such as USM),
   then no further discovery is necessary.  The same is true in
   situations where the application already knows a suitable
   snmpEngineID value.

   The procedure to discover the snmpEngineID of a remote SNMP engine
   can be described as follows:

   1.  Check whether a suitable contextEngineID value is already known.
       If yes, use the provided contextEngineID value and stop the
       discovery procedure.

   2.  Check whether the selected security model supports discovery of
       the remote snmpEngineID (e.g., USM with its discovery mechanism).
       If yes, let the security model perform the discovery.  If the
       remote snmpEngineID value has been successfully determined,
       assign it to the contextEngineID and stop the discovery
       procedure.

   3.  Send a Read Class operation to the remote SNMP engine using the
       localEngineID value as the contextEngineID in order to retrieve
       the scalar snmpEngineID.0 of the SNMP-FRAMEWORK-MIB [RFC3411].
       If successful, set the contextEngineID to the retrieved value and
       stop the discovery procedure.

   4.  Return an error indication that a suitable contextEngineID could
       not be discovered.

   The procedure outlined above is an example and can be modified to
   retrieve more variables in step 3, such as the sysObjectID.0 scalar
   or the snmpSetSerialNo.0 scalar of the SNMPv2-MIB [RFC3418].

4.  IANA Considerations

   RFC 3411 requested that IANA create a registry for SnmpEngineID
   formats.  However, RFC 3411 did not ask IANA to record the initial
   assignments made by RFC 3411 nor did RFC 3411 spell out the precise
   allocation rules.  To address this issue, the following rules are
   hereby established.

   IANA maintains a registry for SnmpEngineID formats.  The first four
   octets of an SnmpEngineID carry an enterprise number, while the fifth
   octet in a variable length SnmpEngineID value, called the format
   octet, indicates how the following octets are formed.  The following
   format values were allocated in [RFC3411]:

     Format    Description                     References
     -------   -----------                     ----------
          0    reserved, unused                 [RFC3411]
          1    IPv4 address                     [RFC3411]
          2    IPv6 address                     [RFC3411]
          3    MAC address                      [RFC3411]
          4    administratively assigned text   [RFC3411]
          5    administratively assigned octets [RFC3411]
       6-127   reserved, unused                 [RFC3411]
     128-255   enterprise specific              [RFC3411]

   IANA can assign new format values out of the originally assigned and
   reserved number space 1-127.  For new assignments in this number
   space, a specification is required as per [RFC5226].  The number
   space 128-255 is enterprise specific and is not controlled by IANA.

   Per this document, IANA has made the following assignment:

     Format    Description                     References
     -------   -----------                     ----------
          6    local engine                     [RFC5343]

5.  Security Considerations

   SNMP version 3 (SNMPv3) provides cryptographic security to protect
   devices from unauthorized access.  This specification recommends use
   of the security services provided by SNMPv3.  In particular, it is
   RECOMMENDED to protect the discovery exchange.

   An snmpEngineID can contain information such as a device's MAC
   address, IPv4 address, IPv6 address, or administratively assigned
   text.  An attacker located behind a router / firewall / network
   address translator may not be able to obtain this information
   directly, and he therefore might discover snmpEngineID values in
   order to obtain this kind of device information.

   In many environments, making snmpEngineID values accessible via a
   security level of noAuthNoPriv will benefit legitimate tools that try
   to algorithmically determine some basic information about a device.
   For this reason, the default View-based Access Control Model (VACM)
   configuration in Appendix A of RFC 3415 [RFC3415] gives noAuthNoPriv
   read access to the snmpEngineID.  Furthermore, the USM discovery
   mechanism defined in RFC 3414 [RFC3414] uses unprotected messages and
   reveals snmpEngineID values.

   In highly secure environments, snmpEngineID values can be protected
   by using the discovery mechanism described in this document together
   with a security model that does not exchange cleartext SNMP messages,
   such as the Transport Security Model (TSM) [TSM].

   The isAccessAllowed() abstract service primitive of the SNMP access
   control subsystem does not take the contextEngineID into account when
   checking access rights [RFC3411].  As a consequence, it is not
   possible to define a special view for context engineID discovery.  A
   request with a localEngineID is thus treated like a request with the
   correct snmpEngineID by the access control subsystem.  This is inline
   with the SNMPv3 design where the authenticated identity is the
   securityName (together with the securityModel and securityLevel
   information), and transport addresses or knowledge of contextEngineID
   values do not impact the access-control decision.

6.  Acknowledgments

   Dave Perkins suggested the introduction of a "local" contextEngineID
   during the interim meeting of the ISMS (Integrated Security Model for
   SNMP) working group in Boston, 2006.  Joe Fernandez, David
   Harrington, Dan Romascanu, and Bert Wijnen provided helpful review
   and feedback, which helped to improve this document.

7.  References

7.1.  Normative References

   [RFC2119]  Bradner, S., "Key words for use in RFCs to Indicate
              Requirement Levels", BCP 14, RFC 2119, March 1997.

   [RFC3411]  Harrington, D., Presuhn, R., and B. Wijnen, "An
              Architecture for Describing Simple Network Management
              Protocol (SNMP) Management Frameworks", STD 62, RFC 3411,
              December 2002.

   [RFC3412]  Case, J., Harrington, D., Presuhn, R., and B. Wijnen,
              "Message Processing and Dispatching for the Simple Network
              Management Protocol (SNMP)", STD 62, RFC 3412,
              December 2002.

   [RFC3414]  Blumenthal, U. and B. Wijnen, "User-based Security Model
              (USM) for version 3 of the Simple Network Management
              Protocol (SNMPv3)", STD 62, RFC 3414, December 2002.

   [RFC3416]  Presuhn, R., "Version 2 of the Protocol Operations for the
              Simple Network Management Protocol (SNMP)", STD 62,
              RFC 3416, December 2002.

   [RFC3418]  Presuhn, R., "Management Information Base (MIB) for the
              Simple Network Management Protocol (SNMP)", STD 62,
              RFC 3418, December 2002.

   [RFC5226]  Narten, T. and H. Alvestrand, "Guidelines for Writing an
              IANA Considerations Section in RFCs", BCP 26, RFC 5226,
              May 2008.

7.2.  Informative References

   [RFC3410]  Case, J., Mundy, R., Partain, D., and B. Stewart,
              "Introduction and Applicability Statements for Internet-
              Standard Management Framework", RFC 3410, December 2002.

   [RFC3415]  Wijnen, B., Presuhn, R., and K. McCloghrie, "View-based
              Access Control Model (VACM) for the Simple Network
              Management Protocol (SNMP)", STD 62, RFC 3415,
              December 2002.

   [TSM]      Harrington, D., "Transport Security Model for SNMP", Work
              in Progress, July 2008.

Author's Address

   Juergen Schoenwaelder
   Jacobs University Bremen
   Campus Ring 1
   28725 Bremen
   Germany

   Phone: +49 421 200-3587
   EMail: j.schoenwaelder@jacobs-university.de

Full Copyright Statement

   Copyright (C) The IETF Trust (2008).

   This document is subject to the rights, licenses and restrictions
   contained in BCP 78, and except as set forth therein, the authors
   retain all their rights.

   This document and the information contained herein are provided on an
   "AS IS" basis and THE CONTRIBUTOR, THE ORGANIZATION HE/SHE REPRESENTS
   OR IS SPONSORED BY (IF ANY), THE INTERNET SOCIETY, THE IETF TRUST AND
   THE INTERNET ENGINEERING TASK FORCE DISCLAIM ALL WARRANTIES, EXPRESS
   OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTY THAT THE USE OF
   THE INFORMATION HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED
   WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.

Intellectual Property

   The IETF takes no position regarding the validity or scope of any
   Intellectual Property Rights or other rights that might be claimed to
   pertain to the implementation or use of the technology described in
   this document or the extent to which any license under such rights
   might or might not be available; nor does it represent that it has
   made any independent effort to identify any such rights.  Information
   on the procedures with respect to rights in RFC documents can be
   found in BCP 78 and BCP 79.

   Copies of IPR disclosures made to the IETF Secretariat and any
   assurances of licenses to be made available, or the result of an
   attempt made to obtain a general license or permission for the use of
   such proprietary rights by implementers or users of this
   specification can be obtained from the IETF on-line IPR repository at
   http://www.ietf.org/ipr.

   The IETF invites any interested party to bring to its attention any
   copyrights, patents or patent applications, or other proprietary
   rights that may cover technology that may be required to implement
   this standard.  Please address the information to the IETF at
   ietf-ipr@ietf.org.

ISO Plain Language

On this page
PROBLEMTo read or change anything on a remote SNMPv3 agent, the manager has to know that agent's snmpEngineID, and configuring that identifier on every management application by hand is impractical.
MECHANISMThe RFC defines a well-known localEngineID value that always refers to the local default context, and a procedure in which the manager reads the snmpEngineID.0 scalar of the framework MIB using that value, then uses the answer as the contextEngineID for its real requests.
WHY IT MATTERSThe mechanism works with security models that have no discovery of their own, and the format registry that IANA keeps for engine identifiers was given explicit allocation rules.

§1Introduction

To retrieve or manipulate management information using the third version of the Simple Network Management Protocol, it is necessary to know the identifier of the remote SNMP protocol engine, the so-called snmpEngineID. While an appropriate snmpEngineID can in principle be configured on each management application for each SNMP agent, it is often desirable to discover the snmpEngineID automatically.

This document introduces a discovery mechanism that can be used to learn the snmpEngineID of a remote SNMP protocol engine. The proposed mechanism is independent of the features provided by SNMP security models, and it has been designed to coexist with discovery mechanisms that may exist in SNMP security models, such as the authoritative engine identifier discovery of the User-based Security Model.

The document also updates RFC 3411 by clarifying the IANA rules for the maintenance of the SnmpEngineID format registry.

Every SNMP agent has its own identifier. The manager needs it before it can ask the agent anything, and nobody wants to write it into the configuration by hand for every device in the network.

§2Engines, Contexts and the Four-Part Name

Within an administrative domain, an SNMP engine is uniquely identified by an snmpEngineID value. An SNMP entity, which consists of an SNMP engine and several SNMP applications, may provide access to multiple contexts. An SNMP context is a collection of management information accessible by an SNMP entity. An item of management information may exist in more than one context and an SNMP entity potentially has access to many contexts.

A context is identified by the snmpEngineID value of the entity hosting the management information, also called a contextEngineID, and a context name that identifies the specific context, also called a contextName. To identify an individual item of management information within an administrative domain, a four tuple is used: a contextEngineID, a contextName, an object type, and its instance identification. The last two elements are encoded in an object identifier value. The contextName is a character string while the contextEngineID is an octet string constructed according to the rules of the SnmpEngineID textual convention.

The SNMP architecture introduces the concept of a scopedPDU as a data structure containing a contextEngineID, a contextName and a protocol data unit, and the SNMPv3 message format uses scopedPDUs to exchange management information.

Within the SNMP framework, contextEngineIDs serve as end-to-end identifiers. This becomes important where SNMP proxies are deployed to translate between protocol versions or to cross middleboxes such as network address translators. In addition, snmpEngineIDs separate the identification of an SNMP engine from the transport addresses used to communicate with it, so management information can be correlated easily even where multiple different transports were used or where transport addresses change dynamically.

The User-based Security Model provides a mechanism to discover the snmpEngineID of the remote engine, since that is needed for security processing reasons, and the discovered value can then be used as a contextEngineID in a scopedPDU. Other security models, such as the Transport Security Model, lack such a procedure and may use the discovery mechanism defined in this document.

Naming one managed item takes four things: which agent hosts it, which group of items inside that agent, what kind of item it is, and which instance. The first two travel in the message header, the last two in the object identifier.

THE FOUR PARTS OF THE NAME OF A MANAGED ITEM
ElementWhat it identifies
contextEngineIDThe SNMP engine that hosts the management information
contextNameThe particular context within that engine
object typeThe kind of item, encoded in the object identifier
instance identificationWhich instance of that kind, also encoded in the object identifier

§3The Two Parts of the Mechanism

The discovery mechanism consists of two parts. The first is the definition of a special well-known snmpEngineID value, called the localEngineID, which always refers to a local default context. The second is the definition of a procedure to acquire the snmpEngineID scalar of the SNMP-FRAMEWORK-MIB using that special well-known localEngineID value.

The split matters because the two halves can be used independently. The localEngineID is useful on its own, since it lets a manager address an agent's default context without knowing the agent's real identifier. The discovery procedure uses it as a bootstrap value, so that a manager can find out the real identifier before it needs to use it.

Two pieces. A fixed identifier that every agent recognises and that means the default collection of information, and a procedure that uses that fixed identifier once to fetch the agent's real identifier.

§3.1The Local EngineID

An SNMP command responder implementing this specification must register its pduTypes using the localEngineID snmpEngineID value by invoking the registerContextEngineID() abstract service interface defined in RFC 3412. This registration is done in addition to the normal registration under the SNMP engine's own snmpEngineID, which is consistent with the SNMPv3 specifications since they explicitly allow registration of multiple engineIDs and multiple pduTypes.

The SnmpEngineID textual convention defines that an snmpEngineID value must be between 5 and 32 octets long. This specification proposes to use the variable length format 3 of that convention and to allocate the reserved, unused format value 6, using the enterprise ID 0 for the localEngineID. The ASN.1 definition for localEngineID would look like this: localEngineID OCTET STRING ::= '8000000006'H.

The localEngineID value always provides access to the default context of an SNMP engine. It is intended to be used as a special value for the contextEngineID field in the scopedPDU, and it must not be used as a value to identify an SNMP engine. That is, it must not be used in the snmpEngineID.0 scalar or in the msgAuthoritativeEngineID field in the securityParameters of the User-based Security Model.

The fixed value is five bytes long and is built like any other engine identifier, so no new syntax is needed. It means one thing only: the default collection of information at the receiving agent.

THE ASN.1 DEFINITION OF THE LOCAL ENGINE ID
localEngineID
localEngineID OCTET STRING ::= '8000000006'H

§3.2The Discovery Procedure

Discovery of the snmpEngineID is done by sending a Read Class protocol operation to retrieve the snmpEngineID scalar using the localEngineID defined above as a contextEngineID value. Implementations should only perform this discovery step when it is needed. In particular, if security models are used that already discover the remote snmpEngineID, such as the User-based Security Model, then no further discovery is necessary. The same is true in situations where the application already knows a suitable snmpEngineID value.

The procedure to discover the snmpEngineID of a remote SNMP engine is described in four steps. First, check whether a suitable contextEngineID value is already known; if so, use the provided value and stop. Second, check whether the selected security model supports discovery of the remote snmpEngineID; if so, let the security model perform the discovery, and if the remote value has been successfully determined, assign it to the contextEngineID and stop. Third, send a Read Class operation to the remote SNMP engine using the localEngineID value as the contextEngineID in order to retrieve the scalar snmpEngineID.0 of the SNMP-FRAMEWORK-MIB; if successful, set the contextEngineID to the retrieved value and stop. Fourth, return an error indication that a suitable contextEngineID could not be discovered.

The procedure outlined above is an example and can be modified to retrieve more variables in the third step, such as the sysObjectID.0 scalar or the snmpSetSerialNo.0 scalar of the SNMPv2-MIB.

Start with what is already known, then ask the security model, then ask the agent directly. If none of that works, report that the identifier could not be found.

DISCOVERING THE ENGINE ID, THEN USING IT
Management applicationSNMP agent
  1. Read with localEngineIDA Read Class operation for the snmpEngineID.0 scalar, using the well-known local engine value as the contextEngineID.
  2. snmpEngineID.0The engine identifier of the remote agent.
  3. Real management requestSent with the discovered value as the contextEngineID.

§4The SnmpEngineID Format Registry

RFC 3411 asked IANA to create a registry for SnmpEngineID formats, but did not ask IANA to record the initial assignments made by RFC 3411, nor did it spell out the precise allocation rules. This document establishes those rules.

IANA maintains a registry for SnmpEngineID formats. The first four octets of an SnmpEngineID carry an enterprise number, while the fifth octet in a variable length SnmpEngineID value, called the format octet, indicates how the following octets are formed. The format values allocated in RFC 3411 are 0 for reserved and unused, 1 for an IPv4 address, 2 for an IPv6 address, 3 for a MAC address, 4 for administratively assigned text and 5 for administratively assigned octets, with 6 to 127 reserved and unused and 128 to 255 enterprise specific.

IANA can assign new format values out of the originally assigned and reserved number space 1 to 127, and for new assignments in that number space a specification is required. The number space 128 to 255 is enterprise specific and is not controlled by IANA. Per this document, IANA has made the assignment of format value 6 for the local engine.

The fifth byte of an engine identifier says what the rest of the identifier is: an address, a hardware address, text chosen by an administrator, and so on. IANA now keeps a list of those meanings, and this document takes one of the reserved values for the local engine.

THE SNMPENGINEID FORMAT VALUES
  • 0Reserved, unused
  • 1IPv4 address
  • 2IPv6 address
  • 3MAC address
  • 4Administratively assigned text
  • 5Administratively assigned octets
  • 6Local engine
  • 6-127Reserved, unused
  • 128-255Enterprise specific

§5Security Considerations

SNMPv3 provides cryptographic security to protect devices from unauthorized access, and this specification recommends the use of the security services provided by SNMPv3. In particular, it is recommended to protect the discovery exchange.

An snmpEngineID can contain information such as a device's MAC address, IPv4 address, IPv6 address, or administratively assigned text. An attacker located behind a router, firewall or network address translator may not be able to obtain this information directly, and might therefore discover snmpEngineID values in order to obtain this kind of device information.

In many environments, making snmpEngineID values accessible at a security level of noAuthNoPriv will benefit legitimate tools that try to determine basic information about a device. For this reason, the default View-based Access Control Model configuration in RFC 3415 gives noAuthNoPriv read access to the snmpEngineID, and the User-based Security Model discovery mechanism uses unprotected messages and reveals snmpEngineID values. In highly secure environments, snmpEngineID values can be protected by using the discovery mechanism described in this document together with a security model that does not exchange cleartext SNMP messages, such as the Transport Security Model.

The isAccessAllowed() abstract service primitive of the SNMP access control subsystem does not take the contextEngineID into account when checking access rights, so it is not possible to define a special view for context engineID discovery. A request with a localEngineID is thus treated like a request with the correct snmpEngineID by the access control subsystem. This is in line with the SNMPv3 design where the authenticated identity is the securityName, together with the security model and security level information, and transport addresses or knowledge of contextEngineID values do not affect the access control decision.

The identifier can leak a hardware or network address, so the RFC recommends protecting the exchange that fetches it. Note that the access rules cannot tell a discovery request from any other request, because they do not look at the context identifier at all.

§8References