CVE-2013-6456: Avoid unsafe use of /proc/$PID/root in LXC USB hotplug
authorDaniel P. Berrange <berrange@redhat.com>
Thu, 30 Jan 2014 16:34:19 +0000 (16:34 +0000)
committerDaniel P. Berrange <berrange@redhat.com>
Tue, 18 Feb 2014 15:52:23 +0000 (15:52 +0000)
commit398c88edfaef50b9b59eb2d9a61b07c9c940a661
treefd0e58cf669b0e2facbb5c6c5a2597a005c5c95a
parentdd055960df60c536957664f0ae3c591feecf7b09
CVE-2013-6456: Avoid unsafe use of /proc/$PID/root in LXC USB hotplug

Rewrite lxcDomainAttachDeviceHostdevSubsysUSBLive function
to use the virProcessRunInMountNamespace helper. This avoids
risk of a malicious guest replacing /dev with a absolute
symlink, tricking the driver into changing the host OS
filesystem.

Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
(cherry picked from commit 7fba01c15c1f886b4235825692b4c13e88dd9f7b)
src/lxc/lxc_driver.c