[PATCH v2 1/4] seccomp: Add sysctl to display available actions

Kees Cook keescook at chromium.org
Tue Feb 14 00:26:39 UTC 2017


On Mon, Feb 13, 2017 at 4:25 PM, Tyler Hicks <tyhicks at canonical.com> wrote:
> kmemleak doesn't complain if we save it to a global. That makes sense
> because it means that we have a persistent reference to the allocated
> memory.
>
> However, kmemleak doesn't complain about this allocation as-is (meaning
> that I simply removed the call to kmemleak_not_leak()). From what I can
> tell, this is because a reference to the allocated ctl_table_header
> struct is saved when __register_sysctl_table() calls init_header(). I
> think kmemleak is seeing this reference when doing scans and
> (incorrectly) thinking that there's no leak.
>
> I think the safest/cleanest thing to do is leave the call to
> kmemleak_not_leak(). Let me know if you disagree.

Okay, that's cool. :) Thanks for checking!

-Kees

-- 
Kees Cook
Pixel Security




More information about the Linux-audit mailing list