components/openstack/nova/patches/07-CVE-2013-7048.patch
author Drew Fisher <drew.fisher@oracle.com>
Mon, 31 Mar 2014 16:44:02 -0700
branchs11-update
changeset 3028 5e73a3a3f66a
permissions -rw-r--r--
PSARC/2013/350 OpenStack for Solaris (Umbrella) PSARC/2014/007 OpenStack client API components for Grizzly PSARC/2014/048 OpenStack Keystone (OpenStack Identity Service) PSARC/2014/049 OpenStack Nova (OpenStack Compute Service) PSARC/2014/054 OpenStack Cinder (OpenStack Block Storage Service) PSARC/2014/055 OpenStack Glance (OpenStack Image Service) PSARC/2014/058 OpenStack Horizon (OpenStack Dashboard) PSARC/2014/059 OpenStack Neutron (OpenStack Networking Service) 17531161 greenlet doesn't build with gcc 4.7.X 18143276 greenlet can crash with register window corruption on MP SPARC 18290089 integrate cinderclient 18290097 integrate glanceclient 18290102 integrate keystoneclient 18290109 integrate neutronclient 18290113 integrate novaclient 18290119 integrate swiftclient 18290125 integrate quantumclient 18307582 Request to integrate Cinder into userland 18307595 Request to integrate Glance into userland 18307626 Request to integrate Horizon into userland 18307641 Request to integrate Keystone into userland 18307650 Request to integrate Neutron into userland 18307659 Request to integrate Nova into userland 18321909 a few Python packages deliver both po and mo files 18362900 Dnsmasq's SMF method_credential is missing a privilege 18363793 Dnsmasq should use SIOCSXARP ioctl

Upstream patch fixed in Grizzly 2013.1.5, Havana 2013.2.2, Icehouse

commit 9bd7fff8c0160057643cfc37c5e2b1cd3337d6aa
Author: Xavier Queralt <[email protected]>
Date:   Wed Nov 27 20:44:36 2013 +0100

    Enforce permissions in snapshots temporary dir
    
    Live snapshots creates a temporary directory where libvirt driver
    creates a new image from the instance's disk using blockRebase.
    Currently this directory is created with 777 permissions making this
    directory accessible by all the users in the system.
    
    This patch changes the tempdir permissions so they have the o+x
    flag set, which is what libvirt needs to be able to write in it and
    
    Closes-Bug: #1227027
    Change-Id: I767ff5247b4452821727e92b668276004fc0f84d
    (cherry picked from commit 8a34fc3d48c467aa196f65eed444ccdc7c02f19f)

diff --git a/nova/virt/libvirt/driver.py b/nova/virt/libvirt/driver.py
index 6b977cb..4cc85f1 100755
--- a/nova/virt/libvirt/driver.py
+++ b/nova/virt/libvirt/driver.py
@@ -1191,9 +1191,8 @@ class LibvirtDriver(driver.ComputeDriver):
             try:
                 out_path = os.path.join(tmpdir, snapshot_name)
                 if live_snapshot:
-                    # NOTE (rmk): libvirt needs to be able to write to the
-                    #             temp directory, which is owned nova.
-                    utils.execute('chmod', '777', tmpdir, run_as_root=True)
+                    # NOTE(xqueralt): libvirt needs o+x in the temp directory
+                    os.chmod(tmpdir, 0o701)
                     self._live_snapshot(virt_dom, disk_path, out_path,
                                         image_format)
                 else: