lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Tue, 18 Feb 2020 11:30:40 -0800
From:   Randy Dunlap <rdunlap@...radead.org>
To:     Stephen Smalley <sds@...ho.nsa.gov>,
        LKML <linux-kernel@...r.kernel.org>,
        linux-security-module <linux-security-module@...r.kernel.org>
Cc:     John Johansen <john.johansen@...onical.com>,
        Kees Cook <keescook@...omium.org>,
        Micah Morton <mortonm@...omium.org>,
        James Morris <jmorris@...ei.org>,
        "Serge E. Hallyn" <serge@...lyn.com>,
        Paul Moore <paul@...l-moore.com>,
        Eric Paris <eparis@...isplace.org>,
        Casey Schaufler <casey@...aufler-ca.com>,
        Kentaro Takeda <takedakn@...data.co.jp>,
        Tetsuo Handa <penguin-kernel@...ove.SAKURA.ne.jp>
Subject: Re: [RFC PATCH] security: <linux/lsm_hooks.h>: fix all kernel-doc
 warnings

On 2/18/20 6:03 AM, Stephen Smalley wrote:
> On 2/16/20 2:08 AM, Randy Dunlap wrote:
>> From: Randy Dunlap <rdunlap@...radead.org>
>>
>> Fix all kernel-doc warnings in <linux/lsm_hooks.h>.
>> Fixes the following warnings:
>>
>> ../include/linux/lsm_hooks.h:1830: warning: Function parameter or member 'quotactl' not described in 'security_list_options'
>> ../include/linux/lsm_hooks.h:1830: warning: Function parameter or member 'quota_on' not described in 'security_list_options'
>> ../include/linux/lsm_hooks.h:1830: warning: Function parameter or member 'sb_free_mnt_opts' not described in 'security_list_options'
>> ../include/linux/lsm_hooks.h:1830: warning: Function parameter or member 'sb_eat_lsm_opts' not described in 'security_list_options'
>> ../include/linux/lsm_hooks.h:1830: warning: Function parameter or member 'sb_kern_mount' not described in 'security_list_options'
>> ../include/linux/lsm_hooks.h:1830: warning: Function parameter or member 'sb_show_options' not described in 'security_list_options'
>> ../include/linux/lsm_hooks.h:1830: warning: Function parameter or member 'sb_add_mnt_opt' not described in 'security_list_options'
>> ../include/linux/lsm_hooks.h:1830: warning: Function parameter or member 'd_instantiate' not described in 'security_list_options'
>> ../include/linux/lsm_hooks.h:1830: warning: Function parameter or member 'getprocattr' not described in 'security_list_options'
>> ../include/linux/lsm_hooks.h:1830: warning: Function parameter or member 'setprocattr' not described in 'security_list_options'
>> ../include/linux/lsm_hooks.h:1830: warning: Function parameter or member 'locked_down' not described in 'security_list_options'
>> ../include/linux/lsm_hooks.h:1830: warning: Function parameter or member 'perf_event_open' not described in 'security_list_options'
>> ../include/linux/lsm_hooks.h:1830: warning: Function parameter or member 'perf_event_alloc' not described in 'security_list_options'
>> ../include/linux/lsm_hooks.h:1830: warning: Function parameter or member 'perf_event_free' not described in 'security_list_options'
>> ../include/linux/lsm_hooks.h:1830: warning: Function parameter or member 'perf_event_read' not described in 'security_list_options'
>> ../include/linux/lsm_hooks.h:1830: warning: Function parameter or member 'perf_event_write' not described in 'security_list_options'
>>
>> Signed-off-by: Randy Dunlap <rdunlap@...radead.org>
>> Cc: John Johansen <john.johansen@...onical.com>
>> Cc: Kees Cook <keescook@...omium.org>
>> Cc: Micah Morton <mortonm@...omium.org>
>> Cc: James Morris <jmorris@...ei.org>
>> Cc: "Serge E. Hallyn" <serge@...lyn.com>
>> Cc: linux-security-module@...r.kernel.org
>> Cc: Paul Moore <paul@...l-moore.com>
>> Cc: Stephen Smalley <sds@...ho.nsa.gov>
>> Cc: Eric Paris <eparis@...isplace.org>
>> Cc: Casey Schaufler <casey@...aufler-ca.com>
>> Cc: Kentaro Takeda <takedakn@...data.co.jp>
>> Cc: Tetsuo Handa <penguin-kernel@...ove.SAKURA.ne.jp>
>> ---
>> Notes:
>> a. The location for some of these might need to be modified.
>> b. 'locked_down' was just missing a final ':'.
>> c. Added a new section: Security hooks for perf events.
>>
>>   include/linux/lsm_hooks.h |   36 +++++++++++++++++++++++++++++++++++-
>>   1 file changed, 35 insertions(+), 1 deletion(-)
>>
>> --- lnx-56-rc1.orig/include/linux/lsm_hooks.h
>> +++ lnx-56-rc1/include/linux/lsm_hooks.h
>> @@ -136,6 +140,10 @@
>>    *    @sb superblock being remounted
>>    *    @data contains the filesystem-specific data.
>>    *    Return 0 if permission is granted.
>> + * @sb_kern_mount:
>> + *     Mount this @sb if allowed by permissions.
>> + * @sb_show_options:
>> + *     Show (print on @m) mount options for this @sb.
>>    * @sb_umount:
>>    *    Check permission before the @mnt file system is unmounted.
>>    *    @mnt contains the mounted file system.
> 
> Thanks for doing this.  Note that some of the existing kernel-doc comments for these hooks include a separate line describing each parameter (not just embedded in the function description) and a line describing the return value.  Is that optional for kernel-doc? Obviously what you have added here is an improvement, just wondering whether it suffices or needs further augmentation.

Hi Stephen,

The additional kernel-doc comments that you refer to are obviously Good to Have,
but they are not required.  I didn't feel comfortable or qualified to add
all of that info, but if anyone wants to help/contribute, please do so.

thanks.
-- 
~Randy

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ