]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Impose a limit on the number of GEOM_CTL arguments.
authormarkj <markj@FreeBSD.org>
Tue, 19 Feb 2019 21:22:22 +0000 (21:22 +0000)
committermarkj <markj@FreeBSD.org>
Tue, 19 Feb 2019 21:22:22 +0000 (21:22 +0000)
commit467f20b5058832d25276962899748597370ca5b5
tree2cf16e4b2ccd703cf3a0ede8cff4c74cd7187bde
parent2fa70908ad2d670f2c8a672257b8efdb7bb14ad0
Impose a limit on the number of GEOM_CTL arguments.

Otherwise a privileged user can trigger a memory allocation of
unbounded size, or an integer overflow in the subsequent
geom_alloc_copyin() call, leading to out-of-bounds accesses.

Hard-code a large limit to circumvent this problem.

admbug: 854
Reported by: Anonymous of the Shellphish Grill Team
Reviewed by: ae
MFC after: 1 week
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D19251
sys/geom/geom_ctl.c