Skip to content

idmapped mounts: extend testsuite and fixes

Christian Brauner fstests 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest7 patches 2 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/7idmapped-mounts: remove unused set_cloexec() helpersrc/idmapped-mounts/idmapped-mounts.c+0 -50 replies
2/7idmapped-mounts: add missing newline to print_r()src/idmapped-mounts/idmapped-mounts.c+1 -10 replies
3/7idmapped-mounts: split out run_test() functionsrc/idmapped-mounts/idmapped-mounts.c+41 -290 replies
4/7generic/637: add fscaps regression test.gitignore src/idmapped-mounts/Makefile src/idmapped-mounts/idmapped-mounts.c +3 more+188 -51 reply
5/7idmapped-mounts: refactor helperssrc/idmapped-mounts/mount-idmapped.c src/idmapped-mounts/utils.c src/idmapped-mounts/utils.h+223 -2550 replies
6/7idmapped-mounts: add nested userns creation helperssrc/idmapped-mounts/idmapped-mounts.c src/idmapped-mounts/mount-idmapped.c src/idmapped-mounts/utils.c +1 more+185 -460 replies
7/7generic/638: add nested user namespace tests.gitignore src/idmapped-mounts/Makefile src/idmapped-mounts/idmapped-mounts.c +4 more+771 -20 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/7] idmapped mounts: extend testsuite and fixes

From: Christian Brauner <[email protected]>

Hey,

This introduces two new idmapped mount tests.
The first test extends the v3 fscaps tests for idmapped mounts. The second test verified that idmapped mounts behave correctly when nested user namespaces are used. In essence it creates a fairly complex nested user namespace hierarchy and then tests whether file ownership changes are correctly reflected in all idmapped mounts as seen from all those user namespaces.
In addition this fixes a couple of minor things and shares more code between the mount-idmapped and idmapped-mounts binaries.

Thanks!
Christian

Christian Brauner (7):
idmapped-mounts: remove unused set_cloexec() helper
idmapped-mounts: add missing newline to print_r()
idmapped-mounts: split out run_test() function generic/637: add fscaps regression test
idmapped-mounts: refactor helpers
idmapped-mounts: add nested userns creation helpers generic/638: add nested user namespace tests

 .gitignore                            |   2 +
 src/idmapped-mounts/Makefile          |  16 +-
 src/idmapped-mounts/idmapped-mounts.c | 931 ++++++++++++++++++++++++--
 src/idmapped-mounts/mount-idmapped.c  | 228 +------
 src/idmapped-mounts/utils.c           | 359 ++++++++--
 src/idmapped-mounts/utils.h           | 102 ++-
 tests/generic/637                     |  42 ++
 tests/generic/637.out                 |   2 +
 tests/generic/638                     |  42 ++
 tests/generic/638.out                 |   2 +
 tests/generic/group                   |   2 +
 11 files changed, 1397 insertions(+), 331 deletions(-)
 create mode 100755 tests/generic/637
 create mode 100644 tests/generic/637.out
 create mode 100755 tests/generic/638
 create mode 100644 tests/generic/638.out

base-commit: 40818883aecd19581a71cc096d07eb9106c11b10

Signature · 1 line
2.27.0