mirror of
https://git.proxmox.com/git/mirror_iproute2
synced 2026-01-04 13:34:16 +00:00
tc: m_action: check cookie hex string len
Check the cookie hex string len is dividable by 2 as the valid hex string always should be. Reported-by: Alex Kushnarov <alexanderk@mellanox.com> Signed-off-by: Jiri Pirko <jiri@mellanox.com> Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
This commit is contained in:
parent
b831c5ffcc
commit
0149dabf2a
@ -291,7 +291,8 @@ done0:
|
||||
invarg(cookie_err_m, *argv);
|
||||
}
|
||||
|
||||
if (hex2mem(*argv, act_ck, slen / 2) < 0)
|
||||
if (slen % 2 ||
|
||||
hex2mem(*argv, act_ck, slen / 2) < 0)
|
||||
invarg("cookie must be a hex string\n",
|
||||
*argv);
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user