Re: [PATCH] erofs: verify metadata accesses for file-backed mounts

Chunhai Guo <[email protected]>
Newsgroups org.ozlabs.lists.linux-erofs,org.kernel.vger.linux-kernel
Message-ID <[email protected]>
On 3/30/2026 10:20 AM, Gao Xiang wrote:
> For file-backed mounts, metadata is fetched via the page cache of
> backing inodes to avoid double caching and redundant copy ops, which is
> currently used by Android APEXes, ComposeFS and containerd for example.
> However, rw_verify_area() was missing prior to metadata accesses.
>
> Similar to vfs_iocb_iter_read(), fix this by:
>   - Enabling fanotify pre-content hooks on metadata accesses;
>   - security_file_permission() for security modules.
>
> Verified that fanotify pre-content hooks now works correctly.
>
> Fixes: fb176750266a ("erofs: add file-backed mount support")
> Acked-by: Amir Goldstein <[email protected]>
> Signed-off-by: Gao Xiang <[email protected]>
> ---

Reviewed-by: Chunhai Guo <[email protected]>


Thanks,
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.