Please help

"Shaji, Sreeja (GE Vernova, consultant)" <[email protected]> Mon, 7 Oct 2024 11:05:04 +0000
Newsgroups gmane.network.net-snmp.devel
Message-ID <PAWP101MB05824D4F681387C3AC0B4494EA7D2@PAWP101MB0582.NAMP101.PROD.OUTLOOK.COM>
--===============8950730666331848399==
Content-Language: en-US
Content-Type: multipart/alternative;
	boundary="_000_PAWP101MB05824D4F681387C3AC0B4494EA7D2PAWP101MB0582NAMP_"

--_000_PAWP101MB05824D4F681387C3AC0B4494EA7D2PAWP101MB0582NAMP_
Content-Type: text/plain; charset="us-ascii"
Content-Transfer-Encoding: quoted-printable

Hi,

Please help us for an issue observing in our application.

SNMP version using  : net-snmp-5.9.4
OpenSSL version : openssl-3.0.13

Our application supports

  *   SNMP polling for version 1 , 2c and 3 and encryption SHA, MD5, AES, D=
ES,
  *   SNMP traps

We are using more than 60 + devices to get the SNMP information. We use con=
tinuous device polling via threads.
Now we found memory leaks in the application while using SNMP v3 version. N=
o issues found in SNMP v2 version.
The issues found in snmp_sess_synch_response with v3 version only.
When we use all other code except this line, no leak found. When we include=
 this function with v3 issue coming.

Please find the usage below,

snmp_sess_init(&session);

ss =3D snmp_sess_open(&session);

Setting v3 parameters
{

}

/*pdu create/*
snmp_pdu_create

snmp_sess_synch_response(ss, pdu, &response);

/* data parsing /*

if (response)
{
      snmp_free_pdu(response);
}

//freed V3 and other configuration memory
free(session.peername); session.peername=3D NULL;
free(session.securityName); session.peername=3D NULL;

snmp_sess_close(ss);

Please let us know any memory leak bug reported for V3 in openssl or net sn=
mp side and any patch or fix is available?
Please reply ASAP it is Very CRITICAL

Thanks
Sreeja Shaji

--_000_PAWP101MB05824D4F681387C3AC0B4494EA7D2PAWP101MB0582NAMP_
Content-Type: text/html; charset="us-ascii"
Content-Transfer-Encoding: quoted-printable

<html xmlns:v=3D"urn:schemas-microsoft-com:vml" xmlns:o=3D"urn:schemas-micr=
osoft-com:office:office" xmlns:w=3D"urn:schemas-microsoft-com:office:word" =
xmlns:m=3D"http://schemas.microsoft.com/office/2004/12/omml" xmlns=3D"http:=
//www.w3.org/TR/REC-html40">
<head>
<meta http-equiv=3D"Content-Type" content=3D"text/html; charset=3Dus-ascii"=
>
<meta name=3D"Generator" content=3D"Microsoft Word 15 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
	{font-family:Wingdings;
	panose-1:5 0 0 0 0 0 0 0 0 0;}
@font-face
	{font-family:"Cambria Math";
	panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
	{font-family:Calibri;
	panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
	{font-family:"Cascadia Mono";
	panose-1:2 11 6 9 2 0 0 2 0 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
	{margin:0in;
	font-size:11.0pt;
	font-family:"Calibri",sans-serif;
	mso-ligatures:standardcontextual;}
p.MsoListParagraph, li.MsoListParagraph, div.MsoListParagraph
	{mso-style-priority:34;
	margin-top:0in;
	margin-right:0in;
	margin-bottom:0in;
	margin-left:.5in;
	font-size:11.0pt;
	font-family:"Calibri",sans-serif;
	mso-ligatures:standardcontextual;}
span.EmailStyle17
	{mso-style-type:personal-compose;
	font-family:"Calibri",sans-serif;
	color:windowtext;}
.MsoChpDefault
	{mso-style-type:export-only;}
@page WordSection1
	{size:8.5in 11.0in;
	margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
	{page:WordSection1;}
/* List Definitions */
@list l0
	{mso-list-id:996764302;
	mso-list-type:hybrid;
	mso-list-template-ids:-1189964040 67698689 67698691 67698693 67698689 6769=
8691 67698693 67698689 67698691 67698693;}
@list l0:level1
	{mso-level-number-format:bullet;
	mso-level-text:\F0B7;
	mso-level-tab-stop:none;
	mso-level-number-position:left;
	text-indent:-.25in;
	font-family:Symbol;}
@list l0:level2
	{mso-level-number-format:bullet;
	mso-level-text:o;
	mso-level-tab-stop:none;
	mso-level-number-position:left;
	text-indent:-.25in;
	font-family:"Courier New";}
@list l0:level3
	{mso-level-number-format:bullet;
	mso-level-text:\F0A7;
	mso-level-tab-stop:none;
	mso-level-number-position:left;
	text-indent:-.25in;
	font-family:Wingdings;}
@list l0:level4
	{mso-level-number-format:bullet;
	mso-level-text:\F0B7;
	mso-level-tab-stop:none;
	mso-level-number-position:left;
	text-indent:-.25in;
	font-family:Symbol;}
@list l0:level5
	{mso-level-number-format:bullet;
	mso-level-text:o;
	mso-level-tab-stop:none;
	mso-level-number-position:left;
	text-indent:-.25in;
	font-family:"Courier New";}
@list l0:level6
	{mso-level-number-format:bullet;
	mso-level-text:\F0A7;
	mso-level-tab-stop:none;
	mso-level-number-position:left;
	text-indent:-.25in;
	font-family:Wingdings;}
@list l0:level7
	{mso-level-number-format:bullet;
	mso-level-text:\F0B7;
	mso-level-tab-stop:none;
	mso-level-number-position:left;
	text-indent:-.25in;
	font-family:Symbol;}
@list l0:level8
	{mso-level-number-format:bullet;
	mso-level-text:o;
	mso-level-tab-stop:none;
	mso-level-number-position:left;
	text-indent:-.25in;
	font-family:"Courier New";}
@list l0:level9
	{mso-level-number-format:bullet;
	mso-level-text:\F0A7;
	mso-level-tab-stop:none;
	mso-level-number-position:left;
	text-indent:-.25in;
	font-family:Wingdings;}
ol
	{margin-bottom:0in;}
ul
	{margin-bottom:0in;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext=3D"edit" spidmax=3D"1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext=3D"edit">
<o:idmap v:ext=3D"edit" data=3D"1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang=3D"EN-US" link=3D"#0563C1" vlink=3D"#954F72" style=3D"word-wrap:=
break-word">
<div class=3D"WordSection1">
<p class=3D"MsoNormal">Hi,<o:p></o:p></p>
<p class=3D"MsoNormal"><o:p>&nbsp;</o:p></p>
<p class=3D"MsoNormal">Please help us for an issue observing in our applica=
tion.<o:p></o:p></p>
<p class=3D"MsoNormal"><o:p>&nbsp;</o:p></p>
<p class=3D"MsoNormal">SNMP version using&nbsp; : net-snmp-5.9.4<o:p></o:p>=
</p>
<p class=3D"MsoNormal">OpenSSL version : openssl-3.0.13<o:p></o:p></p>
<p class=3D"MsoNormal"><o:p>&nbsp;</o:p></p>
<p class=3D"MsoNormal">Our application supports <o:p></o:p></p>
<ul style=3D"margin-top:0in" type=3D"disc">
<li class=3D"MsoListParagraph" style=3D"margin-left:0in;mso-list:l0 level1 =
lfo1">SNMP polling for version 1 , 2c and 3 and encryption SHA, MD5, AES, D=
ES,
<o:p></o:p></li><li class=3D"MsoListParagraph" style=3D"margin-left:0in;mso=
-list:l0 level1 lfo1">SNMP traps
<o:p></o:p></li></ul>
<p class=3D"MsoNormal"><o:p>&nbsp;</o:p></p>
<p class=3D"MsoNormal">We are using more than 60 + devices to get the SNMP =
information. We use continuous device polling via threads.<o:p></o:p></p>
<p class=3D"MsoNormal">Now we found memory leaks in the application while u=
sing SNMP v3 version. No issues found in SNMP v2 version.
<o:p></o:p></p>
<p class=3D"MsoNormal">The issues found in <span style=3D"font-size:9.5pt;f=
ont-family:&quot;Cascadia Mono&quot;;color:black">
snmp_sess_synch_response </span>with v3 version only.<span style=3D"font-si=
ze:9.5pt;font-family:&quot;Cascadia Mono&quot;;color:black"><o:p></o:p></sp=
an></p>
<p class=3D"MsoNormal">When we use all other code except this line, no leak=
 found. When we include this function with v3 issue coming.<o:p></o:p></p>
<p class=3D"MsoNormal"><o:p>&nbsp;</o:p></p>
<p class=3D"MsoNormal">Please find the usage below,<o:p></o:p></p>
<p class=3D"MsoNormal"><o:p>&nbsp;</o:p></p>
<p class=3D"MsoNormal"><span style=3D"font-size:9.5pt;font-family:&quot;Cas=
cadia Mono&quot;;color:black">snmp_sess_init(&amp;session);<o:p></o:p></spa=
n></p>
<p class=3D"MsoNormal"><span style=3D"font-size:9.5pt;font-family:&quot;Cas=
cadia Mono&quot;;color:black"><o:p>&nbsp;</o:p></span></p>
<p class=3D"MsoNormal"><span style=3D"font-size:9.5pt;font-family:&quot;Cas=
cadia Mono&quot;;color:black">ss =3D snmp_sess_open(&amp;session);<o:p></o:=
p></span></p>
<p class=3D"MsoNormal"><span style=3D"font-size:9.5pt;font-family:&quot;Cas=
cadia Mono&quot;;color:black"><o:p>&nbsp;</o:p></span></p>
<p class=3D"MsoNormal"><span style=3D"font-size:9.5pt;font-family:&quot;Cas=
cadia Mono&quot;;color:black">Setting v3 parameters<o:p></o:p></span></p>
<p class=3D"MsoNormal"><span style=3D"font-size:9.5pt;font-family:&quot;Cas=
cadia Mono&quot;;color:black">{<o:p></o:p></span></p>
<p class=3D"MsoNormal"><span style=3D"font-size:9.5pt;font-family:&quot;Cas=
cadia Mono&quot;;color:black"><o:p>&nbsp;</o:p></span></p>
<p class=3D"MsoNormal"><span style=3D"font-size:9.5pt;font-family:&quot;Cas=
cadia Mono&quot;;color:black">}</span><o:p></o:p></p>
<p class=3D"MsoNormal"><span style=3D"font-size:9.5pt;font-family:&quot;Cas=
cadia Mono&quot;;color:black"><o:p>&nbsp;</o:p></span></p>
<p class=3D"MsoNormal"><span style=3D"font-size:9.5pt;font-family:&quot;Cas=
cadia Mono&quot;;color:black">/*<b>pdu create/</b>*<o:p></o:p></span></p>
<p class=3D"MsoNormal"><span style=3D"font-size:9.5pt;font-family:&quot;Cas=
cadia Mono&quot;;color:black">snmp_pdu_create<o:p></o:p></span></p>
<p class=3D"MsoNormal"><span style=3D"font-size:9.5pt;font-family:&quot;Cas=
cadia Mono&quot;;color:black"><o:p>&nbsp;</o:p></span></p>
<p class=3D"MsoNormal"><span style=3D"font-size:9.5pt;font-family:&quot;Cas=
cadia Mono&quot;;color:black">snmp_sess_synch_response(ss, pdu, &amp;respon=
se);<o:p></o:p></span></p>
<p class=3D"MsoNormal"><span style=3D"font-size:9.5pt;font-family:&quot;Cas=
cadia Mono&quot;;color:black"><o:p>&nbsp;</o:p></span></p>
<p class=3D"MsoNormal"><span style=3D"font-size:9.5pt;font-family:&quot;Cas=
cadia Mono&quot;;color:black">/* data parsing /*<o:p></o:p></span></p>
<p class=3D"MsoNormal"><span style=3D"font-size:9.5pt;font-family:&quot;Cas=
cadia Mono&quot;;color:black"><o:p>&nbsp;</o:p></span></p>
<p class=3D"MsoNormal" style=3D"text-autospace:none"><span style=3D"font-si=
ze:9.5pt;font-family:&quot;Cascadia Mono&quot;;color:blue">if</span><span s=
tyle=3D"font-size:9.5pt;font-family:&quot;Cascadia Mono&quot;;color:black">=
 (response)<o:p></o:p></span></p>
<p class=3D"MsoNormal" style=3D"text-autospace:none"><span style=3D"font-si=
ze:9.5pt;font-family:&quot;Cascadia Mono&quot;;color:black">{<o:p></o:p></s=
pan></p>
<p class=3D"MsoNormal" style=3D"text-autospace:none"><span style=3D"font-si=
ze:9.5pt;font-family:&quot;Cascadia Mono&quot;;color:black">&nbsp;&nbsp;&nb=
sp;&nbsp;&nbsp; snmp_free_pdu(response);<o:p></o:p></span></p>
<p class=3D"MsoNormal"><span style=3D"font-size:9.5pt;font-family:&quot;Cas=
cadia Mono&quot;;color:black">}<o:p></o:p></span></p>
<p class=3D"MsoNormal"><span style=3D"font-size:9.5pt;font-family:&quot;Cas=
cadia Mono&quot;;color:black"><o:p>&nbsp;</o:p></span></p>
<p class=3D"MsoNormal"><span style=3D"font-size:9.5pt;font-family:&quot;Cas=
cadia Mono&quot;;color:black">//freed V3 and other configuration memory<o:p=
></o:p></span></p>
<p class=3D"MsoNormal"><span style=3D"font-size:9.5pt;font-family:&quot;Cas=
cadia Mono&quot;;color:black">free(session.peername); session.peername=3D N=
ULL;<o:p></o:p></span></p>
<p class=3D"MsoNormal"><span style=3D"font-size:9.5pt;font-family:&quot;Cas=
cadia Mono&quot;;color:black">free(session.securityName); session.peername=
=3D NULL;<o:p></o:p></span></p>
<p class=3D"MsoNormal"><o:p>&nbsp;</o:p></p>
<p class=3D"MsoNormal"><span style=3D"font-size:9.5pt;font-family:&quot;Cas=
cadia Mono&quot;;color:black">snmp_sess_close(ss);<o:p></o:p></span></p>
<p class=3D"MsoNormal"><span style=3D"font-size:9.5pt;font-family:&quot;Cas=
cadia Mono&quot;;color:black"><o:p>&nbsp;</o:p></span></p>
<p class=3D"MsoNormal">Please let us know any memory leak bug reported for =
V3 in openssl or net snmp side and any patch or fix is available?<o:p></o:p=
></p>
<p class=3D"MsoNormal"><b><span style=3D"color:red">Please reply ASAP it is=
 Very CRITICAL<o:p></o:p></span></b></p>
<p class=3D"MsoNormal"><span style=3D"font-size:9.5pt;font-family:&quot;Cas=
cadia Mono&quot;;color:black"><o:p>&nbsp;</o:p></span></p>
<p class=3D"MsoNormal"><span style=3D"font-size:9.5pt;font-family:&quot;Cas=
cadia Mono&quot;;color:black">Thanks<o:p></o:p></span></p>
<p class=3D"MsoNormal"><span style=3D"font-size:9.5pt;font-family:&quot;Cas=
cadia Mono&quot;;color:black">Sreeja Shaji<o:p></o:p></span></p>
</div>
</body>
</html>

--_000_PAWP101MB05824D4F681387C3AC0B4494EA7D2PAWP101MB0582NAMP_--


--===============8950730666331848399==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline


--===============8950730666331848399==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

_______________________________________________
Net-snmp-coders mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/net-snmp-coders

--===============8950730666331848399==--