Currently for bsnmpd is possible to configure only two community strings for SNMP v1/2 - one for read only access and one for write access.
begemotSnmpdCommunityString.0.1 = $(read) # begemotSnmpdCommunityString.0.2 = $(write) begemotSnmpdCommunityDisable = 1
This patch allows use several different community strings with different access rights for bsnmpd. The compatibility with old config files and other snmp modules should be saved.
New field in community table is introduced: begemotSnmpdCommunityPermission. Currently it can have only two values 1 (COMM_READ, it is default value) and 2 (COMM_WRITE). When new community string is found in config file it is dynamically created. Example:
begemotSnmpdCommunityString.0.1 = "public1" #begemotSnmpdCommunityString.0.2 = $(write) begemotSnmpdCommunityString.0.3 = "writeAcce$s" begemotSnmpdCommunityPermission.0.3 = 2 begemotSnmpdCommunityString.0.4 = "2public" begemotSnmpdCommunityString.0.5 = "3pubLic" # hide community table from SNMP agents begemotSnmpdCommunityDisable = 1