1. 15 11月, 2014 1 次提交
  2. 03 11月, 2014 1 次提交
  3. 26 9月, 2014 1 次提交
  4. 24 9月, 2014 2 次提交
  5. 04 9月, 2014 1 次提交
  6. 22 8月, 2014 1 次提交
  7. 20 8月, 2014 1 次提交
  8. 04 8月, 2014 2 次提交
  9. 22 7月, 2014 1 次提交
  10. 21 7月, 2014 2 次提交
  11. 18 7月, 2014 1 次提交
    • M
      examples: Introduce domtop · 28d54aab
      Michal Privoznik 提交于
      There's this question on the list that is asked over and over again.
      How do I get {cpu, memory, ...} usage in percentage? Or its modified
      version: How do I plot nice graphs like virt-manager does?
      
      It would be nice if we have an example to inspire people. And that's
      what domtop should do. Yes, it could be written in different ways, but
      I've chosen this one as I think it show explicitly what users need to
      implement in order to imitate virt-manager's graphing.
      
      Note: The usage is displayed from host perspective. That is, how much
      host CPUs the domain is using. But it should be fairly simple to
      switch do just guest CPU usage if needed.
      Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
      28d54aab
  12. 16 7月, 2014 1 次提交
    • C
      Rework lxc apparmor profile · 9265f8ab
      Cédric Bosdonnat 提交于
      Rework the apparmor lxc profile abstraction to mimic ubuntu's container-default.
      This profile allows quite a lot, but strives to restrict access to
      dangerous resources.
      
      Removing the explicit authorizations to bash, systemd and cron files,
      forces them to keep the lxc profile for all applications inside the
      container. PUx permissions where leading to running systemd (and others
      tasks) unconfined.
      
      Put the generic files, network and capabilities restrictions directly
      in the TEMPLATE.lxc: this way, users can restrict them on a per
      container basis.
      9265f8ab
  13. 07 7月, 2014 1 次提交
  14. 18 6月, 2014 1 次提交
  15. 30 4月, 2014 1 次提交
  16. 27 3月, 2014 1 次提交
  17. 25 3月, 2014 1 次提交
  18. 21 3月, 2014 1 次提交
  19. 04 3月, 2014 2 次提交
  20. 12 2月, 2014 1 次提交
  21. 08 2月, 2014 1 次提交
  22. 20 1月, 2014 1 次提交
  23. 08 1月, 2014 1 次提交
  24. 25 12月, 2013 2 次提交
    • M
      event-test: Unregister close callback · f7fee15a
      Michal Privoznik 提交于
      When registering a close callback, the connection refcount is increased
      as the connection object is passed to the callback and hence we must
      prevent deleting it too soon. However, when closing the connection, the
      connection object is just unrefed. So whenever a connection with a close
      callback is closed, we end up with the connection object which has
      exactly one reference. Leaving the code as-is doesn't mean the end of
      the world as we know it, but why give a bad example?
      
      ==14531== 288 bytes in 1 blocks are still reachable in loss record 695 of 762
      ==14531==    at 0x4C2BDE4: calloc (in /usr/lib64/valgrind/vgpreload_memcheck-amd64-linux.so)
      ==14531==    by 0x4E9FE09: virAllocVar (viralloc.c:558)
      ==14531==    by 0x4EDBE45: virObjectNew (virobject.c:190)
      ==14531==    by 0x4F71AAC: virGetConnect (datatypes.c:116)
      ==14531==    by 0x4F78511: do_open (libvirt.c:1136)
      ==14531==    by 0x4F7B3AC: virConnectOpenAuth (libvirt.c:1481)
      ==14531==    by 0x4011D2: main (event-test.c:499)
      
      (and other leaks tied to virGetConnect())
      Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
      f7fee15a
    • M
      examples: Resurrect domsuspend example · e26cae6b
      Michal Privoznik 提交于
      This partially reverts 5eb4b042 and 62774afb.
      
      Rewrite the domsuspend example from scratch. This time do it right.
      Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
      e26cae6b
  25. 14 12月, 2013 2 次提交
  26. 05 12月, 2013 1 次提交
    • P
      examples: Remove broken bad example · 5eb4b042
      Peter Krempa 提交于
      The domsuspend example code is a really old and bad exmample of (how not
      to use) the libvirt API. Remove it as it's apparent that nobody tried to
      use it. It was broken and nobody complained.
      5eb4b042
  27. 26 11月, 2013 1 次提交
  28. 21 10月, 2013 1 次提交
    • D
      Don't link virt-login-shell against libvirt.so (CVE-2013-4400) · 3e2f27e1
      Daniel P. Berrange 提交于
      The libvirt.so library has far too many library deps to allow
      linking against it from setuid programs. Those libraries can
      do stuff in __attribute__((constructor) functions which is
      not setuid safe.
      
      The virt-login-shell needs to link directly against individual
      files that it uses, with all library deps turned off except
      for libxml2 and libselinux.
      
      Create a libvirt-setuid-rpc-client.la library which is linked
      to by virt-login-shell. A config-post.h file allows this library
      to disable all external deps except libselinux and libxml2.
      Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
      3e2f27e1
  29. 05 9月, 2013 1 次提交
    • E
      build: only install nwfilter examples when building nwfilter · b420df72
      Eric Blake 提交于
      'make rpm' with client_local set to 1 (by manual modification,
      or with RHEL 5 on s390) warns:
      
      RPM build errors:
          Installed (but unpackaged) file(s) found:
         /etc/libvirt/nwfilter/allow-arp.xml
         /etc/libvirt/nwfilter/allow-dhcp-server.xml
         /etc/libvirt/nwfilter/allow-dhcp.xml
         /etc/libvirt/nwfilter/allow-incoming-ipv4.xml
         /etc/libvirt/nwfilter/allow-ipv4.xml
         /etc/libvirt/nwfilter/clean-traffic.xml
         /etc/libvirt/nwfilter/no-arp-ip-spoofing.xml
         /etc/libvirt/nwfilter/no-arp-mac-spoofing.xml
         /etc/libvirt/nwfilter/no-arp-spoofing.xml
         /etc/libvirt/nwfilter/no-ip-multicast.xml
         /etc/libvirt/nwfilter/no-ip-spoofing.xml
         /etc/libvirt/nwfilter/no-mac-broadcast.xml
         /etc/libvirt/nwfilter/no-mac-spoofing.xml
         /etc/libvirt/nwfilter/no-other-l2-traffic.xml
         /etc/libvirt/nwfilter/no-other-rarp-traffic.xml
         /etc/libvirt/nwfilter/qemu-announce-self-rarp.xml
         /etc/libvirt/nwfilter/qemu-announce-self.xml
         /usr/share/polkit-1/actions/org.libvirt.api.policy
      
      The bulk of these are fixed with this patch.
      
      * examples/xml/nwfilter/Makefile.am (install-data-local)
      (uninstall-local): Make conditional.
      Signed-off-by: NEric Blake <eblake@redhat.com>
      b420df72
  30. 04 9月, 2013 1 次提交
    • E
      build: fix typo that broke 'make dist' · 11e80ddf
      Eric Blake 提交于
      Bug introduced in commit 5c6ff422; 'make dist' fails:
      
      make[3]: Entering directory `/home/eblake/libvirt-tmp/build3/examples/python'
      make[3]: *** No rule to make target `topoology.py', needed by `distdir'.  Stop.
      make[3]: Leaving directory `/home/eblake/libvirt-tmp/build3/examples/python'
      
      * examples/python/Makefile.am (EXTRA_DIST): Spell topology right.
      Signed-off-by: NEric Blake <eblake@redhat.com>
      11e80ddf
  31. 03 9月, 2013 1 次提交
  32. 23 8月, 2013 1 次提交
  33. 15 8月, 2013 1 次提交
  34. 30 7月, 2013 1 次提交
    • E
      examples: fix mingw build vs. printf · 6f4458a0
      Eric Blake 提交于
      Mingw *printf is a moving target; newer mingw now provides a version
      of asprintf() that fails to understand %lld:
      
        CC       event_test-event-test.o
      ../../../../examples/domain-events/events-c/event-test.c: In function 'myDomainEventRTCChangeCallback':
      ../../../../examples/domain-events/events-c/event-test.c:270:18: error: unknown conversion type character 'l' in format [-Werror=format=]
                        virDomainGetID(dom), offset) < 0)
                        ^
      
      But since our examples already admitted that they were hacking around
      a mingw deficiency, it is easier to just use printf() directly, coupled
      with <inttypes.h> macros, for a more portable work-around.
      
      * examples/domain-events/events-c/event-test.c
      (myDomainEventRTCChangeCallback): Use PRIdMAX instead of asprintf.
      Signed-off-by: NEric Blake <eblake@redhat.com>
      6f4458a0