5293 Commits

Author SHA1 Message Date
Richard W.M. Jones
9e582f9cf4 EPEL 5: qemu-img in RHEL 5 doesn't let you create 512 byte qcow2 image.
I checked the source of qemu-img and this is not possible to create.
2013-10-18 19:43:53 +01:00
Richard W.M. Jones
d35729d684 RHEL 5: Don't use 'truncate' command in tests.
Use 'guestfish sparse' instead, which is roughly equivalent.

See commit ef1514aa1e
and commit 39df80dcc0.
(cherry picked from commit 18c93ac61f)
2013-10-18 09:12:40 +01:00
Richard W.M. Jones
8c8f833537 EPEL 5: Revert "Use pkg-config for Python"
In RHEL 5, python doesn't have pkg-config configuration.

This reverts commit ba2e4f1794.
2013-10-17 22:45:14 +01:00
Richard W.M. Jones
dbd34c6947 EPEL 5: ruby: Use old rake/rdoctask and rake/gempackagetask.
The 'begin ... rescue' code is supposed to ensure these old packages
are required, but for reasons not understood this doesn't work on
ancient Ruby 1.8.5 in RHEL 5.
2013-10-17 22:45:14 +01:00
Richard W.M. Jones
13a9733fb8 EPEL 5: Remove Linux capabilities.
Linux file capabilities are not supported in RHEL 5, and the
cap_*_file functions don't exist in the libcap library (although
confusingly they are in the header file).
2013-10-17 22:45:14 +01:00
Richard W.M. Jones
49ba9324f8 EPEL 5: Disable valgrind.
Ancient automake didn't have AM_SUBST_NOTMAKE.
2013-10-17 22:45:13 +01:00
Richard W.M. Jones
3f6ea65904 EPEL 5: No libtoolize --install option. 2013-10-17 22:45:13 +01:00
Richard W.M. Jones
d0136bc8aa EPEL 5: Revert "daemon: remove call to obsolete udevsettle"
This reverts commit b6413f8dbe.
2013-10-17 22:45:13 +01:00
Richard W.M. Jones
0533583754 EPEL 5: Ignore sparsify error if qemu-img --help is killed by a signal. 2013-10-17 22:45:13 +01:00
Richard W.M. Jones
0e29c1ea90 EPEL 5: Disable tar --xz test.
Although xz is available, ancient tar didn't have the --xz option.
2013-10-17 22:45:13 +01:00
Richard W.M. Jones
628cc664e5 EPEL 5: Revert "daemon: Remove e2prog hack (only needed for RHEL 5)."
This reverts commit 163e030ee1.
2013-10-17 22:45:13 +01:00
Richard W.M. Jones
74a3698379 EPEL 5: Don't use sgabios.
Old qemu doesn't support '-device' parameter.
2013-10-17 22:45:13 +01:00
Richard W.M. Jones
9a77f3071f EPEL 5: Revert "Mac OS X: Use libtool --mode=execute instead of LD_LIBRARY_PATH"
This reverts commit 61c9ea496e.
2013-10-17 22:45:13 +01:00
Richard W.M. Jones
53bffd9d0f EPEL 5: podwrapper: Don't use Pod::Man.
This unfortunately means the man pages are generated as plain text.
However that's necessary as Pod::Man does not have an output_string
method.
2013-10-17 22:45:13 +01:00
Richard W.M. Jones
42da2432bf EPEL 5: podwrapper: Remove HTML output.
It requires perl Pod::Simple::XHTML which did not exist in
RHEL 5 era.
2013-10-17 22:45:13 +01:00
Richard W.M. Jones
33195f966d EPEL 5: Add 1 second pause after unmounting any filesystem.
This fixes the test-charset-fidelity test case.  A simpler example
which fails without this is:

  guestfish <<EOF
  sparse test1.img 1G
  run
  part-disk /dev/sda mbr
  mkfs msdos /dev/sda1
  mount /dev/sda1 /
  touch /foo
  umount /
  mkfs ntfs /dev/sda1
  # Next command would fail:
  mount /dev/sda1 /
  vfs-type /dev/sda1 -x
  EOF
2013-10-17 22:45:13 +01:00
Richard W.M. Jones
19ce5c576a EPEL 5: Add mkisofs to package list.
This package contains the 'isoinfo' program which is required
to implement the corresponding API and for tests to pass.
2013-10-17 22:45:13 +01:00
Richard W.M. Jones
2a51142015 EPEL 5: Remove Fedora MD test images.
On RHEL 5, mdadm is not able to create md devices with aliases,
eg. '/dev/md/boot'.
2013-10-17 22:45:13 +01:00
Richard W.M. Jones
aeeecfdbb0 EPEL 5: sparsify: Fix command line options for old qemu-img.
This didn't have -o backing_file etc.  Use old -b and -F options instead.
2013-10-17 22:45:13 +01:00
Richard W.M. Jones
751ea66fc7 EPEL 5: Fix blkid to return "LVM2_member" for PVs.
Old blkid in RHEL 5 didn't return the right thing for PVs.
2013-10-17 22:45:13 +01:00
Richard W.M. Jones
d35083900f EPEL 5: Disable libvirt attach method. 2013-10-17 22:45:13 +01:00
Richard W.M. Jones
2d836027a0 EPEL 5: Add "null vmchannel" back for qemu without virtio-serial support. 2013-10-17 22:45:13 +01:00
Richard W.M. Jones
cb25d3c32f EPEL 5: Remove id= from -drive parameter on qemu command line. 2013-10-17 22:45:13 +01:00
Richard W.M. Jones
20674c5467 EPEL 5: Pass --preserve-dup-deps explicitly to libtool.
See this thread:
https://lists.gnu.org/archive/html/bug-gnulib/2012-06/msg00162.html
2013-10-17 22:45:13 +01:00
Richard W.M. Jones
a26861d9eb EPEL 5: Replace format6 with format4 in OCaml gettext routines. 2013-10-17 22:45:13 +01:00
Richard W.M. Jones
6f8097c9fb EPEL 5: Old ocamlopt didn't support debugging (-g option). 2013-10-17 22:45:13 +01:00
Richard W.M. Jones
a45170e0d7 EPEL 5: Add gnulib utimensat module.
This function is missing in RHEL 5-era kernels.
2013-10-17 22:45:13 +01:00
Richard W.M. Jones
8bf06ca604 EPEL 5: Define le64toh, le32toh if not defined. 2013-10-17 22:45:13 +01:00
Richard W.M. Jones
c0eceb1bd1 EPEL 5: Remove PHP bindings. 2013-10-17 22:45:13 +01:00
Richard W.M. Jones
9a427b97c0 EPEL 5: Remove GObject / GObject Introspection / GJS bindings. 2013-10-17 22:45:13 +01:00
Richard W.M. Jones
68b094e0b0 EPEL 5: Remove Erlang bindings. 2013-10-17 22:45:13 +01:00
Richard W.M. Jones
7ad71f29ce EPEL 5: Don't use C99-style variable decls in for-loop. 2013-10-17 22:45:13 +01:00
Richard W.M. Jones
4adfd0f665 EPEL 5: Replace macro AC_STRUCT_DIRENT_D_TYPE for ancient autoconf. 2013-10-17 22:09:08 +01:00
Richard W.M. Jones
dc3cbf4232 EPEL 5: Remove AS_ECHO_N for ancient autoconf. 2013-10-17 22:09:08 +01:00
Richard W.M. Jones
31d54be5c2 EPEL 5: Remove checks which fail with ancient qemu.
Note that g->app.qemu_version and g->app.qemu_devices will both
be empty strings.
2013-10-17 22:09:08 +01:00
Richard W.M. Jones
205d72417a Version 1.20.12. 1.20.12 2013-10-17 15:27:03 +01:00
Richard W.M. Jones
c1a0822b79 daemon: Fix xfs_info parser because of new format.
The old parser had several problems: firstly it called the error path
sometimes without calling reply_with_error causing a protocol hang.
More seriously it had hard-coded line numbers, and since Fedora 21 the
output of xfs_info has changed, moving lines around.

Change the parser to be more robust against added fields by using the
first name on the line as the section name, thus 'bsize=' is
interpreted differently depending on whether it appears in the "data"
section or the "naming" section.

Ensure also that we don't call the error path without calling
reply_with_error, which is a side-effect of the above change.

(cherry picked from commit 8abd0a83b3)
(cherry picked from commit adcdc44004)
2013-10-17 13:22:16 +01:00
Richard W.M. Jones
6a451ff65c fish: CVE-2013-4419: Fix insecure temporary directory handling for remote guestfish (RHBZ#1016960).
When using the guestfish --remote or guestfish --listen options,
guestfish would create a socket in a known location
(/tmp/.guestfish-$UID/socket-$PID).

The location has to be a known one in order for both ends to
communicate.  However no checking was done that the containing
directory (/tmp/.guestfish-$UID) is owned by the user.  Thus another
user could create this directory and potentially modify sockets owned
by another user's guestfish client or server.

This commit fixes the issue by creating the directory unconditionally,
and then checking that the directory has the correct owner and
permissions, thus preventing another user from creating the directory
first.

If guestfish sees a suspicious socket directory it will print an error
like this and exit with an error status:

  guestfish: '/tmp/.guestfish-1000' is not a directory or has insecure owner or permissions

Thanks: Michael Scherer for discovering this issue.

Version 2:
 - Add assigned CVE number.
 - Update documentation.

Signed-off-by: Richard W.M. Jones <rjones@redhat.com>
(cherry picked from commit 54fb09e052)
(cherry picked from commit b23fca294e)
2013-10-17 13:21:23 +01:00
Richard W.M. Jones
baac27d95a fish: Use UNIX_PATH_MAX instead of hard-coded value for max length of socket buf.
(cherry picked from commit 9f1bcbca55)
(cherry picked from commit e42a6e5e54)
2013-10-17 13:21:17 +01:00
Richard W.M. Jones
0be5cd3357 Version 1.20.11. 1.20.11 2013-08-27 12:03:46 +01:00
Richard W.M. Jones
6d763b86d6 align/domains.c: Remove include of progname.h.
This was inadvertently broken by
commit d241876bd1.  This wasn't
noticed until I updated gnulib.
2013-08-27 11:56:57 +01:00
Richard W.M. Jones
2b43749535 daemon: sh: Fix missing initializer which caused segfault (RHBZ#1000121).
Thanks: Olaf Hering.
(cherry picked from commit fc2947b112)
(cherry picked from commit aea9761126)
2013-08-24 11:48:53 +01:00
Richard W.M. Jones
96ac6508d1 daemon: hivex: Define empty hivex_finalize function in case !HAVE_HIVEX.
Thanks: Olaf Hering (see previous commit).
(cherry picked from commit d188594b11)
(cherry picked from commit 379ced49de)
2013-08-24 11:48:48 +01:00
Olaf Hering
05507b9dbd tests: change noinst to check
This change avoids the hard requirement for qemu-tools during package
build.

Signed-off-by: Olaf Hering <olaf@aepfle.de>
(cherry picked from commit cb7b1c56b7)
(cherry picked from commit 9b62b700ba)
2013-08-24 11:48:28 +01:00
Richard W.M. Jones
4872697c84 fish: Document that guestfish --remote --add won't work as expected (RHBZ#998513).
(cherry picked from commit 7e39695461)
(cherry picked from commit 23e9cc95fa)
2013-08-24 11:46:50 +01:00
Richard W.M. Jones
5c69b054d7 launch: direct: Don't try to wait for qemu if parent process forked (RHBZ#998482).
When using guestfish --remote, libguestfs is not the parent of qemu,
so waitpid is expected to return -ECHILD.  And indeed guestfish --remote
would print a bogus error message in this case:

  libguestfs: error: waitpid (qemu): No child processes

If the parent process forked into the background, then it should have
called 'set_recovery_proc 0' so we can use this to determine if we
need to wait for qemu.

Thanks: Kazuya Saito for reporting and identifying the issue.

(cherry picked from commit a843b5e5e3)
(cherry picked from commit 8b354dbbfd)
2013-08-24 11:46:41 +01:00
Or Goshen
d94a55df00 Fix to src/proto.c in libguestfs so it will compile with portablexdr under mingw.
(cherry picked from commit 18b40a8892)
(cherry picked from commit 5fe8a679ee)
2013-08-24 11:45:53 +01:00
Richard W.M. Jones
1820cdd87d FAQ: Replace the debugging section (again) with a checklist of information we need to start to fix bugs.
(cherry picked from commit abc59d776a)
(cherry picked from commit a9f7bd6934)
2013-08-24 11:45:19 +01:00
Richard W.M. Jones
2763d94884 FAQ: Move #debug anchor back to the right place.
This was accidentally moved by this commit:

  commit b8b5ed65c2
  Author: Richard W.M. Jones <rjones@redhat.com>
  Date:   Wed May 23 11:46:23 2012 +0100

    FAQ: Add section about using libguestfs in closed source programs.

(cherry picked from commit 0a484e868f)
(cherry picked from commit e02bbeabb1)
2013-08-24 11:45:02 +01:00
Richard W.M. Jones
0415edfec7 FAQ: Delete section about Ubuntu 10.04.
The link was broken, and we don't support Ubuntu 10.04 (maybe the
'oldlinux' branch does).

(cherry picked from commit 937a9a3532)
(cherry picked from commit 023dc6f23c)
2013-08-24 11:44:56 +01:00