Libvirt provides a portable, long term stable C API for managing the virtualization technologies provided by many operating systems. It includes support for QEMU, KVM, Xen, LXC, bhyve, Virtuozzo, VMware vCenter and ESX, VMware Desktop, Hyper-V, VirtualBox and the POWER Hypervisor.
Go to file
Luyao Huang 87b9437f89 storage: fix crash caused by no check return before set close
https://bugzilla.redhat.com/show_bug.cgi?id=1087104#c5

When trying to use an invalid offset to virStorageVolUpload(), libvirt
fails in virFDStreamOpenFileInternal(), although it seems libvirt does
not check the return in storageVolUpload(), and calls
virFDStreamSetInternalCloseCb() right after.  But stream doesn't have a
privateData (is NULL) yet, and the daemon crashes then.

0  0x00007f09429a9c10 in pthread_mutex_lock () from /lib64/libpthread.so.0
1  0x00007f094514dbf5 in virMutexLock (m=<optimized out>) at util/virthread.c:88
2  0x00007f09451cb211 in virFDStreamSetInternalCloseCb at fdstream.c:795
3  0x00007f092ff2c9eb in storageVolUpload at storage/storage_driver.c:2098
4  0x00007f09451f46e0 in virStorageVolUpload at libvirt.c:14000
5  0x00007f0945c78fa1 in remoteDispatchStorageVolUpload at remote_dispatch.h:14339
6  remoteDispatchStorageVolUploadHelper at remote_dispatch.h:14309
7  0x00007f094524a192 in virNetServerProgramDispatchCall at rpc/virnetserverprogram.c:437

Signed-off-by: Luyao Huang <lhuang@redhat.com>
2014-12-03 17:36:07 +01:00
.gnulib@9565c3be73 maint: update to latest gnulib 2014-09-06 19:14:43 -06:00
build-aux bracket-spacing: Add syntax-check for unnecessary curly brackets 2014-11-14 17:13:36 +01:00
daemon Replace virDomainSnapshotFree with virObjectUnref 2014-12-02 11:03:41 -05:00
docs build, docs: Let make see the dependencies for html/*.html 2014-12-02 07:50:18 +01:00
examples examples: Add support for the guest agent lifecycle event 2014-11-24 15:47:01 +01:00
gnulib
include Implement public API for virDomainGetFSInfo 2014-11-24 10:02:08 -05:00
m4 build: fix build with older dbus headers 2014-11-20 06:41:53 -07:00
po Transform VIR_ERROR into VIR_WARN in detect_scsi_host_caps 2014-11-07 16:44:48 +01:00
src storage: fix crash caused by no check return before set close 2014-12-03 17:36:07 +01:00
tests network: dnsmasq: Don't format lease file path 2014-12-03 14:22:40 +01:00
tools virsh: vol-upload disallow negative offset 2014-12-03 08:43:59 -05:00
.ctags
.dir-locals.el
.gitignore gitignore: use wildcard for configure's temporary files 2014-11-06 16:56:21 +01:00
.gitmodules
.mailmap maint: update .mailmap 2014-10-06 08:23:47 -06:00
AUTHORS.in Cleanup maintainers list 2014-10-15 10:16:47 +02:00
autobuild.sh
autogen.sh maint: detect VPATH builds when checking for gnulib update 2014-06-04 16:06:55 -06:00
bootstrap
bootstrap.conf internal: add macro to round value to the next closest power of 2 2014-11-24 22:05:55 +01:00
cfg.mk Replace virDomainSnapshotFree with virObjectUnref 2014-12-02 11:03:41 -05:00
ChangeLog-old
config-post.h
configure.ac maint: use portable shell 2014-11-19 12:13:14 -07:00
COPYING
COPYING.LESSER
HACKING docs: Adjust contributor guidelines about curly brackets 2014-11-14 17:13:36 +01:00
libvirt-lxc.pc.in Add pkg-config files for libvirt-qemu & libvirt-lxc 2014-06-23 16:17:27 +01:00
libvirt-qemu.pc.in Add pkg-config files for libvirt-qemu & libvirt-lxc 2014-06-23 16:17:27 +01:00
libvirt.pc.in Add pkg-config files for libvirt-qemu & libvirt-lxc 2014-06-23 16:17:27 +01:00
libvirt.spec.in Generate a MAC when loading a config instead of package update 2014-12-02 15:56:33 +01:00
Makefile.am examples: Introduce domtop 2014-07-18 16:39:54 +02:00
Makefile.nonreentrant
mingw-libvirt.spec.in Move virConnect related APIs out of libvirt.h.in 2014-10-24 17:23:51 +01:00
README
README-hacking
run.in Add PKG_CONFIG_PATH to run.in script. 2014-06-26 14:32:35 +01:00
TODO

         LibVirt : simple API for virtualization

  Libvirt is a C toolkit to interact with the virtualization capabilities
of recent versions of Linux (and other OSes). It is free software
available under the GNU Lesser General Public License. Virtualization of
the Linux Operating System means the ability to run multiple instances of
Operating Systems concurrently on a single hardware system where the basic
resources are driven by a Linux instance. The library aim at providing
long term stable C API initially for the Xen paravirtualization but
should be able to integrate other virtualization mechanisms if needed.

Daniel Veillard <veillard@redhat.com>