[RFC PATCH 3/6] security/fbfam: Use the api to manage statistics

Jann Horn jannh at google.com
Thu Sep 10 20:27:35 UTC 2020


On Thu, Sep 10, 2020 at 10:21 PM Kees Cook <keescook at chromium.org> wrote:
> Use the previous defined api to manage statistics calling it accordingly
> when a task forks, calls execve or exits.

You defined functions that return error codes in the previous patch,
but here you ignore the return values. That's a bad idea.

You should probably check the return value in execve() (and fail the
execution in the case where memory allocation fails), and make it so
that the other functions always succeed.



More information about the Linux-security-module-archive mailing list