1. Overview 

This implementation of SNMP agent is originally from CMU (see section 5 for
more details on the origin of this software).  It has been extensively modified
to be compatible with VxWorks and is appropriately customized to run in an
embedded environment.

This implementation supports version 1 and 2 of SNMP standards.	 See MIB.txt
file for more details.

This Snmp agent software is made to run without requiring filesystem
support for storing configuration files or MIB text files.  Since many
embedded systems do not have storage for files, the agent software
has been modified to compile into single object module that can be
linked at compile time.	 Customization can be done entirly in source code,
without having to keep various files around.

One of the tools required to make this happen is a MIB compiler.  I has
added a MIB compiler that takes any MIB text file in ASN.1 notation
and turns it into C file that can be compiled and linked into the snmp
module.	 The compilation is done quite efficiently, since the result
of the compilation is a internal tree data structure used by the agent
code at run time.  There is little run-time processing overhead involved in
turning the compiled MIB data into useable form.

Customization, in terms of adding new MIB elements is straight-forward.
There are portions of the software that can be customized.  It is
somewhat clear as to where new software needs to be added.  Furthermore,
there are many examples of how new code can be constructed for the new
MIB elements.



2. Customizing this software for your projects

The customization here basically refers to adding your custom enterprise
MIB definition specific to your product and company.

An example MIB can be found in PSO.txt.	 To compile this file along with
MIB.txt	 you can:

        cat MIB.txt PSO.txt | ./mib_process > mib.out.c

There is an entry for this in the Makefile.  Note that you have to
append MIB.txt in front, since PSO.txt MIB refers to enterprises MIB
in RFC1155.  It is most likely that your custom MIB will be under
enterprises with your own registered OID.

The example provided is to be used for development only.  The sole purpose
of the PSO.txt is to provide an example for the developers.  It is definitely
not intended to be deployed.  The OID 9999 is not registered anywhere and
it is there only for demonstration purpose.  Please keep this in mind.

List of files that can be used for customization:

        custom_snmp_vars.c
		This file can be used to add var_XXX() routines
		for each MIB objects being added.  Examples are
		available in this file currently to show you
		two examples: first one	lists out list of tasks
		running	in a VxWorks system (similar to 'i' command).
		The second one returns some information	about the
		SNMP agent task	itself.

        custom_snmp_vars.h
		This file is used to add definitions of	MIB object
		id's.  The numeric definitions (e.g. VXWORKS_TASK_MIB
		which is defined as 1,3,6,1,4,1,9999,1,1) for the MIB
		object is defined at the top.	In the second half
		of the file, a list of XXX_variables[] structure array
		is defined.  These are used in conjunction with	the
		custom_subtree.h

        custom_subtree.h
		This file lists	out subtree information to be
		incorporated into snmp_vars.c file.  A list of
		initializations	for the subtree structure is defined
		for each of the	added MIB entities.  Within the
		definition, XXX_variables[] defined in custom_snmp_vars.h
		and var_XXX() routines defined in custom_snmp_vars.c
		are referenced.

        PSO.txt
		This file can be named something else (e.g. COMPANY_ABC.txt).
		It contains example enterprise MIB extensions (for this
		example	1,3,6,1,4,1,9999) definitions in ASN.1.	 Combined
		with MIB.txt this file can be sent to mib_process program
		to generate C compiler compatible input	file.



3. Example of using snmpwalk client (CMU client program on Unix)
        against this SNMP agent running inside VxWorks (actually
        a VxSim on Sparc/Solaris whose address is 127.0.1.0).

        3.1) snmpwalk 127.0.1.0 public 
        print everything

        3.2) snmpwalk 127.0.1.0 public system
        print 'system' specific portions of standard MIB

        3.3) 
        cp PSO.txt /usr/local/share/snmp/mibs/
        snmpwalk -m ALL	 127.0.1.0 public .1.3.6.1.4.1.9999

        copy custom MIB file to shared directory (so that
        the snmpwalk program reads it and knows your custom MIB
        structure) and then print the custom MIB content



4. License, Copyright, Credits and History

This software is based on original work by 
        Copyright 1988, 1989, 1990 by Carnegie Mellon University
        Copyright 1989  TGV, Incorporated

Additionally, it is based on work by
        Copyright (C) 1993, University Research Association
        Carl Kalbfleisch        cwk@irrational.ssc.gov
        Larry Hoff		hoff@gw1.ags.bnl.gov

All other modifications are based on work by
        Hwa-Jin Bae, bae@mail.com, Piedmont California
        Modifications are placed in Public domain
