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:   Fri, 21 Apr 2017 13:41:44 +0100
From:   David Howells <dhowells@...hat.com>
To:     "Michael Kerrisk (man-pages)" <mtk.manpages@...il.com>
Cc:     dhowells@...hat.com, lkml <linux-kernel@...r.kernel.org>,
        linux-fsdevel <linux-fsdevel@...r.kernel.org>, hch@...radead.org
Subject: Re: Unchecked flags in statx(2) [Should be fixed before 4.11-final?]

Michael Kerrisk (man-pages) <mtk.manpages@...il.com> wrote:

>  I was reading your statx(2) man page, and noticed this text:
> 
>        Do not simply set mask to UINT_MAX as one or more bits may, in the
>        future, be used to specify an extension to the buffer.
> 
> (Here' 'mask' is the fourth argument to statx())
> 
> What is going on here? Why is there  not a check in the code to
> give EINVAL if any flag other than those in STATX_ALL (0x00000fffU)
> is specified? (There is a check that gives EINVAL flags in 
> STATX__RESERVED (0x80000000U), but STATX_ALL != ~STATX__RESERVED.

Yeah, I need to update that.  I sent you the manpage to have a look at before
the patch that added the reservation got merged - possibly before I even wrote
that patch.

> Similarly, there appears to be no check for invalid flags in the
> 'flags' argument of statx(). Why is there also not such a check
> there?

Like this?

	if (mask & STATX__RESERVED)
		return -EINVAL;

David

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ