1. 16 1月, 2013 1 次提交
  2. 15 1月, 2013 2 次提交
    • J
      securityselinuxhelper.c: Don't try to include xattr.h if not available · 7ae3f2d5
      John Ferlan 提交于
      Commit 907a39e7 missed adding the WITH_ATTR around #include <attr/xattr.h>
      resulting in a build failure:
      
        CC     libsecurityselinuxhelper_la-securityselinuxhelper.lo
        securityselinuxhelper.c:27:24: fatal error: attr/xattr.h: No such file or directory
        compilation terminated.
        make[2]: *** [libsecurityselinuxhelper_la-securityselinuxhelper.lo] Error 1
        make[2]: Leaving directory `/home/jferlan/libvirt.work/tests'
        make[1]: *** [all-recursive] Error 1
        make[1]: Leaving directory `/home/jferlan/libvirt.work'
        make: *** [all] Error 2
      7ae3f2d5
    • D
      Add missing stubs to securityselinuxhelper.c · 7184af13
      Daniel P. Berrange 提交于
      Make sure we override both the raw and non-raw stubs in
      securityselinuxhelper.c. Also add diagnostics if
      securityselinuxlabeltest fails a test item
      7184af13
  3. 14 1月, 2013 2 次提交
    • D
      Add a test suite for validating SELinux labelling · 907a39e7
      Daniel P. Berrange 提交于
      There are many aspects of the guest XML which result in the
      SELinux driver applying file labelling. With the increasing
      configuration options it is desirable to test this behaviour.
      It is not possible to assume that the test suite has the
      ability to set SELinux labels. Most filesystems though will
      support extended attributes. Thus for the purpose of testing,
      it is possible to extend the existing LD_PRELOAD hack to
      override setfilecon() and getfilecon() to simply use the
      'user.libvirt.selinux' attribute for the sake of testing.
      Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
      907a39e7
    • D
      Rename HAVE_GNUTLS to WITH_GNUTLS · bccd4a8c
      Daniel P. Berrange 提交于
      bccd4a8c
  4. 11 1月, 2013 2 次提交
  5. 10 1月, 2013 2 次提交
  6. 09 1月, 2013 2 次提交
  7. 08 1月, 2013 2 次提交
  8. 07 1月, 2013 1 次提交
    • O
      conf: Parse and format the new XML · 535aed56
      Osier Yang 提交于
      Like "rawio", "sgio" is only allowed for block disk of device
      type "lun".
      
      It doesn't default disk->sgio to "filtered" when parsing, as
      it won't be able to distinguish explicitly requested "filtered"
      and a default "filtered" in driver then. We have to error out for
      explicit request when the kernel doesn't support the new sysfs
      knob "unpriv_sgio", however, for defaulted "filtered", we can
      just ignore it if the kernel doesn't support "unpriv_sgio".
      535aed56
  9. 05 1月, 2013 2 次提交
  10. 21 12月, 2012 16 次提交
  11. 19 12月, 2012 2 次提交
  12. 18 12月, 2012 2 次提交
    • D
      Add support for <hostdev mode="capabilities"> · aae0fc2a
      Daniel P. Berrange 提交于
      The <hostdev> device type has long had a redundant "mode"
      attribute, which has always been "subsys". This finally
      introduces a new mode "capabilities", which will be used
      by the LXC driver for device assignment. Since container
      based virtualization uses a single kernel, the idea of
      assigning physical PCI devices doesn't make sense. It is
      still reasonable to assign USB devices, but for assigning
      arbitrary nodes in /dev, the new 'capabilities' mode is
      to be used.
      
      The first capability support is 'storage', which is for
      assignment of block devices. Functionally this is really
      pretty similar to the <disk> support. The only difference
      is the device node name is identical in both host and
      container namespaces.
      
          <hostdev mode='capabilities' type='storage'>
            <source>
              <block>/dev/sdf1</block>
            </source>
          </hostdev>
      
      The second capability support is 'misc', which is for
      assignment of character devices. There is no existing
      parallel to this. Again the device node is the same
      inside & outside the container.
      
          <hostdev mode='capabilities' type='misc'>
            <source>
              <char>/dev/input/event3</char>
            </source>
          </hostdev>
      
      The reason for keeping the char & storage devices
      separate in the domain XML, is to mirror the split
      in the node device XML. NB the node device XML does
      not yet report character devices, but that's another
      new patch to come
      Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
      aae0fc2a
    • V
      tests: Add tests for sysinfo · 347a712a
      Viktor Mihajlovski 提交于
      Test cases for virSysinfoRead. Initially, there are tests for
      x86 (DMI based) and s390 (/proc/... based).
      In lack of PPC data, I have stubbed out the test for it, but it
      can be added with a minimal effort.
      Signed-off-by: NViktor Mihajlovski <mihajlov@linux.vnet.ibm.com>
      347a712a
  13. 17 12月, 2012 3 次提交
    • G
      tests: add one -device video device testcase · ed6fc41b
      Guannan Ren 提交于
      The testcase is for testing non-fixed PCI address for primary
      video device and using video args to -deivce qemu option.
      ed6fc41b
    • G
      qemu: use newer -device video device in qemu commandline · aa51202b
      Guannan Ren 提交于
      '-device VGA' maps to '-vga std'
      '-device cirrus-vga' maps to '-vga cirrus'
      '-device qxl-vga' maps to '-vga qxl'
                   (there is also '-device qxl' for secondary devices)
      '-device vmware-svga' maps to '-vga vmware'
      
      For qemu(>=1.2), we can use -device to replace -vga for video
      device. For the primary video device, the patch tries to use 0x2
      slot for matching old qemu. If the 0x2 slot is allocated already,
      the addr property could help for using any available slot.
      For qemu(< 1.2), we keep using -vga for primary device.
      aa51202b
    • G
      qemu: add qemu vga devices caps and one cap to mark them usable · 4c993d8a
      Guannan Ren 提交于
      QEMU_CAPS_DEVICE_QXL          -device qxl
      QEMU_CAPS_DEVICE_VGA          -device VGA
      QEMU_CAPS_DEVICE_CIRRUS_VGA   -device cirrus-vga
      QEMU_CAPS_DEVICE_VMWARE_SVGA  -device vmware-svga
      
      QEMU_CAPS_DEVICE_VIDEO_PRIMARY  /* safe to use -device XXX
                                       for primary video device */
      
      Fix a typo in qemuCapsObjectTypes, the string 'qxl' here
      should be -device qxl rather than -vga [...|qxl|..]
      4c993d8a
  14. 14 12月, 2012 1 次提交
    • L
      network: prevent dnsmasq from listening on localhost · d66eb786
      Laine Stump 提交于
      This patch resolves the problem reported in:
      
         https://bugzilla.redhat.com/show_bug.cgi?id=886663
      
      The source of the problem was the fix for CVE 2011-3411:
      
         https://bugzilla.redhat.com/show_bug.cgi?id=833033
      
      which was originally committed upstream in commit
      753ff83a. That commit improperly
      removed the "--except-interface lo" from dnsmasq commandlines when
      --bind-dynamic was used (based on comments in the latter bug).
      
      It turns out that the problem reported in the CVE could be eliminated
      without removing "--except-interface lo", and removing it actually
      caused each instance of dnsmasq to listen on localhost on port 53,
      which created a new problem:
      
      If another instance of dnsmasq using "bind-interfaces" (instead of
      "bind-dynamic") had already been started (or if another instance
      started later used "bind-dynamic"), this wouldn't have any immediately
      visible ill effects, but if you tried to start another dnsmasq
      instance using "bind-interfaces" *after* starting any libvirt
      networks, the new dnsmasq would fail to start, because there was
      already another process listening on port 53.
      
      (Subsequent to the CVE fix, another patch changed the network driver
      to put dnsmasq options in a conf file rather than directly on the
      dnsmasq commandline, but preserved the same options.)
      
      This patch changes the network driver to *always* add
      "except-interface=lo" to dnsmasq conf files, regardless of whether we use
      bind-dynamic or bind-interfaces. This way no libvirt dnsmasq instances
      are listening on localhost (and the CVE is still fixed).
      
      The actual code change is miniscule, but must be propogated through all
      of the test files as well.
      d66eb786