[PKT_SCHED]: Fix illegal memory dereferences when dumping actions
authorThomas Graf <tgraf@suug.ch>
Thu, 6 Jul 2006 03:45:06 +0000 (20:45 -0700)
committerDavid S. Miller <davem@davemloft.net>
Thu, 6 Jul 2006 03:45:06 +0000 (20:45 -0700)
commit26dab8930b408d5e5eb9ef496d68364dc955e249
tree3ddcc939b167a66638b91fa423882048faf6b8ca
parente340221acda6bc0bf05a0ff6e6114902c4307670
[PKT_SCHED]: Fix illegal memory dereferences when dumping actions

The TCA_ACT_KIND attribute is used without checking its
availability when dumping actions therefore leading to a
value of 0x4 being dereferenced.

The use of strcmp() in tc_lookup_action_n() isn't safe
when fed with string from an attribute without enforcing
proper NUL termination.

Both bugs can be triggered with malformed netlink message
and don't require any privileges.

Signed-off-by: Thomas Graf <tgraf@suug.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/sched/act_api.c