RFC user namespaces: add ns to user_struct
Get series with b4
b4 am [email protected]Versions newest first
- v1 RFC Latest8 patches 1 replyIn review
Patches in v1 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/8 | user namespaces: add ns to user_structfs/ fs/ include/ +5 more | +107 | 0 replies | |
| 2/8 | Bump the value of CAP_LAST_CAP to reflect the current last cap value.include/ | +4 | 0 replies | |
| 3/8 | containers: add CAP_NS_OVERRIDE capabilityinclude/ | +8 | 0 replies | |
| 4/8 | user namespace: enforce CAP_NS_OVERRIDE for cross-namespace killkernel/ | +5 | 1 reply | |
| 5/8 | userns: handle user namespaces in file sigiofs/ include/ | +48 | 0 replies | |
| 6/8 | userns: agp: remove uid comparison as security checkdrivers/ | +1 | 0 replies | |
| 7/8 | userns: reiser4: replace uid==0 check with capabilityfs/ | +1 | 0 replies | |
| 8/8 | userns: oom_kill: remove uid==0 checksmm/ | +1 | 0 replies |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.
Cover letter [RFC] [PATCH 0/8] user namespaces: add ns to user_struct
I'm working toward fixing up some of the remaining uid==0 and uid1==uid2 checks, and beginning to restrict capabilities within namespaces.
This patchset starts to do that by
1. improving per-ns user_struct storing
2. introducing CAP_NS_OVERRIDE
3. requiring CAP_NS_OVERRIDE to signal another user namespace
4. remove a few uid==0 checks
Especially the last 3 patches are a definite security improvement in the face of user namespaces.
The next steps would be
* add user_ns to siginfo
* signals delivered to another userns (like sigchld) send uid 0.
* fix up more uid and gid checks (sigh)
* convert struct key_user?
* introduce uid aliases
* per-process keyring
* stores (user_ns,uid) keys
* allows process which is really (user_ns1, uid1) to act as though it were (user_ns2, uid2) on objects in user_ns2
* convert struct kstat (may have serious lifetime issues)
That should leave us in a reasonable shape to start considering how to really handle file access.
I still have a set of patches which tag struct inode with user_ns and patch ext2+ext3. But it's at the end of my patch set for now.
Comments welcome, on these patches, on the outlined next steps, or on anything I'm forgetting.
(Against 2.6.24-rc3-mm2)
thanks,
-serge