9.1.3.1 SNMPv3

 



 

Overview

 

The version 3 of Simple Network Management Protocol addresses some of the long pending issues related to the large scale deployment of SNMP. Due to lack of security in using SNMP, system and network administrators were using other means such as telnet, ascii, etc., for configuration, accounting, and fault management. The primary goal of SNMP version 3 (SNMPv3) is to define a secure version of the SNMP. SNMPv3 also facilitates remote configuration of the SNMP entities, which make remote administration

of SNMP entities a much simpler task.  

 

AdventNet has implemented SNMPv3 as defined from RFC2570 to RFC2576.

 

Security Levels in SNMPv3

 

As explained earlier, SNMP version 3 (SNMPv3) is used to provide a secured environment in managing the systems and networks. The SNMPv3 Agent supports the following set of security levels as defined in the USM MIB (RFC 2574) :

A framework for definition of different authentication and privacy protocols is available in V3. Currently, the MD5 and SHA authentication protocols and the CBC_DES privacy protocol are supported in USM.

 

Supported Privacy Packages

 

For privacy support, the Encryption packages that can be used are "Cryptix" and "JCE".

 

To make use of JCE classes  

Note : If JDK 1.4 is used, then JCE privacy jars are not required to be in the class path. 

 

To make use of Cryptix classes

 

Export Restrictions

 

Encryption packages are bound by Export restrictions.

  1. If JCE 1.2 or its implementations are used in developing application and applets, they cannot be used outside US and Canada.

  2. JCE 1.2.1 does not have any export restrictions and it can be used in applications, which can be distributed throughout the world.

  3. The latest JDK version ( JDK 1.4 beta ) comes integrated with the JCE 1.2.1.

  4. Cryptix package does not have any such export restrictions.

Default Users of SNMPv3 Agents

 

By default, the SNMPv3 Agent provides support for three level of users, namely:

The details about the users get stored in the XML or Serialized Files or Runtime Memory depending upon the type of storage option chosen. 

 

Developing a Sample V3 Agent

 

Please follow the steps given below to develop a Sample v3 Agent.

Testing the SNMPv3 Agent With Default Users

 

Now that a Sample Agent is created, it has to be tested with the Default Users.

 

Testing the V3 Agent for noAuth Users

 

The default entry of noAuthUser in USM Table will be as follows. These details can

be viewed in the UsmUserTable.xml file or ser file generated under <Agent Toolkit Home>/jmxprojects/projectname/agent/bin/conf

directory.

 

Context Name Security Level

User Name

Auth Protocol

Priv Protocol

Auth Password

Priv Password

noAuth

noAuthNoPriv

noAuthUser

-

-

-

-

 

To test the Agent for noAuthUser,

  1. Make sure the Agent is started from <Agent Toolkit Home>/jmxprojects/projectname/agent/bin directory using run.bat or .sh file.

  2. Start the MIB Browser application from <Agent Toolkit Home>/bin directory.

  3. Load AGENT-SAMPLE-MIB.

  4. Click MIB Browser Settings in the toolbar icon.

  5. A wizard opens up wherein you have to choose the version of the Manager. Choose v3.

  6. Click Add in this wizard. 

  7. A Snmp Parameter Panel appears wherein the following details need to be filled : 

    1. Target Host : localhost (by default)

    2. Target Port : 8001.

    3. User Name : noAuthUser

    4. Security Level : noAuth,noPriv

    5. Context Name : noAuth

  8. Click OK.

  9. The entry gets listed in v3 Settings.

  10. Select the entry and click OK to close the MIB Browser Settings wizard.

  11. Move on to the MIB Browser Main UI.

  12. Now, test the SNMPv3 Agent by sending a query (say GET request) to the scalar variable agentDescr in the agentSystem group under the demo group. You will receive the response as
    Sent get request to localhost : 8001
    agentDescr.0:-->agentDescr not initialized

Testing the V3 Agent for authUsers

 

Context Name Security Level

User Name

Auth Protocol

Priv Protocol

Auth Password

Priv Password

auth

authNoPriv

authUser

MD5

-

authuser

-

 

To test the Agent for authUser,

Testing the Agent for Privacy Users

 

Default entry of privUser in USM Table :

 

Context Name Security Level

User Name

Auth Protocol

Priv Protocol

Auth Password

Priv Password

priv

Auth, Priv

privUser

MD5

SHA

privUser

privUser

 

To test the Agent for privUser,

Adding More Users for v3 Agents (USM)

 

User-based Security Model (USM) is a default security model defined by SNMPv3. It provides different types of security levels using various authentication and privacy protocols as explained earlier in this section. To add more users for accessing v3 Agents, AdventNet provides a table called the USMTable. User entries can be added to the Table either : (1) Before Agent Startup or (2) During Run Time.

 

Please note that though user entries are added these users will not be able to access the Agent unless View Access is given to them. Please refer to "Enabling Authorization in V3 using VACM" section for more details.

 

Before Agent Startup

 

Entries can be added to the USMTable before Agent Startup using any of the following options : (1)Using JMX Compiler UI or (2) Using XML/Ser Files/Runtime Memory or (3) Using API calls . 

 

Using JMX Compiler UI

  1. Create a Project and load a MIB. 

  2. Choose Project -> Settings menu from the menu bar of JMX Compiler UI. 

  3. Select usmUserTable in the Adaptors -> SNMP -> SNMPv3 Panel.  

  4. Click Add. 

  5. A wizard pops up wherein you can specify the user entries.

  6. Click OK. A new USM User entry gets added. 

Using XML/Ser File/Runtime Memory

 

The entries configured through JMX Compiler UI get stored in the configuration file "UsmUserTable.xml" after code generation. They get stored under <<Agent Toolkit Home>>/jmxprojects/projectname/agent/bin/conf directory, provided the type of storage is chosen.  To choose the Storage Type, 

  1. Choose Project -> Settings menu of JMX Compiler UI. 

  2. Select usmUserTable from the Adaptors -> SNMP -> SNMPv3 Panel -> USM Group. 

  3. Choose XML or Serialization or Runtime Memory from the Storage Option. By default XML file is chosen.

This XML file can be edited to add new entries. Please note that the Agent has to be re-started for the changes to take effect.  The serialized formatted file cannot be edited to add new entries. They can be updated only by adding entries during runtime.  

 

Run time memory can be used to store the v3 users information in the Agent Memory itself. Using this option will not store the entries in ser files or xml files. After choosing the Runtime memory storage option,  follow the steps given in adding entries "From the Manager"  given under the heading "Adding Entries During Runtime". Please note that once the Agent is killed, the entries added are removed from the memory.

 

Using API Calls

 

Add the following piece of code in the Main file generated in the initializeV3Settings() method in case you want to add the entries using API calls. The following is a sample entry for adding a newUser entry.

 

snmpadaptor.getSnmpAgent().getUsmUserTableListener().createAndAddUSMUserEntry("newUser"

,new Integer(0) ,"0.0" ,new Integer(NO_AUTH) ,new Integer(NO_PRIV) ,"userPublic"

," " ," " ,new Integer(3) ,new Integer(1));

 

During Runtime

 

Entries can be added during run time from the Manager.  

 

From the Manager - Using a Command line Utility

 

To add entries from the Manager, it is important to enable the Remote Configuration option in "Project -> Settings menu -> Adaptors -> SNMP -> SNMPv3 panel". Else, it is not possible to access the Table from remote. 

Usage : snmpUSMRemoteConfigure [-d dumps the messages] [-p agent port] [-r retries]

[-t timeout][-a auth_protocol] [-w auth_password] [-s priv_password] [-n contextName]

[-i contextID] [-y new_auth_password] [-z

new_priv_password] userName newUserName host

<AdventNet\JavaAgent>\examples\snmp\low_level_udpapps>run snmpUSMRemoteConfigure

-d -p 8001 -a MD5 -w authUser -n auth -y xxxUser authUser xxxUser localhost 

Changing the Password of an Existing User

 

The Manager can also change the password of an existing user, using the utility called "snmpUSMKeyChange.java" available in <Agent Toolkit Home>/examples/snmp/low_level_udpapps directory.

 

The usage of this utility is as follows:

 

Usage: snmpUSMKeyChange [-d] [-p port] [-r retries] [-t time-out] [-a

auth_protocol] [-w auth_password] [-s priv_password] [-n contextName] [-i contextID]

[-y new_auth_password] [-z new_priv_password] [ -ou user_name] [

-ow old_auth_password] [ -oz old_priv_password] userName  host

 

The password can be changed in the following ways:  

The following is an example for Own AuthKey change. Assuming that View access is given for the user, options are explained.

 

run snmpUSMKeyChange -d -p 8001 -a MD5 -w authUser -n auth -y authUserNew authUser

localhost

 

Here,  

The above inputs will modify the authentication password of the user "authUser" from "authUser" to "authUserNew". The user's authentication protocol is "MD5".

 

Enabling Authorization in V3 Using VACM

 

View-based Access Control Model (VACM) is a default access control model defined by SNMPV3 frame work (RFC 2575). It is possible to restrict a particular group in accessing an OID in the MIB using VACM. SNMPv3 Agent has implemented the VACM MIB

as a default access control model.

 

Details for VACM

 

The details for View-based Access are to be specified in the four tables of VACM MIB namely:  

Adding Entries to VACM Tables

 

An user can be given view access to a managed node by specifying their views in the VACM Tables. Entries can be added to the VACM Tables either : (1) Before Agent Startup or (2) During Run Time. Please note that only when all the vacm tables are configured

for an user will the user entry have view access. Lets have a look at the default entries in VACM Tables and move on to the steps involved in adding view access to users.

 

Default VACM Entries

 

VacmContextTable 

 

Context Name - noAuth, auth, priv

 

Vacm Security to Group Table

 

Model Security Name

Group Name

USM (3)

noAuthUser

noAuthGroup

USM ( 3)

authUser

authGroup

USM ( 3)

privUser

privGroup

1

noAuthUser

noAuthGroup

2

noAuthUser

noAuthGroup

 

Vacm Group Access Table

 

Group Name Prefix

Model

Level

Match

Read

Notify

Write

noAuthGroup

noAuth

USM(3)

noAuth,noPriv

Exact

noAuthView

noAuthView

noAuthView

aithGroup

auth

USM(3)

Auth,noPriv

Exact

authView

authView

authView

privGroup

priv

USM(3)

Auth,Priv

Exact

privView

privView

privView

noAuthGroup

noAuth

2

noAuth,noPriv

Exact

noAuthView

noAuthView

noAuthView

noAuthGroup

noAuth

1

noAuth,noPriv

Exact

noAuthView

noAuthView

noAuthView

 

Vacm View Tree Family Table

 

View Name

Mask

Type

SubTree

noAuthView

ff

included

1.3.6

authView

ff

included

1.3.6

privView

ff

included

1.3.6

 

Adding Entries before Agent Startup

 

Entries can be added to the tables before Agent Startup using (1) JMX Compiler UI option or (2) Using XML/Ser files/Runtime Memory or (3) Using API calls.

 

Using JMX Compiler UI

  1. Create a Project and load a MIB. 

  2. Choose Project -> Settings menu from the menu bar of JMX Compiler UI. 

  3. Select vacmContextTable in the Adaptors -> SNMP -> SNMPv3->VACM Panel. 

  4. Now, Click Add. 

  5. A wizard pops up wherein you can specify the user entries.

  6. Click OK. 

Similarly other VACM Tables have to be populated.

 

Using XML/Ser File/Runtime Memory

 

The entries configured through JMX Compiler UI get stored in the configuration file, VacmContextTable.xml or VacmContextTable.ser (name of the table varies according to the table chosen) under <Agent Toolkit Home>/jmxprojects/projectname/agent/bin/conf

directory, provided the storage type is chosen. To choose the type of storage, 

  1. Choose Project -> Settings menu from the menu bar of JMX Compiler UI. 

  2. Select a table from the VACM group of Adaptors -> SNMP -> SNMPv3 Panel. 

  3. Choose XML File or Serialization format or Runtime Memory from the Storage Type Options provided. By default XML File is chosen. 

  4. Choosing this would generate files in xml or serialized for each table in the VACM group.

These XML files can be edited to add new entries.  Please note that the Agent has to be re-started for the changes to take effect. The serialized formatted file cannot be edited to add new entries. They can be updated only by adding entries during runtime.  

 

Run time memory can be used to store the v3 users information in the Agent Memory itself. Using this option will not store the entries in ser files or xml files. After choosing this storage option,  follow the steps given in adding entries "From the Manager"  given under the heading "Adding Entries During Runtime". Please note that once the Agent is killed, the entries added are removed from the memory.

 

Using API calls

 

These code snippets have to be added in the main file generated in the initializeV3Settings() method. Adding the piece of code will add new entries in the vacm tables.

 

Adding entries to the vacmContextTable

 

snmpadaptor.getSnmpAgent().getVacmContextTableListener().createAndAddVacmContextEntry("newNoAuth");

 

Adding entries to the vacmSecurityToGroupTable

 

snmpadaptor.getSnmpAgent().getVacmSecurityToGroupTableListener().createAndAddVacmGroupEntry(new

Integer(3), "newNoAuthUser", "newNoAuthGrp", new Integer(3), new Integer(1));

 

Adding entries to the vacmAccessTable

 

snmpadaptor.getSnmpAgent().getVacmAccessTableListener().createAndAddVacmAccessEntry("authGrp",

"newNoAuth", new Integer(3), new Integer(0), new Integer(1), new String("newNoAuthView"),

new String("newNoAuthView"), new String("newNoAuthView"), new Integer(3), new Integer(1));

 

Adding entries to the vacmViewTreeFamilyTable

 

snmpadaptor.getSnmpAgent().getVacmViewTreeFamilyTableListener().createAndAddVacmFamilyEntry("newNoAuthView",

".1.3.6", "ff", new Integer(1), new Integer(3), new Integer(1));

 

Adding entries during Run Time

 

You can also add entries to the tables during run time. 

 

From the Manager

 

To configure the Agent from the Manager, follow the steps given below:

Note : The User-based Security Model (USM) and View-based Access Control (VACM) Tables are implemented by default when the Agent is started as SNMP Version 3 Agent.

 

Authenticating Requests From v1/v2c Managers (Coexistence Support)

 

In a typical deployment scenario, the management applications and applets will be required to communicate with SNMP Agents of different versions. They will also be required to communicate with multilingual agents, i.e., SNMP Agents that support all the three SNMP versions (v1, v2c and v3 ).

 

The multilingual  SNMP Agents  support multiple SNMP message versions and coexist with entities which support only a single SNMP message version. So, management applications with SNMPv1 or v2c support  can also communicate with SNMPv3 agents.

 

This is called as coexistence in v3 as defined in RFC 2576. SNMPv3 Agent entities with coexistence support  implement the SNMP-COMMUNITY-MIB. This MIB contains objects for mapping between community strings and version-independent SNMP  message parameters. Apart from this , a complete implementation of Coexistence Support require the implementation of SNMP-TARGET-MIB. The implementation of this MIB facilitates the source address validation on the incoming requests.

 

In case the Agent is strictly v3, it will drop the requests sent from v1/v2c Managers. To know how to make an Agent strictly v3, please refer to Making the Agent Strictly V3" (14.11) topic.   

 

14.10.1 Enabling Co-existence Support

 

You can enable Coexistence Support either through JMX Compiler UI or through API Calls.

 

Using JMX Compiler UI  

Using API calls

 

On enabling the option in JMX Compiler UI, the following code gets generated in the Main file. Without enabling the option in UI, you can enable Coexistence by adding the following line of code before the code for restarting SNMP Agent.

 

super.getSnmpAPI().setCommunityAuthentication(true);

 

Once the community Authentication is set as true, the Agent is ready to authenticate requests from all Managers. Thus Co-Existence is enabled.

 

Note : To enable Coexistence Support and add a new entry to the Table, the following import statement has to be included in the Main file.  import com.adventnet.snmp.snmp2.agent.community.*;

 

Default Users of Coexistence Support

 

The Tables of Community MIB and Target MIB used for Coexistence support include SnmpCommunityTable,

SnmpTargetAddrTable, and SnmpTargetAddrExtTable. The configurations present by default

in these Community tables are as follows:

 

SnmpCommunityTable

 

Snmp Community Index

Snmp Community Name

Snmp Community Security Name

Snmp Community ContextEngineID

SnmpCommunity Context  Name

Snmp  Community Transport         Tag

Snmp

Community

Storage  

Type

Snmp  Community Status

public

public

noAuthUser

127.0.0.18003

noAuth

public

nonVolatile (3)

active(1)

 

SnmpTargetAddrTable

 

SnmpTarget AddrName

SnmpTarget

AddrTDomain

SnmpTarget AddrTAddress

SnmpTarget AddrTimeOut

SnmpTarget AddrRetryCount

SnmpTarget AddrTagList

SnmpTargetAddr Params

SnmpTargetAddr StorageType

SnmpTarget

Addr RowStatus

localhost

.1.3.6.1.6.1.1

127.0.0.1#8003

5

1

public

advent

nonVolatile(3)

active

 

SnmpTargetAddrExt Table

 

SnmpTargetAddrMask

SnmpTargetAddrMMS

SnmpTargetAddrTask

localhost

fff

484

 

Adding Managers for Supporting Coexistence

 

Manager entries can be added to the Community Tables either : (1) Before Agent Startup or (2) During Run time.

 

Before Agent Startup

 

Entries can be added to the Target and Community tables either using the option in JMX Compiler UI or using API calls or using the XML files/Serialized file/Runtime memory storage options.

 

Using JMX Compiler UI

  1. Create a Project and load a MIB. 

  2. Choose Project -> Settings menu from the menu bar of JMX Compiler UI. 

  3. Select a table under the Community or Target group in SNMPv3 Panel. 

  4. Now, Click Add. 

  5. A wizard pops up wherein you can specify the user entries for each table.

  6. Click OK.  The entries are added. 

  7. Following the same steps add entries in all the Community and Target Tables.

Using XML/Ser File/Runtime Memory

 

The entries configured through JMX Compiler UI get stored in the configuration file, USMTable.xml under <Agent Toolkit Home>/jmxprojects/projectname/agent/bin/conf directory, provided the storage type is chosen. For this purpose, 

  1. Choose Project -> Settings menu from the menu bar of JMX Compiler UI. 

  2. Select Community Table/ Target Tables from the Adaptors -> SNMP -> SNMPv3 Panel. 

  3. Choose XML or Serialized or Runtime Memory from the Storage Option. By default xml is chosen.

Please note that the Agent has to be re-started for the changes to take effect. 

 

Run time memory can be used to store the v3 users information in the Agent Memory itself. Using this option will not store the entries in ser files or xml files. After choosing the storage option,  follow the steps given in adding entries "From the Manager"  given under the heading "Adding Entries During Runtime" . Please note that once the Agent is killed, the entries added are removed from the memory.

 

Using API Calls

 

The code snippet required for configuring the tables for Coexistence support through API calls is provided below. Add these sample codes in the main file generated before the code for restarting the SNMP Agent.

 

SnmpCommunityTable

 

snmpadaptor.getSnmpAgent().getSnmpCommunityTableListener().createAndAddCommunityEntry("newpublic",

"newpublic", "newUser", "127.0.0.18003", "newNoAuth", "newTag", new Integer(3), new

Integer(1));

 

SnmpTargetAddressExtTable

 

snmpadaptor.getSnmpAgent().getSnmpTargetAddrExtTableListener().createAndAddSnmpTargetAddrExtEntry("localHost1",

new Integer(484), "ff");

 

SnmpTargetAddressTable

 

snmpadaptor.getSnmpAgent().getSnmpTargetAddrTableListener().createAndAddSnmpTargetAddrEntry("localHost1",

".1.3.6.1.6.1.1", "127.0.0.1#8003", new Integer(5), new Integer(1), "newTag","addressParamsName",

new Integer(3), new Integer(1));

 

During Run Time - From the Manager

 

To Configure the Agent from the Manager,

Note : By default Co-Existence and Notification Filtering is not available for a v3 Agent. The option for enabling this is available in the Project - > Settings menu -> Adaptor -> SNMP -> General Panel of JMX Compiler UI.

 

Sending Notifications

 

SNMPv3 Notification PDU though similar to SNMPv2 Notification PDU, differs in the message format. It contains SNMPv3 message headers such as message ID,  version, security level, maximum supported size, security model, etc., and security parameters depending upon the security model and scoped PDU parameters such as context name, context engine ID, varbinds, etc.

 

Notifications can be sent to both v3 Managers (using the Manager information in v3Trap ForwardingTable) and v1/v2c Managers (using Notification Filtering Mechanism). Please go through the following topics for more details.

 

Notifications To v3 Managers

 

SNMPv3 frame work recommends SNMP-TARGET-MIB to identify the targets for sending Notifications, which is implementation specific . AdventNet Toolkit has a proprietary table called the V3 Trap Forwarding Table that contains all the information of the

target. For more information about this table, please refer to Traps section. This section explains how Traps can be sent from v3 Agents to v3 Managers using v3 Trap Forwarding Table.

 

Notifications to v1/v2c Managers

 

The Trap Forwarding Table mentioned above is by default bilingual in nature. Hence can forward Notifications from a v3 Agent to v1/v2c Managers also. If the proprietary implementation is not required, then you can go for the Notification Filtering Mechanism

support which is implemented as per RFC 2573.  

 

Enabling Notification Filtering Support

 

Notification Filtering support can be enabled using JMX Compiler UI or using API calls.

 

Using JMX Compiler UI

Using API Calls

 

Notification Filtering support can also be availed in AdventNet SnmpV3 Agent by adding the following piece of code in the main file before the code for restarting the Agent.

 

super.getSnmpAPI().setNotificationFiltering(true);

 

Note : While enabling Notification Filtering Support through API calls and adding a new entry to the Tables, the following import statement has to be included in the Main file (in the beginning).  

 

import com.adventnet.snmp.snmp2.agent.notification.*;

 

Coexistence support should also be enabled to support Notification Filtering Mechanism. Hence, include the API calls and the imports for the same.

 

Default Users for Notification Filtering Support

 

The Tables of Notification MIB and Target MIB used for Filtering Mechanism support include SnmpTargetAddrTable, SnmpTargetParamsTable, SnmpNotifyTable, SnmpNotifyFilterProfileTable, and SnmpNotifyFilterTable. The default configurations present in these Notification Filtering Tables are as follows:

 

SnmpTargetParamsTable

 

SnmpTarget ParamsName

SnmpTarget

ParamsMP

Model

SnmpTarget ParamsSecurity

Model

SnmpTarget ParamsSecurity

Name

SnmpTarget ParamsSecurity

Level

SnmpTarget

Params StorageType

SnmpTarget

Params

RowStatus

advent

3

3

noAuthUser

0

NonVolatile (3)

active

 

SnmpNotifyTable

 

Snmp Notify Name

Snmp Notify Tag

Snmp Notify Type

Snmp Notify Storage Type

Snmp Notify RowStatus

localhost

public

1(trap)

Non Volatile(3)

Active

 

SnmpNotify FilterProfileTable

 

SnmpTarget ParamsName

Snmp NotifyFilter ProfileName

Snmp NotifyFilter ProfileStorage Type

Snmp   Notify FilterProfile RowStatus

advent

profile

Non Volatile(3)

Active (1)

 

SnmpNotify FilterTable

 

SnmpNotify FilterProfile Name

SnmpNotify        Filter SubTree

Snmp   NotifyFilter Mask

Snmp NotifyFilter Type

SnmpNotify FilterStorage Type

SnmpNotify FilterRow Status

profile

1.3.6

ff

1

Non Volatile(3)

Active (1)

 

Adding Managers to the Notification Tables

 

After enabling Notification Filtering Support, it is required to specify the v1/v2c Managers to whom these Notifications should be sent. Manager Entries can be added to the Notification tables either : (1) Before Agent Startup or (2) During Run Time.

 

Before Agent Startup - 

 

Using JMX Compiler UI

  1. Create a Project and load a MIB. 

  2. Choose Project -> Settings menu from the menu bar of JMX Compiler UI. 

  3. Select a table from the Notification Group in Adaptors -> SNMP -> SNMPv3 Panel. 

  4. Now, Click Add. 

  5. A wizard pops up wherein you can specify the user entries.

  6. Click OK. Thus the entries get added to the table selected.

  7. Following the same steps add entries to all the tables in the Notification group.

Using XML File/Ser File/Runtime Memory

 

The entries configured through JMX Compiler UI get stored in the configuration file, NotificationTable.xml under <Agent Toolkit Home>/jmxprojects/projectname/agent/bin/conf directory, provided the storage type is chosen. For this purpose, 

  1. Choose Project -> Settings menu from the menu bar of JMX Compiler UI. 

  2. Select each table in the Adaptors -> SNMP -> SNMPv3 Panel -> Notification Group. 

  3. Choose XML or Serialized or Runtime Memory from the Storage Option. By default xml is chosen. 

  4. By choosing either of the option for each Notification related table, a file gets generated either in xml or serialized format. By default the storage type chosen is xml.

These XML files can be edited to add new entries.  Please note that the Agent has to be re-started for the changes to take effect. 

 

Run time memory can be used to store the v3 users information in the Agent Memory itself. Using this option will not store the entries in ser files or xml files. After choosing the storage option,  follow the steps given in adding entries "From the Manager"  given under the heading "Adding Entries During Runtime" . Please note that once the Agent is killed, the entries added are removed from the memory.

 

Using API calls

 

To add the entries, follow the links and include the code (given under respective links) in the generated main file.

 

SnmpTargetAddrTable

 

snmpadaptor.getSnmpAgent().getSnmpTargetAddrTableListener().createAndAddSnmpTargetAddrEntry("localHost1",

".1.3.6.1.6.1.1", "127.0.0.1#8003", new Integer(5), new Integer(1), "newTag","addressParamsName",

new Integer(3), new Integer(1));

 

SnmpTargetParamsTable

 

snmpadaptor.getSnmpAgent().getSnmpTargetParamsTableListener().createAndAddSnmpTargetParamsEntry("advent1",

new Integer(3), new Integer(3), "newUser", new Integer(0), new Integer(3), new Integer(1));

 

SnmpNotifyTable

 

snmpadaptor.getSnmpAgent().getSnmpNotifyTableListener().createAndAddSnmpNotifyEntry("localhost2",

"public", new Integer(1), new Integer(3), new Integer(1));

 

SnmpNotifyFilterTable

 

snmpadaptor.getSnmpAgent().getSnmpNotifyFilterTableListener().createAndAddSnmpNotifyFilterEntry("advent1",

".1.3.6", "ff", new Integer(1), new Integer(3), new Integer(1));

 

SnmpNotifyFilterProfileTable

 

snmpadaptor.getSnmpAgent().getSnmpNotifyFilterProfileTableListener().createAndAddSnmpNotifyFilterProfileEntry("advent1",

"newProfile", new Integer(3), new Integer(1));

 

During Run Time - From the Manager

 

To configure the Agent from the Manager,

Testing Notification Filtering Support

 

Now that you have enabled this feature and added entries to the Notification Table, the next step is checking whether the Agent works with this support. To ensure the same, follow these steps: