WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-changelog

[Xen-changelog] [qemu-xen-unstable] passthrough: fix security issue with

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [qemu-xen-unstable] passthrough: fix security issue with stubdoms
From: Ian Jackson <Ian.Jackson@xxxxxxxxxxxxx>
Date: Wed, 21 Oct 2009 09:35:03 -0700
Delivery-date: Wed, 21 Oct 2009 09:35:05 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-changelog-request@lists.xensource.com?subject=help>
List-id: BK change log <xen-changelog.lists.xensource.com>
List-post: <mailto:xen-changelog@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=unsubscribe>
Reply-to: xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
commit b4bb8b3f09d1c873f522f6aebe1f125a6d1854d0
Author: Ian Jackson <ian.jackson@xxxxxxxxxxxxx>
Date:   Wed Oct 21 16:42:15 2009 +0100

    passthrough: fix security issue with stubdoms
    
    this patch series fixes the outstanding security problem with stubdoms
    and pci passthrough.
    The idea is to allow mmio, irq and ioport remapping not only if the
    current domain IS_PRIV_FOR but also if the current domain has
    permissions over those mmio areas, irqs and ioports.
    This way a stubdom can only remap resources that currently "owns".
    This patch series also moves the de\assign_device hypercalls from the
    list of hypercalls made by qemu\stubdom to xend.
    
    The two patches must be applied at the same time otherwise pci
    passthrough won't work for HVM guests.
    
    [PATCH 2 of 2] qemu: do not call xc_assign_device
    
    This patch removes the call to xc_assign_device from qemu.
    
    Signed-off-by: Stefano Stabellini <stefano.stabellini@xxxxxxxxxxxxx>
---
 hw/pass-through.c |   10 ----------
 1 files changed, 0 insertions(+), 10 deletions(-)

diff --git a/hw/pass-through.c b/hw/pass-through.c
index a207b2c..cdf0f31 100644
--- a/hw/pass-through.c
+++ b/hw/pass-through.c
@@ -4168,7 +4168,6 @@ static struct pt_dev * register_real_device(PCIBus *e_bus,
     struct pt_dev *assigned_device = NULL;
     struct pci_dev *pci_dev;
     uint8_t e_device, e_intx;
-    struct pci_config_cf8 machine_bdf;
     char *key, *val;
     int msi_translate, power_mgmt;
 
@@ -4253,15 +4252,6 @@ static struct pt_dev * register_real_device(PCIBus 
*e_bus,
     assigned_device->is_virtfn = pt_dev_is_virtfn(pci_dev);
     pt_iomul_init(assigned_device, r_bus, r_dev, r_func);
 
-    /* Assign device */
-    machine_bdf.reg = 0;
-    machine_bdf.bus = r_bus;
-    machine_bdf.dev = r_dev;
-    machine_bdf.func = r_func;
-    rc = xc_assign_device(xc_handle, domid, machine_bdf.value);
-    if ( rc < 0 )
-        PT_LOG("Error: xc_assign_device error %d\n", rc);
-
     /* Initialize virtualized PCI configuration (Extended 256 Bytes) */
     for ( i = 0; i < PCI_CONFIG_SIZE; i++ )
         assigned_device->dev.config[i] = pci_read_byte(pci_dev, i);
--
generated by git-patchbot for /home/xen/git/qemu-xen-unstable.git

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] [qemu-xen-unstable] passthrough: fix security issue with stubdoms, Ian Jackson <=