Date: Sun, 26 Oct 2014 21:47:01 +0800 From: Tiwei Bie <btw@mail.ustc.edu.cn> To: mjg@freebsd.org Cc: freebsd-hackers@freebsd.org Subject: Questions with 'MPASS(ngrp <= ngroups_max)' assertion in kern_setgroups() Message-ID: <1414331221-29048-1-git-send-email-btw@mail.ustc.edu.cn>
next in thread | raw e-mail | index | archive | help
Hello, Mateusz! The check in kern_setgroups's callers is: if (gidsetsize > ngroups_max + 1) return (EINVAL); So, gidsetsize could be (ngroups_max + 1). And under this condition, the assertion MPASS(ngrp <= ngroups_max); in kern_setgroups() will fail. One of them should be fixed. Tiwei Bie
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?1414331221-29048-1-git-send-email-btw>