⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 rfc1442.txt

📁 著名的RFC文档,其中有一些文档是已经翻译成中文的的.
💻 TXT
📖 第 1 页 / 共 5 页
字号:
          Case, McCloghrie, Rose & Waldbusser                   [Page 6]          RFC 1442                SMI for SNMPv2              April 1993          -- names of objects          ObjectName ::=              OBJECT IDENTIFIER          -- syntax of objects          ObjectSyntax ::=              CHOICE {                  simple                      SimpleSyntax,                    -- note that SEQUENCEs for conceptual tables and                    -- rows are not mentioned here...                  application-wide                      ApplicationSyntax              }          -- built-in ASN.1 types          SimpleSyntax ::=              CHOICE {                  -- INTEGERs with a more restrictive range                  -- may also be used                  integer-value                      INTEGER (-2147483648..2147483647),                  string-value                      OCTET STRING,                  objectID-value                      OBJECT IDENTIFIER,                  -- only the enumerated form is allowed                  bit-value                      BIT STRING              }          Case, McCloghrie, Rose & Waldbusser                   [Page 7]          RFC 1442                SMI for SNMPv2              April 1993          -- indistinguishable from INTEGER, but never needs more than          -- 32-bits for a two's complement representation          Integer32 ::=              [UNIVERSAL 2]                  IMPLICIT INTEGER (-2147483648..2147483647)          -- application-wide types          ApplicationSyntax ::=              CHOICE {                  ipAddress-value                      IpAddress,                  counter-value                      Counter32,                  gauge-value                      Gauge32,                  timeticks-value                      TimeTicks,                  arbitrary-value                      Opaque,                  nsapAddress-value                      NsapAddress,                  big-counter-value                      Counter64,                  unsigned-integer-value                      UInteger32              }          -- in network-byte order          -- (this is a tagged type for historical reasons)          IpAddress ::=              [APPLICATION 0]                  IMPLICIT OCTET STRING (SIZE (4))          Case, McCloghrie, Rose & Waldbusser                   [Page 8]          RFC 1442                SMI for SNMPv2              April 1993          -- this wraps          Counter32 ::=              [APPLICATION 1]                  IMPLICIT INTEGER (0..4294967295)          -- this doesn't wrap          Gauge32 ::=              [APPLICATION 2]                  IMPLICIT INTEGER (0..4294967295)          -- hundredths of seconds since an epoch          TimeTicks ::=              [APPLICATION 3]                  IMPLICIT INTEGER (0..4294967295)          -- for backward-compatibility only          Opaque ::=              [APPLICATION 4]                  IMPLICIT OCTET STRING          -- for OSI NSAP addresses          -- (this is a tagged type for historical reasons)          NsapAddress ::=              [APPLICATION 5]                  IMPLICIT OCTET STRING (SIZE (1 | 4..21))          -- for counters that wrap in less than one hour with only 32 bits          Counter64 ::=              [APPLICATION 6]                  IMPLICIT INTEGER (0..18446744073709551615)          -- an unsigned 32-bit quantity          UInteger32 ::=              [APPLICATION 7]                  IMPLICIT INTEGER (0..4294967295)          Case, McCloghrie, Rose & Waldbusser                   [Page 9]          RFC 1442                SMI for SNMPv2              April 1993          -- definition for objects          OBJECT-TYPE MACRO ::=          BEGIN              TYPE NOTATION ::=                            "SYNTAX" type(Syntax)                            UnitsPart                            "MAX-ACCESS" Access                            "STATUS" Status                            "DESCRIPTION" Text                            ReferPart                            IndexPart                            DefValPart              VALUE NOTATION ::=                            value(VALUE ObjectName)              UnitsPart ::=                            "UNITS" Text                          | empty              Access ::=                            "not-accessible"                          | "read-only"                          | "read-write"                          | "read-create"              Status ::=                            "current"                          | "deprecated"                          | "obsolete"              ReferPart ::=                            "REFERENCE" Text                          | empty              IndexPart ::=                            "INDEX"    "{" IndexTypes "}"                          | "AUGMENTS" "{" Entry      "}"                          | empty              IndexTypes ::=                            IndexType                          | IndexTypes "," IndexType          Case, McCloghrie, Rose & Waldbusser                  [Page 10]          RFC 1442                SMI for SNMPv2              April 1993              IndexType ::=                            "IMPLIED" Index                          | Index              Index ::=                              -- use the SYNTAX value of the                              -- correspondent OBJECT-TYPE invocation                            value(Indexobject ObjectName)              Entry ::=                              -- use the INDEX value of the                              -- correspondent OBJECT-TYPE invocation                            value(Entryobject ObjectName)              DefValPart ::=                            "DEFVAL" "{" value(Defval Syntax) "}"                          | empty              -- uses the NVT ASCII character set              Text ::= """" string """"          END          Case, McCloghrie, Rose & Waldbusser                  [Page 11]          RFC 1442                SMI for SNMPv2              April 1993          -- definitions for notifications          NOTIFICATION-TYPE MACRO ::=          BEGIN              TYPE NOTATION ::=                            ObjectsPart                            "STATUS" Status                            "DESCRIPTION" Text                            ReferPart              VALUE NOTATION ::=                            value(VALUE OBJECT IDENTIFIER)              ObjectsPart ::=                            "OBJECTS" "{" Objects "}"                          | empty              Objects ::=                            Object                          | Objects "," Object              Object ::=                            value(Name ObjectName)              Status ::=                            "current"                          | "deprecated"                          | "obsolete"              ReferPart ::=                          "REFERENCE" Text                        | empty              -- uses the NVT ASCII character set              Text ::= """" string """"          END          END          Case, McCloghrie, Rose & Waldbusser                  [Page 12]          RFC 1442                SMI for SNMPv2              April 1993          3.  Information Modules          An "information module" is an ASN.1 module defining          information relating to network management.          The SMI describes how to use a subset of ASN.1 to define an          information module.  Further, additional restrictions are          placed on "standard" information modules.  It is strongly          recommended that "enterprise-specific" information modules          also adhere to these restrictions.          Typically, there are three kinds of information modules:          (1)  MIB modules, which contain definitions of inter-related               managed objects, make use of the OBJECT-TYPE and               NOTIFICATION-TYPE macros;          (2)  compliance statements for MIB modules, which make use of               the MODULE-COMPLIANCE and OBJECT-GROUP macros [2]; and,          (3)  capability statements for agent implementations which               make use of the AGENT-CAPABILITIES macros [2].          This classification scheme does not imply a rigid taxonomy.          For example, a "standard" information module might include          definitions of managed objects and a compliance statement.          Similarly, an "enterprise-specific" information module might          include definitions of managed objects and a capability          statement.  Of course, a "standard" information module may not          contain capability statements.          All information modules start with exactly one invocation of          the MODULE-IDENTITY macro, which provides contact and revision          history.  This invocation must appear immediately after any          IMPORTs or EXPORTs statements.          3.1.  Macro Invocation          Within an information module, each macro invocation appears          as:               <descriptor> <macro> <clauses> ::= <value>          where <descriptor> corresponds to an ASN.1 identifier, <macro>          Case, McCloghrie, Rose & Waldbusser                  [Page 13]          RFC 1442                SMI for SNMPv2              April 1993          names the macro being invoked, and <clauses> and <value>          depend on the definition of the macro.          An ASN.1 identifier consists of one or more letters, digits,          or hyphens.  The initial character must be a lower-case          letter, and the final character may not be a hyphen.  Further,          a hyphen may not be immediatedly followed by another hyphen.          For all descriptors appearing in an information module, the          descriptor shall be unique and mnemonic, and shall not exceed          64 characters in length.  This promotes a common language for          humans to use when discussing the information module and also          facilitates simple table mappings for user-interfaces.          The set of descriptors defined in all "standard" information          modules shall be unique.  Further, within any information          module, the hyphen is not allowed as a character in any

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -