Re: [RFC PATCH 3/6] security/fbfam: Use the api to manage statistics
From: Jann Horn <jannh@google.com>
Date: 2020-09-10 20:29:04
Also in:
linux-fsdevel, linux-security-module, lkml
From: Jann Horn <jannh@google.com>
Date: 2020-09-10 20:29:04
Also in:
linux-fsdevel, linux-security-module, lkml
On Thu, Sep 10, 2020 at 10:21 PM Kees Cook [off-list ref] 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.