]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
net/sched: pedit: make sure that offset is valid
authorAmir Vadai <amir@vadai.me>
Mon, 28 Nov 2016 10:56:40 +0000 (12:56 +0200)
committerJiri Slaby <jslaby@suse.cz>
Tue, 13 Dec 2016 15:57:11 +0000 (16:57 +0100)
commitf277a1310514bff1c5f05c93b33bd7caf2e119fb
treee09c801f36e92c31a9127472451c70845b163830
parentc20932ae0d412f1aabf3514891cdd6ae6a08ae01
net/sched: pedit: make sure that offset is valid

[ Upstream commit 95c2027bfeda21a28eb245121e6a249f38d0788e ]

Add a validation function to make sure offset is valid:
1. Not below skb head (could happen when offset is negative).
2. Validate both 'offset' and 'at'.

Signed-off-by: Amir Vadai <amir@vadai.me>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Jiri Slaby <jslaby@suse.cz>
net/sched/act_pedit.c