Close all non-stdio FDs in virt-login-shell (CVE-2013-4400) CVE-2013-4400-2
authorDaniel P. Berrange <berrange@redhat.com>
Wed, 9 Oct 2013 14:14:34 +0000 (15:14 +0100)
committerDaniel P. Berrange <berrange@redhat.com>
Mon, 21 Oct 2013 13:03:52 +0000 (14:03 +0100)
commitb7fcc799ad5d8f3e55b89b94e599903e3c092467
tree1cbb288edd4142072d20ae676bf4e048d1a210ea
parent8c3586ea755c40d5e01b22cb7b5c1e668cdec994
Close all non-stdio FDs in virt-login-shell (CVE-2013-4400)

We don't want to inherit any FDs in the new namespace
except for the stdio FDs. Explicitly close them all,
just in case some do not have the close-on-exec flag
set.

Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
tools/virt-login-shell.c