verify_root_map(9)
π NAME π
okay so this is verify_root_map(9) from the Kernel API Manual, and it's literally the function that checks the uid 0 mapping. bestie, it's giving "are you actually allowed to do this" energy π₯
β¨ SYNOPSIS β¨
bool verify_root_map (const struct file *file , struct user_namespace
*map_ns , struct uid_gid_map *new_map );
π ARGUMENTS π
fileβ the idmapping file, bestie. that's the file in question πmap_nsβ the user namespace of the target process πnew_mapβ the requested idmap, aka the map being asked for π¦
πΈ DESCRIPTION πΈ
so here's the tea: if a process requests mapping parent uid 0 into the new ns, this function verifies that the process writing the map had the CAP_SETFCAP capability. why? because the target process will be able to write fscaps that are valid in ancestor user namespaces. no cap, no mapping β periodt πβ¨
π RETURN π
trueif the mapping is allowed πfalseif not π
π«Ά SEE ALSO π«Ά
- Kernel file
./kernel/user_namespace.c make_kuid(9)from_kuid(9)from_kuid_munged(9)make_kgid(9)from_kgid(9)from_kgid_munged(9)make_kprojid(9)from_kprojid(9)from_kprojid_munged(9)
shoutout to ./kernel for the source/version vibe and October 2026 for the date stamp β iconic, no cap ππ
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms