Hi All,
         Sorry for posting Again...........
 
Anyone has any clue about below problem.
 
Thanks,
Sanjay

________________________________

From: Kumar Sanjay-XJD784 
Sent: Monday, March 28, 2011 1:48 PM
To: [email protected]
Cc: 'Dave Shield'
Subject: Trying to GET the details of unauthorized user


Hi All,
          I am trying to GET  the details of unauthorized user, trying
to access the SNMP Agent.
For that I am trying to get the snmpv3 access details in function
"usm_process_in_msg" in snmpusm.c
 
Here  I am  trying to get IP address of the V3 user from
"netsnmp_session * sess,     /* IN   - session which got the message
*/" 
a function parameter to "usm_process_in_msg", 
there is an element in data structure "netsnmp_session"    char
*peername;       /* Domain name or dotted IP address of default peer */
 
snmp_log( LOG_INFO, "sanjay unknown username: %s ** ip:%s ** %x ** \n",
secName, sess->peername, sess->peername );
 
Output: 
user.info snmpd: sanjay unknown username: mot ** ip:(null) ** 0 **
 
 
But  unfortunately peername is  "null" string.
 
Could someone help me out where I need to update the netsnmp_session
structure 
so the I will be able to get the IP Address in "usm_process_in_msg" ?
 
 
Thanks,
Sanjay 


------------------------------------------------------------------------------
Create and publish websites with WebMatrix
Use the most popular FREE web apps or write code yourself; 
WebMatrix provides all the features you need to develop and 
publish your website. http://p.sf.net/sfu/ms-webmatrix-sf
_______________________________________________
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

Reply via email to