This file is indexed.

/usr/share/mibs/netsnmp/NET-SNMP-EXAMPLES-MIB is in libsnmp-base 5.4.3~dfsg-2.4ubuntu1.3.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
NET-SNMP-EXAMPLES-MIB DEFINITIONS ::= BEGIN

--
-- Example MIB objects for agent module example implementations
--

IMPORTS
    MODULE-IDENTITY, OBJECT-TYPE, Integer32,
    NOTIFICATION-TYPE                       FROM SNMPv2-SMI
    SnmpAdminString                         FROM SNMP-FRAMEWORK-MIB
    netSnmp                                 FROM NET-SNMP-MIB
    RowStatus, StorageType                  FROM SNMPv2-TC
    InetAddressType, InetAddress            FROM INET-ADDRESS-MIB
;

netSnmpExamples MODULE-IDENTITY
    LAST-UPDATED "200406150000Z"
    ORGANIZATION "www.net-snmp.org"
    CONTACT-INFO    
	 "postal:   Wes Hardaker
                    P.O. Box 382
                    Davis CA  95617

          email:    net-snmp-coders@lists.sourceforge.net"
    DESCRIPTION
	"Example MIB objects for agent module example implementations"
    REVISION     "200406150000Z"
    DESCRIPTION
	"Corrected notification example definitions"
    REVISION     "200202060000Z"
    DESCRIPTION
	"First draft"
    ::= { netSnmp 2 }

--
-- top level structure
--
netSnmpExampleScalars       OBJECT IDENTIFIER ::= { netSnmpExamples 1 }
netSnmpExampleTables        OBJECT IDENTIFIER ::= { netSnmpExamples 2 }
netSnmpExampleNotifications OBJECT IDENTIFIER ::= { netSnmpExamples 3 }
netSnmpExampleNotificationPrefix  OBJECT IDENTIFIER
                                  ::= { netSnmpExampleNotifications 0 }
netSnmpExampleNotificationObjects OBJECT IDENTIFIER
                                  ::= { netSnmpExampleNotifications 2 }
-- netSnmpTutorial          OBJECT IDENTIFIER ::= { netSnmpExamples 4 }

--
-- Example scalars
--

netSnmpExampleInteger OBJECT-TYPE
    SYNTAX      Integer32
    MAX-ACCESS  read-write
    STATUS      current
    DESCRIPTION
	"This is a simple object which merely houses a writable
	 integer.  It's only purposes is to hold the value of a single
	 integer.  Writing to it will simply change the value for
	 subsequent GET/GETNEXT/GETBULK retrievals.

	 This example object is implemented in the
	 agent/mibgroup/examples/scalar_int.c file."
    DEFVAL { 42 }
    ::= { netSnmpExampleScalars 1 }

netSnmpExampleSleeper OBJECT-TYPE
    SYNTAX      Integer32
    MAX-ACCESS  read-write
    STATUS      current
    DESCRIPTION
	"This is a simple object which is a basic integer.  It's value
	 indicates the number of seconds that the agent will take in
	 responding to requests of this object.  This is implemented
	 in a way which will allow the agent to keep responding to
	 other requests while access to this object is blocked.  It is
	 writable, and changing it's value will change the amount of
	 time the agent will effectively wait for before returning a
	 response when this object is manipulated.  Note that SET
	 requests through this object will take longer, since the
	 delay is applied to each internal transaction phase, which
	 could result in delays of up to 4 times the value of this
	 object.

	 This example object is implemented in the
	 agent/mibgroup/examples/delayed_instance.c file."
    DEFVAL { 1 }
    ::= { netSnmpExampleScalars 2 }

netSnmpExampleString OBJECT-TYPE
    SYNTAX      SnmpAdminString
    MAX-ACCESS  read-write
    STATUS      current
    DESCRIPTION
	"This is a simple object which merely houses a writable
	 string.  It's only purposes is to hold the value of a single
	 string.  Writing to it will simply change the value for
	 subsequent GET/GETNEXT/GETBULK retrievals.

	 This example object is implemented in the
	 agent/mibgroup/examples/watched.c file."
    DEFVAL { "So long, and thanks for all the fish!" }
    ::= { netSnmpExampleScalars 3 }


--
--  Example Tables
--

netSnmpIETFWGTable OBJECT-TYPE
    SYNTAX      SEQUENCE OF NetSnmpIETFWGEntry
    MAX-ACCESS  not-accessible
    STATUS      current
    DESCRIPTION
	"This table merely contains a set of data which is otherwise
	 useless for true network management.  It is a table which
	 describes properies about a IETF Working Group, such as the
	 names of the two working group chairs.

	 This example table is implemented in the
	 agent/mibgroup/examples/data_set.c file."
    ::= { netSnmpExampleTables 1 }

netSnmpIETFWGEntry OBJECT-TYPE
    SYNTAX      NetSnmpIETFWGEntry
    MAX-ACCESS  not-accessible
    STATUS      current
    DESCRIPTION
	"A row describing a given working group"
    INDEX   { nsIETFWGName }
    ::= {netSnmpIETFWGTable 1 }

NetSnmpIETFWGEntry ::= SEQUENCE {
	nsIETFWGName	OCTET STRING,
	nsIETFWGChair1	OCTET STRING,
	nsIETFWGChair2	OCTET STRING
}

nsIETFWGName OBJECT-TYPE
    SYNTAX      OCTET STRING (SIZE(1..32))
    MAX-ACCESS  not-accessible
    STATUS      current
    DESCRIPTION
	"The name of the IETF Working Group this table describes."
    ::= { netSnmpIETFWGEntry 1 }

nsIETFWGChair1 OBJECT-TYPE
    SYNTAX      OCTET STRING
    MAX-ACCESS  read-create
    STATUS      current
    DESCRIPTION
	"One of the names of the chairs for the IETF working group."
    ::= { netSnmpIETFWGEntry 2 }

nsIETFWGChair2 OBJECT-TYPE
    SYNTAX      OCTET STRING
    MAX-ACCESS  read-create
    STATUS      current
    DESCRIPTION
	"The other name, if one exists, of the chairs for the IETF
	working group."
    ::= { netSnmpIETFWGEntry 3 }

--
-- A table used in a table_iterator example
--   (agent/mibgroup/examples/netSnmpHostsTable*.[ch])
--

netSnmpHostsTable OBJECT-TYPE
    SYNTAX      SEQUENCE OF NetSnmpHostsEntry
    MAX-ACCESS  not-accessible
    STATUS      current
    DESCRIPTION
	"An example table that implements a wrapper around the
	/etc/hosts file on a machine using the iterator helper API."
    ::= { netSnmpExampleTables 2 }

netSnmpHostsEntry OBJECT-TYPE
    SYNTAX      NetSnmpHostsEntry
    MAX-ACCESS  not-accessible
    STATUS      current
    DESCRIPTION
	"A host name mapped to an ip address"
    INDEX   { netSnmpHostName }
    ::= { netSnmpHostsTable 1 }

NetSnmpHostsEntry ::= SEQUENCE {
    netSnmpHostName         OCTET STRING,
    netSnmpHostAddressType  InetAddressType,
    netSnmpHostAddress      InetAddress,
    netSnmpHostStorage      StorageType,
    netSnmpHostRowStatus    RowStatus
}

netSnmpHostName OBJECT-TYPE
    SYNTAX      OCTET STRING (SIZE(0..64))
    MAX-ACCESS  not-accessible
    STATUS      current
    DESCRIPTION
	"A host name that exists in the /etc/hosts (unix) file."
    ::= { netSnmpHostsEntry 1 }

netSnmpHostAddressType OBJECT-TYPE
    SYNTAX      InetAddressType
    MAX-ACCESS  read-create
    STATUS      current
    DESCRIPTION
	"The address type of then given host."
    ::= { netSnmpHostsEntry 2 }

netSnmpHostAddress OBJECT-TYPE
    SYNTAX      InetAddress
    MAX-ACCESS  read-create
    STATUS      current
    DESCRIPTION
	"The address of then given host."
    ::= { netSnmpHostsEntry 3 }

netSnmpHostStorage OBJECT-TYPE
    SYNTAX       StorageType
    MAX-ACCESS   read-create
    STATUS       current
    DESCRIPTION "The storage type for this conceptual row."
    DEFVAL      { nonVolatile }
    ::= { netSnmpHostsEntry 4 }

netSnmpHostRowStatus OBJECT-TYPE
    SYNTAX       RowStatus
    MAX-ACCESS   read-create
    STATUS       current
    DESCRIPTION "The status of this conceptual row."
    ::= { netSnmpHostsEntry 5 }


--
--  Example Notifications
--

netSnmpExampleHeartbeatRate OBJECT-TYPE
    SYNTAX      Integer32
    MAX-ACCESS  accessible-for-notify
    STATUS      current
    DESCRIPTION
        "A simple integer object, to act as a payload for the
         netSnmpExampleHeartbeatNotification.  The value has
         no real meaning, but is nominally the interval (in
         seconds) between successive heartbeat notifications."
::= { netSnmpExampleNotificationObjects 1 }

netSnmpExampleHeartbeatName OBJECT-TYPE
    SYNTAX      SnmpAdminString
    MAX-ACCESS  accessible-for-notify
    STATUS      current
    DESCRIPTION
        "A simple string object, to act as an optional payload
         for the netSnmpExampleHeartbeatNotification.  This varbind
         is not part of the notification definition, so is optional
         and need not be included in the notification payload. 
         The value has no real meaning, but the romantically inclined
         may take it to be the object of the sender's affection,
         and hence the cause of the heart beating faster."
::= { netSnmpExampleNotificationObjects 2 }

netSnmpExampleHeartbeatNotification NOTIFICATION-TYPE
    OBJECTS     { netSnmpExampleHeartbeatRate }
    STATUS      current
    DESCRIPTION
        "An example notification, used to illustrate the
         definition and generation of trap and inform PDUs
         (including the use of both standard and additional
         varbinds in the notification payload).
         This notification will typically be sent every
	 30 seconds, using the code found in the example module
             agent/mibgroup/examples/notification.c"
::= { netSnmpExampleNotificationPrefix 1 }
    
netSnmpExampleNotification OBJECT-TYPE
    SYNTAX      SnmpAdminString
    MAX-ACCESS  accessible-for-notify
    STATUS      obsolete
    DESCRIPTION
        "This object was improperly defined for its original purpose,
         and should no longer be used."
::= { netSnmpExampleNotifications 1 }

END