qemu/docs/system
Eric Blake d9f059aa6c qemu-img: Deprecate use of -b without -F
Creating an image that requires format probing of the backing image is
potentially unsafe (we've had several CVEs over the years based on
probes leaking information to the guest on a subsequent boot, although
these days tools like libvirt are aware of the issue enough to prevent
the worst effects).  For example, if our probing algorithm ever
changes, or if other tools like libvirt determine a different probe
result than we do, then subsequent use of that backing file under a
different format will present corrupted data to the guest.
Fortunately, the worst effects occur only when the backing image is
originally raw, and we at least prevent commit into a probed raw
backing file that would change its probed type.

Still, it is worth starting a deprecation clock so that future
qemu-img can refuse to create backing chains that would rely on
probing, to encourage clients to avoid unsafe practices.  Most
warnings are intentionally emitted from bdrv_img_create() in the block
layer, but qemu-img convert uses bdrv_create() which cannot emit its
own warning without causing spurious warnings on other code paths.  In
the end, all command-line image creation or backing file rewriting now
performs a check.

Furthermore, if we probe a backing file as non-raw, then it is safe to
explicitly record that result (rather than relying on future probes);
only where we probe a raw image do we care about further warnings to
the user when using such an image (for example, commits into a
probed-raw backing file are prevented), to help them improve their
tooling.  But whether or not we make the probe results explicit, we
still warn the user to remind them to upgrade their workflow to supply
-F always.

iotest 114 specifically wants to create an unsafe image for later
amendment rather than defaulting to our new default of recording a
probed format, so it needs an update.  While touching it, expand it to
cover all of the various warnings enabled by this patch.  iotest 301
also shows a change to qcow messages.

Signed-off-by: Eric Blake <eblake@redhat.com>
Message-Id: <20200706203954.341758-11-eblake@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
2020-07-14 15:24:05 +02:00
..
arm docs/system: Document Aspeed boards 2020-06-05 17:23:09 +01:00
s390x docs/system/s390x: Improve the 3270 documentation 2020-07-13 11:40:52 +02:00
build-platforms.rst docs/system: convert Texinfo documentation to rST 2020-03-06 10:05:12 +00:00
conf.py docs: Generate qemu.1 manpage with Sphinx 2020-03-06 11:06:55 +00:00
cpu-models-mips.rst.inc docs/system: Convert qemu-cpu-models.texi to rST 2020-03-06 10:05:12 +00:00
cpu-models-x86.rst.inc qemu-cpu-models.rst: Document -noTSX, mds-no, taa-no, and tsx-ctrl 2020-03-16 23:02:25 +01:00
deprecated.rst qemu-img: Deprecate use of -b without -F 2020-07-14 15:24:05 +02:00
device-url-syntax.rst.inc docs: Split out sections for the manpage into .rst.inc files 2020-03-06 11:06:55 +00:00
gdb.rst docs: Add to gdbstub documentation the PhyMemMode 2020-07-11 15:53:00 +01:00
images.rst docs/system: convert Texinfo documentation to rST 2020-03-06 10:05:12 +00:00
index.rst Documentation: create/move s390x documentation 2020-03-23 12:36:27 +01:00
invocation.rst docs: Split out sections for the manpage into .rst.inc files 2020-03-06 11:06:55 +00:00
ivshmem.rst docs/system: convert Texinfo documentation to rST 2020-03-06 10:05:12 +00:00
keys.rst docs: Split out sections for the manpage into .rst.inc files 2020-03-06 11:06:55 +00:00
keys.rst.inc docs: Split out sections for the manpage into .rst.inc files 2020-03-06 11:06:55 +00:00
license.rst docs/system: convert Texinfo documentation to rST 2020-03-06 10:05:12 +00:00
linuxboot.rst docs/system: convert Texinfo documentation to rST 2020-03-06 10:05:12 +00:00
managed-startup.rst docs/system: convert managed startup to rST. 2020-03-06 10:05:12 +00:00
monitor.rst hmp-commands-info.hx: Add rST documentation fragments 2020-03-06 10:05:12 +00:00
mux-chardev.rst docs: Split out sections for the manpage into .rst.inc files 2020-03-06 11:06:55 +00:00
mux-chardev.rst.inc docs: Split out sections for the manpage into .rst.inc files 2020-03-06 11:06:55 +00:00
net.rst docs/system: convert Texinfo documentation to rST 2020-03-06 10:05:12 +00:00
qemu-block-drivers.rst docs: Create defs.rst.inc as a place to define substitutions 2020-03-06 10:04:58 +00:00
qemu-block-drivers.rst.inc docs/system: put qemu-block-drivers body in an included file 2020-03-06 10:04:58 +00:00
qemu-cpu-models.rst docs/system: Convert qemu-cpu-models.texi to rST 2020-03-06 10:05:12 +00:00
qemu-manpage.rst docs: Generate qemu.1 manpage with Sphinx 2020-03-06 11:06:55 +00:00
quickstart.rst docs/system: convert Texinfo documentation to rST 2020-03-06 10:05:12 +00:00
security.rst docs/system: Convert security.texi to rST format 2020-03-06 10:05:12 +00:00
target-arm.rst docs/system: Document Aspeed boards 2020-06-05 17:23:09 +01:00
target-avr.rst target/avr: Add section into QEMU documentation 2020-07-11 11:02:05 +02:00
target-i386-desc.rst.inc pcspk: update docs/system/target-i386-desc.rst.inc 2020-07-06 17:01:11 +02:00
target-i386.rst docs: Split out sections for the manpage into .rst.inc files 2020-03-06 11:06:55 +00:00
target-m68k.rst docs: Roll semihosting option information into qemu-options.hx 2020-03-06 10:05:12 +00:00
target-mips.rst hw/mips/fuloong2e: Fix typo in Fuloong machine name 2020-05-26 13:20:48 +02:00
target-ppc.rst docs: Roll -prom-env and -g target-specific info into qemu-options.hx 2020-03-06 10:05:18 +00:00
target-rx.rst docs: Document the RX target 2020-06-22 18:37:12 +02:00
target-s390x.rst docs/s390x: document vfio-ccw 2020-06-05 17:13:11 +02:00
target-sparc64.rst docs: Roll -prom-env and -g target-specific info into qemu-options.hx 2020-03-06 10:05:18 +00:00
target-sparc.rst docs: Roll -prom-env and -g target-specific info into qemu-options.hx 2020-03-06 10:05:18 +00:00
target-xtensa.rst docs: Roll semihosting option information into qemu-options.hx 2020-03-06 10:05:12 +00:00
targets.rst target/avr: Add section into QEMU documentation 2020-07-11 11:02:05 +02:00
tls.rst docs/system: convert Texinfo documentation to rST 2020-03-06 10:05:12 +00:00
usb.rst docs/system: convert Texinfo documentation to rST 2020-03-06 10:05:12 +00:00
vnc-security.rst docs/system: convert Texinfo documentation to rST 2020-03-06 10:05:12 +00:00