Skip to content

fscrypt: report correct st_size for encrypted symlinks

Eric Biggers linux-ext4 linux-f2fs-devel linux-fscrypt linux-fsdevel linux-mtd stable 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest5 patches 1 replyIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/5fscrypt: add fscrypt_symlink_getattr() for computing st_sizefs/crypto/hooks.c include/linux/fscrypt.h+51 -00 replies
2/5ext4: report correct st_size for encrypted symlinksfs/ext4/symlink.c+11 -10 replies
3/5f2fs: report correct st_size for encrypted symlinksfs/f2fs/namei.c+11 -10 replies
4/5ubifs: report correct st_size for encrypted symlinksfs/ubifs/file.c+12 -10 replies
5/5fscrypt: remove mention of symlink st_size quirk from documentationDocumentation/filesystems/fscrypt.rst+0 -50 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/5] fscrypt: report correct st_size for encrypted symlinks

This series makes the stat() family of syscalls start reporting the correct size for encrypted symlinks.

See patch 1 for a detailed explanation of the problem and solution.

Patch 1 adds a helper function that computes the correct size for an encrypted symlink. Patches 2-4 make the filesystems with fscrypt support use it, and patch 5 updates the documentation.

This series applies to mainline commit 3dbdb38e2869.

Eric Biggers (5):
fscrypt: add fscrypt_symlink_getattr() for computing st_size
ext4: report correct st_size for encrypted symlinks
f2fs: report correct st_size for encrypted symlinks
ubifs: report correct st_size for encrypted symlinks
fscrypt: remove mention of symlink st_size quirk from documentation

 Documentation/filesystems/fscrypt.rst |  5 ---
 fs/crypto/hooks.c                     | 44 +++++++++++++++++++++++++++
 fs/ext4/symlink.c                     | 12 +++++++-
 fs/f2fs/namei.c                       | 12 +++++++-
 fs/ubifs/file.c                       | 13 +++++++-
 include/linux/fscrypt.h               |  7 +++++
 6 files changed, 85 insertions(+), 8 deletions(-)

base-commit: 3dbdb38e286903ec220aaf1fb29a8d94297da246

Signature · 1 line
2.32.0