unshare: Add support for mapping ranges of user/group IDs
Status from this message: Applied, thanks!
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v2 Latest6 patches 6 repliesApplied
- v15 patches 4 repliesSuperseded
Changes in v2 from the cover letter
- Add "auto" option for --map-users and --map-groups
- Add UID_BUFSIZ macro to hold the maximum size of a uid represented as a string
- Add some documentation for waitchild
- Add some helpers for forking and synchronizing
- Copy names from string_to_idarray into a buffer to add a nul-terminator, instead of modifying them directly
- Document new "auto" value for --map-user and --map-group
- Fix most of read_subid_range using spaces instead of tabs
- Fix typo of --group instead of --user
- Update doc comments for uint_to_id() and get_map_range()
- Use more meaningful numbers in map_ids
- Use pathname macros for /etc/sub{u,g}id
- Use sync helpers for idmap
Patches in v2 Applied
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/6 | include/c: Add abs_diff macroinclude/ | +8 | 0 replies | |
| 2/6 | unshare: Add waitchild helpersys-utils/ | +25 | 0 replies | |
| 3/6 | unshare: Add some helpers for forking and synchronizingsys-utils/ | +68 | 0 replies | |
| 4/6 | unshare: Add options to map blocks of user/group IDssys-utils/ | +251 | 0 replies | |
| 5/6 | unshare: Add option to automatically create user and group mapsinclude/ sys-utils/ | +85 | 0 replies | |
| 6/6 | unshare: Document --map-{groups,users,auto}sys-utils/ | +32 | 0 replies |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v2 yet.
Cover letter [PATCH v2 0/6] unshare: Add support for mapping ranges of user/group IDs
This series adds support for mapping ranges of user/group IDs using the newuidmap and newgidmap programs from shadow. The intent is to allow for root-less bootstrapping of Linux root filesystems with correct ownership. My primary inspiration is mmdebstrap [1], which uses unshare(2) to create Debian root filesystems without needing root access.
[1] https://gitlab.mister-muffin.de/josch/mmdebstrap
Changes in v2:
- Add "auto" option for --map-users and --map-groups
- Add UID_BUFSIZ macro to hold the maximum size of a uid represented as a string
- Add some documentation for waitchild
- Add some helpers for forking and synchronizing
- Copy names from string_to_idarray into a buffer to add a nul-terminator, instead of modifying them directly
- Document new "auto" value for --map-user and --map-group
- Fix most of read_subid_range using spaces instead of tabs
- Fix typo of --group instead of --user
- Update doc comments for uint_to_id() and get_map_range()
- Use more meaningful numbers in map_ids
- Use pathname macros for /etc/sub{u,g}id
- Use sync helpers for idmap
Sean Anderson (6):
include/c: Add abs_diff macro
unshare: Add waitchild helper
unshare: Add some helpers for forking and synchronizing
unshare: Add options to map blocks of user/group IDs
unshare: Add option to automatically create user and group maps
unshare: Document --map-{groups,users,auto}
include/c.h | 8 + include/pathnames.h | 3 + sys-utils/unshare.1.adoc | 32 +++ sys-utils/unshare.c | 477 ++++++++++++++++++++++++++++++++++----- 4 files changed, 465 insertions(+), 55 deletions(-)
Signature · 1 line
2.33.0