SNMP Subagent Programmer's Guide
Security Checker
2-82 119728—SNMP Subagent Programmer’s Guide
Programming Tutorials
Checker’s MIB extensions, highlighted in bold type, identify access functions provided
for each MIB object.
Example 2-17. Security Checker MIB Definition (page 1 of 2)
#include "typessmi"
HELLO-WORLD DEFINITIONS ::= BEGIN
IMPORTS
Counter
FROM RFC1155-SMI
OBJECT-TYPE
FROM RFC-1212
DisplayString
FROM RFC1213-MIB
TRAP-TYPE
FROM RFC1215;
private OBJECT IDENTIFIER ::= { iso(1) org(3) dod(6) internet(1) 4 }
enterprises OBJECT IDENTIFIER ::= { private 1 }
peer OBJECT IDENTIFIER ::= { enterprises 442 }
--
-- Within the 'peer' arc, entire subtrees are dedicated to the
-- following
--
peer-products OBJECT IDENTIFIER ::= { peer 1 }
peer-demos OBJECT IDENTIFIER ::= { peer 2 }
hello OBJECT IDENTIFIER ::= { peer-demos 1 }
helloOutputText OBJECT-TYPE
SYNTAX DisplayString (SIZE (0..255))
ACCESS read-write
STATUS mandatory
DESCRIPTION
"The textual message that is displayed to stdout
by the Hello World program."
::= { hello 1 }
helloPrintFreq OBJECT-TYPE
SYNTAX INTEGER (1..120)
ACCESS read-write
STATUS mandatory
DESCRIPTION
"The number of seconds between each printing
of the text described in the helloOutputText variable."
::= { hello 2 }
helloPrintCnt OBJECT-TYPE
SYNTAX Counter
ACCESS read-only
STATUS mandatory
DESCRIPTION
"A running count of the number of times the
helloOutputText message has been printed to
the console."
::= { hello 3 }