RE: mibII/vacm_vars: vacm_in_view: No security name found withmteTriggerEntry
"mike johnson" <[email protected]>
| Newsgroups | gmane.network.net-snmp.user |
|---|---|
| Message-ID | <[email protected]> |
As an addendum to my previous email. There are also two related errors I am
running into with this actually.
For the first error mentione in the first email just to see if I could get
this working I made vacm_conf.c return VACM_SUCCESS for me by editing the
file like this:
cat agent/mibgroup/mibII/vacm_conf.c | perl -e '$a = join("", <>); $a =~
s/(Should be implemented via registration \*\/\n\s+)sn = NULL;/$1return
VACM_SUCCESS;/s; print $a' > agent/mibgroup/mibII/vacm_conf.c
This is the problem which I documented in the first email I sent.
The second problem I am having is that in snmplib/snmp_api.c in the
snmp_pdu_parse func when I do a set to mteTriggerValueID like this:
mteTriggerValueID.\"snmpd.conf\".\'test\' = testErrorFlag.\'test\'
. the oid's length is getting multiplied by 4 by this line:
vp->val_len *= sizeof(oid);
which in the table_iterator_helper this makes it so that it doesn't find the
matching table row because the size is 4X too long.
and my oid look like this in debug mode:
TEST-MIB::testErrorFlag.'test.............................................'
I tried just removing the line 'vp->val_len *= sizeof(oid);', but that
didn't fix things either. If anyone has a correct fix for these two issues
I would greatly appreciate it.
Thanks
>From: "mike johnson" <[email protected]>
>To: [email protected]
>Subject: mibII/vacm_vars: vacm_in_view: No security name found
>withmteTriggerEntry
>Date: Fri, 30 Jun 2006 15:21:07 -0700
>
>although I have this in my snmpd.conf file
>
>rwuser snmp
>rwcommunity public
>
>trapcommunity public
>trapsink localhost
>
>
>agentSecName internal
>rouser internal
>
>---------
>with netsnmp 5.3.0.1 default install from tarball
>
>I still am seeing this when I set up a mteTriggerEntry and it does its
>internal get:
>
>disman:event:trigger:monitor: Running trigger (test)
>trace: netsnmp_callback_hook_build(): snmpCallbackDomain.c, 443:
>transport_callback: hook_build enter
>trace: netsnmp_callback_hook_build(): snmpCallbackDomain.c, 518:
>transport_callback: hook_build exit
>
>Sending 1 bytes to callback: 2 on fd 12
>0000: 00 .
>
>trace: netsnmp_callback_send(): snmpCallbackDomain.c, 237:
>transport_callback: hook_send enter
>trace: callback_debug_pdu(): snmpCallbackDomain.c, 91:
>dump_send_callback_transport: PDU: command = 160, errstat = 0, errindex = 0
>trace: callback_debug_pdu(): snmpCallbackDomain.c, 93:
>dump_send_callback_transport: var 2:trace: sprint_realloc_by_type():
>mib.c, 1977:
>output: sprint_by_type, type 0
>trace: sprint_realloc_by_type(): mib.c, 2037:
>sprint_by_type: bad type: 0
>MYTEST::mytestErrorFlag.'test.............................................'
>= Wrong Type (should be INTEGER): Variable has bad type
>trace: netsnmp_callback_send(): snmpCallbackDomain.c, 318:
>transport_callback: hook_send exit
>
>trace: snmp_sess_select_info(): snmp_api.c, 5843:
>sess_select: for all sessions: 12 (to in 1151600610.161280 sec) 5 8 3
>sess_select: next alarm 1.590680 sec
>verbose:sess_select: timer due in 1.590680 sec
>verbose:sess_select: setting timer to 1.590680 sec, clear block (was 1)
>trace: _sess_read(): snmp_api.c, 5417:
>sess_read: not reading 12 (fdset 0xbfffe0a0 set 0)
>trace: _sess_read(): snmp_api.c, 5417:
>sess_read: not reading 5 (fdset 0xbfffe0a0 set 0)
>trace: _sess_read(): snmp_api.c, 5417:
>sess_read: not reading 8 (fdset 0xbfffe0a0 set 0)
>trace: netsnmp_callback_recv(): snmpCallbackDomain.c, 188:
>transport_callback: hook_recv enter
>trace: netsnmp_callback_recv(): snmpCallbackDomain.c, 214:
>transport_callback: hook_recv exit
>trace: _sess_process_packet(): snmp_api.c, 5099:
>sess_process_packet: session 0x8052500 fd 3 pkt 0x81b3560 length 1
>
>Received 1 bytes from callback: 1 on fd 3
>0000: 4C L
>
>Received SNMP packet(s) from callback: 1 on fd 3
>trace: callback_debug_pdu(): snmpCallbackDomain.c, 91:
>dump_recv_callback_transport: PDU: command = 160, errstat = 0, errindex = 0
>trace: callback_debug_pdu(): snmpCallbackDomain.c, 93:
>dump_recv_callback_transport: var 2:trace: sprint_realloc_by_type():
>mib.c, 1977:
>output: sprint_by_type, type 0
>trace: sprint_realloc_by_type(): mib.c, 2037:
>sprint_by_type: bad type: 0
>MYTEST::mytestErrorFlag.'test.............................................'
>= Wrong Type (should be INTEGER): Variable has bad type
> GET message
> --
>MYTEST::mytestErrorFlag.'test.............................................'
>
># in snmplib/snmp_api.c: in _sess_process_packet
># 5334 printed by sp->callback(NETSNMP_CALLBACK_OP_RECEIVED_MESSAGE, sp,
>pdu->reqid, pdu, sp->callback_magic);
>trace: init_agent_snmp_session(): snmp_agent.c, 1260:
>snmp_agent: agent_sesion 0x81b2a98 created
>trace: init_agent_snmp_session(): snmp_agent.c, 1275:
>verbose:asp: asp 0x81b2a98 reqinfo 0x81b2a68 created
>trace: _callback_lock(): callback.c, 118:
>9:callback:lock: locked (APP,(null))
>trace: snmp_call_callbacks(): callback.c, 304:
>callback: START calling callbacks for maj=1 min=5
>trace: snmp_call_callbacks(): callback.c, 318:
>callback: calling a callback for maj=1 min=5
>trace: vacm_check_view(): mibgroup/mibII/vacm_conf.c, 1243:
>mibII/vacm_vars: vacm_in_view: ver=1, community=public
>trace: vacm_check_view(): mibgroup/mibII/vacm_conf.c, 1341:
>mibII/vacm_vars: vacm_in_view: No security name found
>trace: snmp_call_callbacks(): callback.c, 330:
>callback: END calling callbacks for maj=1 min=5 (1 called)
>trace: _callback_unlock(): callback.c, 150:
>9:callback:lock: unlocked (APP,(null))
>trace: netsnmp_send_traps(): agent_trap.c, 610:
>trap: send_trap 4 0 NET-SNMP-MIB::netSnmpAgentOIDs.10
>trace: netsnmp_remove_and_free_agent_snmp_session(): snmp_agent.c, 1690:
>snmp_agent: REMOVE session == 0x81b2a98
>trace: free_agent_snmp_session(): snmp_agent.c, 1286:
>snmp_agent: agent_session 0x81b2a98 released
>trace: free_agent_snmp_session(): snmp_agent.c, 1291:
>verbose:asp: asp 0x81b2a98 reqinfo 0x81b2a68 freed
>
>the problem I think is that in the vacm_check_view func there are several
>if statements doing different things depending on what pdu->tDomain is set
>to - the problem is mine is set to NULL and so the code does this sn =
>NULL;
>
>unless there is a way to change what my pdu->tDomain is set to, I will
>always get denied access independent of what is in the config I think
>
>Please let me know if anyone has any ideas about this or if you need any
>more information.
>
>Thanks
>
>_________________________________________________________________
>Dont just search. Find. Check out the new MSN Search!
>http://search.msn.click-url.com/go/onm00200636ave/direct/01/
>
>
>Using Tomcat but need to do more? Need to support web services, security?
>Get stuff done quickly with pre-integrated technology to make your job
>easier
>Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
>http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
>_______________________________________________
>Net-snmp-users mailing list
>[email protected]
>Please see the following page to unsubscribe or change other options:
>https://lists.sourceforge.net/lists/listinfo/net-snmp-users
_________________________________________________________________
FREE pop-up blocking with the new MSN Toolbar get it now!
http://toolbar.msn.click-url.com/go/onm00200415ave/direct/01/
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Net-snmp-users mailing list
[email protected]
Please see the following page to unsubscribe or change other options:
https://lists.sourceforge.net/lists/listinfo/net-snmp-users