Skip to content

Misc. redirect_dir=nofollow fixes

Amir Goldstein linux-unionfs 1 version Applied

Status from this message: Applied, thanks.

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest3 patches 22 repliesApplied

Patches in v1 Applied

#Subject and filesSizeRepliesApplied
1/3ovl: force read-only sb on failure to create index dirfs/overlayfs/super.c+6 -57 replies
2/3ovl: fix mount option checks for nfs_export with no upperdirDocumentation/filesystems/overlayfs.rst fs/overlayfs/super.c+20 -155 replies
3/3ovl: do not follow non-dir origin with redirect_dir=nofollowfs/overlayfs/namei.c+1 -13 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH 0/3] Misc. redirect_dir=nofollow fixes

Miklos, Vivek,

Following discussion on following an unsafe non-dir origin [1] and in a addition to a fix for the reported null uuid case [2] and to Vivek's doc clarification [3], I am proposing to piggy back existing config redirect_dir=nofollow to also not follow non-dir origin.

Like in the case of non-dir origin, following redirects behavior was added with no opt-out option in kernel v4.10. Later security concerns about following malformed redirects resulted in the redirect_dir=nofollow config option.

Without giving too much thought into how unsafe it can be to follow a bad origin, there is very low motication IMO to follow non-dir origin with redirect_dir=nofollow, because it is a configuration that prefers safety over correctness, so it just seems like the right thing to do.

The first two patches are independent bug fixes related to read-only NFS export, which can be taken regardless of non-dir origin nofollow. FYI, I found those bugs because I am using ro,index=off NFS export configuration for the new overlay fsnotify snaphsot series.

Thanks,
Amir.

[1] https://lore.kernel.org/linux-unionfs/CAJfpegv9h7ubuGy_6K4OCdZd3R7Z4HGmCDB2L7mO5bVoGd6MSA@mail.gmail.com/
[2] https://lore.kernel.org/linux-unionfs/[email protected]/
[3] https://lore.kernel.org/linux-unionfs/[email protected]/

Amir Goldstein (3):
ovl: force read-only sb on failure to create index dir
ovl: fix mount option checks for nfs_export with no upperdir
ovl: do not follow non-dir origin with redirect_dir=nofollow

 Documentation/filesystems/overlayfs.rst |  4 +--
 fs/overlayfs/namei.c                    |  2 +-
 fs/overlayfs/super.c                    | 42 ++++++++++++++-----------
 3 files changed, 27 insertions(+), 21 deletions(-)
Signature · 1 line
2.17.1