summaryrefslogtreecommitdiffstats
path: root/meta-networking/recipes-daemons/vblade
diff options
context:
space:
mode:
authorJian Liu <jian.liu@windriver.com>2015-07-07 09:17:30 +0800
committerJoe MacDonald <joe_macdonald@mentor.com>2015-07-16 09:56:40 -0400
commit8e642c32bb59e4b93f514174bb8203d9aee93d2e (patch)
tree1342e2a1b719ec1daa86568d6509096d258a61fa /meta-networking/recipes-daemons/vblade
parent2750941c1ea57010e4081c8443ac417c38076217 (diff)
downloadmeta-openembedded-8e642c32bb59e4b93f514174bb8203d9aee93d2e.tar.gz
net-snmp: don't return incompletely parsed varbinds
the snmp_pdu_parse() function could leave incompletely parsed varBind variables in the list of variables in case the parsing of the SNMP PDU failed. If later processing tries to operate on the stale and incompletely processed varBind (e.g. when printing the variables), this can lead to e.g. crashes or, possibly, execution of arbitrary code. The snmp_pdu_parse() function stores varBind variables in a list of netsnmp_variable_list structures. Each time the function parses a new varBind, a new netsnmp_variable_list item is allocated on the heap and linked to the list of variables. The problem is that this item is not removed from the list, even if snmp_pdu_parse() fails to complete the parsing. The "type" member of the stale netsnmp_variable_list is not properly initialized in case snmp_pdu_parse() returns early from the parsing. However, the "type" member is used to determine later code paths, which is why we see crashes in a variety of functions, although the root cause for all of these is the same. This patch come from http://sourceforge.net/p/net-snmp/code/ci/f23bcd3ac6ddee5d0a48f9703007ccc738914791/ Written-by: Robert Story Signed-off-by: Jian Liu <jian.liu@windriver.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> Signed-off-by: Joe MacDonald <joe_macdonald@mentor.com>
Diffstat (limited to 'meta-networking/recipes-daemons/vblade')
0 files changed, 0 insertions, 0 deletions