[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <855fe20ed05ea1aba21da3c9c05fcb025fc51763.camel@linux.ibm.com>
Date: Mon, 30 Nov 2020 12:10:59 -0500
From: Mimi Zohar <zohar@...ux.ibm.com>
To: Roberto Sassu <roberto.sassu@...wei.com>,
torvalds@...ux-foundation.org, hch@...radead.org
Cc: linux-integrity@...r.kernel.org,
linux-security-module@...r.kernel.org,
linux-kernel@...r.kernel.org, silviu.vlasceanu@...wei.com,
stable@...r.kernel.org
Subject: Re: [PATCH] ima: Don't modify file descriptor mode on the fly
On Thu, 2020-11-26 at 11:34 +0100, Roberto Sassu wrote:
> Commit a408e4a86b36b ("ima: open a new file instance if no read
> permissions") already introduced a second open to measure a file when the
> original file descriptor does not allow it. However, it didn't remove the
> existing method of changing the mode of the original file descriptor, which
> is still necessary if the current process does not have enough privileges
> to open a new one.
>
> Changing the mode isn't really an option, as the filesystem might need to
> do preliminary steps to make the read possible. Thus, this patch removes
> the code and keeps the second open as the only option to measure a file
> when it is unreadable with the original file descriptor.
>
> Cc: <stable@...r.kernel.org> # 4.20.x: 0014cc04e8ec0 ima: Set file->f_mode
> Fixes: 2fe5d6def1672 ("ima: integrity appraisal extension")
> Signed-off-by: Roberto Sassu <roberto.sassu@...wei.com>
Thanks, Roberto, Christoph. The patch is now queued in next-integrity.
Mimi
Powered by blists - more mailing lists