All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/3] Patches to enable chroot for all users
@ 2013-03-20 12:53 Tal Tchwella
  2013-03-20 12:53 ` [PATCH 1/3] enabled " Tal Tchwella
                   ` (3 more replies)
  0 siblings, 4 replies; 6+ messages in thread
From: Tal Tchwella @ 2013-03-20 12:53 UTC (permalink / raw)
  To: linux-kernel; +Cc: tchwella

I want to suggest adding chroot capability to all users.
The following patches enable that capability, while considering the security mechanism needed to disable escape routes for chroots by non-root users,
and keeping chroot backward-compatible for root users.
The first patch establishes the concept of multi-user chroot, while disabling checks for root user in the chroot process.
The second patch checks whether a fd that is sent to a chroot application by a non-root user refers to a directory. 
If that is the case, that fd is skipped, to disable an escape route. 
The third patch disables the option for applications that have open fds to directories to be chrooted by a non-root user.

Any comments, feedback and suggestions are appreciated!

Thanks,
Tal


Tal Tchwella (3):
  enabled chroot for all users
  socket checks for uds fds transfer
  open fds check when starting chroot

 fs/exec.c             |    3 +++
 fs/open.c             |   32 ++++++++++++++++++++++++++++++--
 include/linux/sched.h |   12 ++++++++++++
 init/main.c           |    1 +
 kernel/fork.c         |    2 ++
 net/core/scm.c        |    9 +++++++++
 6 files changed, 57 insertions(+), 2 deletions(-)

-- 
1.7.9.5


^ permalink raw reply	[flat|nested] 6+ messages in thread
* [PATCH 0/3] Patches to enable chroot for all users
@ 2013-03-20 13:09 tal.tchwella
  2013-03-20 13:09 ` [PATCH 2/3] socket checks for uds fds transfer tal.tchwella
  0 siblings, 1 reply; 6+ messages in thread
From: tal.tchwella @ 2013-03-20 13:09 UTC (permalink / raw)
  To: linux-kernel; +Cc: tchwella

From: Tal Tchwella <tchwella@mit.edu>

I want to suggest adding chroot capability to all users.
The following patches enable that capability, while considering the security mechanism needed to disable escape routes for chroots by non-root users,
and keeping chroot backward-compatible for root users.
The first patch establishes the concept of multi-user chroot, while disabling checks for root user in the chroot process.
The second patch checks whether a fd that is sent to a chroot application by a non-root user refers to a directory. 
If that is the case, that fd is skipped, to disable an escape route. 
The third patch disables the option for applications that have open fds to directories to be chrooted by a non-root user.

These patches were applied and test on linux-kernel 3.2.0-31-generic.

Any comments, feedback and suggestions are appreciated!

Thanks,
Tal


Tal Tchwella (3):
  enabled chroot for all users
  socket checks for uds fds transfer
  open fds check when starting chroot

 fs/exec.c             |    3 +++
 fs/open.c             |   32 ++++++++++++++++++++++++++++++--
 include/linux/sched.h |   12 ++++++++++++
 init/main.c           |    1 +
 kernel/fork.c         |    2 ++
 net/core/scm.c        |    9 +++++++++
 6 files changed, 57 insertions(+), 2 deletions(-)

-- 
1.7.9.5


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2013-03-20 15:16 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-03-20 12:53 [PATCH 0/3] Patches to enable chroot for all users Tal Tchwella
2013-03-20 12:53 ` [PATCH 1/3] enabled " Tal Tchwella
2013-03-20 12:53 ` [PATCH 2/3] socket checks for uds fds transfer Tal Tchwella
2013-03-20 12:53 ` [PATCH 3/3] open fds check when starting chroot Tal Tchwella
2013-03-20 15:16 ` [PATCH 0/3] Patches to enable chroot for all users Rob Landley
2013-03-20 13:09 tal.tchwella
2013-03-20 13:09 ` [PATCH 2/3] socket checks for uds fds transfer tal.tchwella

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.