> On Mon, 14 Feb 2005 14:58:24 -0500 [EMAIL PROTECTED] wrote:
> CRC>     session.peername = "localhost";
> CRC>     session.retries = 3;
> CRC>     session.version = SNMP_VERSION_2c;
> CRC>     session.community = "private";
> CRC>     session.community_len = strlen(session.community);
> CRC> 
> CRC>     ss = snmp_open(&session);
> CRC> 
> CRC> I don't see "private" in those packets.  Should I?
> 
> Yes.
> 
> CRC>  Any idea why this doesn't work?
> 
> Nope.
> 
> What does the session structure look like after you call snmp_open?

My code says:

    session.peername = "localhost";
    session.retries = 1;
    session.version = SNMP_VERSION_2c;
    session.community = "config";
    session.community_len = strlen(session.community);

    /* establish the session */
    ss = snmp_open(&session);

    snmp_log(LOG_INFO, "peername:%s\n", session.peername);
    snmp_log(LOG_INFO, "community:%s\n", session.community);

and the log output is:

   peername:localhost
   community:(null)

What the heck is _that_ about?





-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
_______________________________________________
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