]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
ubi: Fix out of bounds write in volume update code
authorRichard Weinberger <richard@nod.at>
Sun, 21 Feb 2016 09:53:03 +0000 (10:53 +0100)
committerSasha Levin <sasha.levin@oracle.com>
Mon, 14 Mar 2016 16:42:31 +0000 (12:42 -0400)
commit325940deb74b23351f507d5f1e1e01592c1efa1c
treedd8275de00cb32fb34b2192055aceacf04d29f8e
parent5a4557b0eb8a2a0b3bccdcbc7a66b8b04262f878
ubi: Fix out of bounds write in volume update code

[ Upstream commit e4f6daac20332448529b11f09388f1d55ef2084c ]

ubi_start_leb_change() allocates too few bytes.
ubi_more_leb_change_data() will write up to req->upd_bytes +
ubi->min_io_size bytes.

Cc: stable@vger.kernel.org
Signed-off-by: Richard Weinberger <richard@nod.at>
Reviewed-by: Boris Brezillon <boris.brezillon@free-electrons.com>
Signed-off-by: Sasha Levin <sasha.levin@oracle.com>
drivers/mtd/ubi/upd.c