QEMU With E2K User Support
Go to file
Daniel P. Berrange e6b636779b Add -f FMT / --format FMT arg to qemu-nbd
Currently the qemu-nbd program will auto-detect the format of
any disk it is given. This behaviour is known to be insecure.
For example, if qemu-nbd initially exposes a 'raw' file to an
unprivileged app, and that app runs

   'qemu-img create -f qcow2 -o backing_file=/etc/shadow /dev/nbd0'

then the next time the app is started, the qemu-nbd will now
detect it as a 'qcow2' file and expose /etc/shadow to the
unprivileged app.

The only way to avoid this is to explicitly tell qemu-nbd what
disk format to use on the command line, completely disabling
auto-detection. This patch adds a '-f' / '--format' arg for
this purpose, mirroring what is already available via qemu-img
and qemu commands.

  qemu-nbd --format raw -p 9000 evil.img

will now always use raw, regardless of what format 'evil.img'
looks like it contains

Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
[Use errx, not err. - Paolo]
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
2013-04-15 14:29:20 -05:00
audio
backends qemu-char: Call fe_claim / fe_release when not using qdev chr properties 2013-04-04 19:21:25 -05:00
block rbd: add an asynchronous flush 2013-04-15 10:18:05 +02:00
bsd-user
default-configs hw: move ARM CPU cores to hw/cpu/, configure with default-configs/ 2013-04-08 18:13:16 +02:00
disas target-i386: add AES-NI instructions 2013-04-13 13:51:57 +02:00
docs Typo, spelling and grammatical fixes 2013-04-12 14:33:20 +02:00
fpu fpu: Correct edgecase in float64_muladd 2013-04-15 16:06:15 +02:00
fsdev
gdb-xml
hw virtio-serial: cleanup: remove qdev field. 2013-04-15 10:22:05 -05:00
include virtio-serial: cleanup: remove qdev field. 2013-04-15 10:22:05 -05:00
ldscripts
libcacard
linux-headers linux-headers: Update to v3.9-rc2 2013-04-01 11:50:04 -06:00
linux-user linux-user: pass correct host flags to eventfd2 call 2013-04-12 14:33:20 +02:00
net hw: move headers to include/ 2013-04-08 18:13:10 +02:00
pc-bios hw: move headers to include/ 2013-04-08 18:13:10 +02:00
pixman@97336fad32
po po: Update German translation 2013-04-04 00:28:37 +02:00
qapi
qga qemu-ga: ga_get_fd_handle(): abort if fd_counter overflows 2013-04-02 09:06:11 -05:00
QMP
qobject qjson: to_json() case QTYPE_QSTRING is buggy, rewrite 2013-04-13 19:40:25 +00:00
qom
roms
scripts trace: [stderr] Port to generic event information and new control interface 2013-03-28 14:19:57 +01:00
slirp oslib-posix: rename socket_set_nonblock() to qemu_set_nonblock() 2013-04-02 11:47:37 -04:00
stubs
sysconfigs/target
target-alpha
target-arm hw: move headers to include/ 2013-04-08 18:13:10 +02:00
target-cris
target-i386 target-i386: add AES-NI instructions 2013-04-13 13:51:57 +02:00
target-lm32 hw: move headers to include/ 2013-04-08 18:13:10 +02:00
target-m68k
target-microblaze Typo, spelling and grammatical fixes 2013-04-12 14:33:20 +02:00
target-mips target-mips: fix mipsdsp_mul_q15_q15 and tests for MAQ_SA_W_PHL/PHR 2013-04-15 16:07:57 +02:00
target-moxie target-moxie: Fix VMState registration 2013-04-12 14:30:39 +02:00
target-openrisc
target-ppc hw: move headers to include/ 2013-04-08 18:13:10 +02:00
target-s390x Typo, spelling and grammatical fixes 2013-04-12 14:33:20 +02:00
target-sh4 hw: move headers to include/ 2013-04-08 18:13:10 +02:00
target-sparc
target-unicore32
target-xtensa
tcg Merge branch 'tci' of git://qemu.weilnetz.de/qemu 2013-04-13 13:50:06 +02:00
tests target-mips: fix mipsdsp_mul_q15_q15 and tests for MAQ_SA_W_PHL/PHR 2013-04-15 16:07:57 +02:00
tpm hw: move headers to include/ 2013-04-08 18:13:10 +02:00
trace trace: rebuild generated-events.o when configuration changes 2013-03-28 14:19:57 +01:00
ui Merge remote-tracking branch 'luiz/queue/qmp' into staging 2013-04-02 14:07:35 -05:00
util unicode: New mod_utf8_codepoint() 2013-04-13 19:39:59 +00:00
.exrc
.gitignore .gitignore: rename trace/generated-tracers.dtrace 2013-03-28 14:19:57 +01:00
.gitmodules
.mailmap
aio-posix.c
aio-win32.c
arch_init.c hw: move headers to include/ 2013-04-08 18:13:10 +02:00
async.c
balloon.c
block-migration.c
block.c block: Introduce bdrv_pwritev() for qcow2_save_vmstate 2013-04-15 08:26:18 +02:00
blockdev-nbd.c hw: move headers to include/ 2013-04-08 18:13:10 +02:00
blockdev.c hw: move headers to include/ 2013-04-08 18:13:10 +02:00
blockjob.c
bt-host.c
bt-vhci.c
Changelog
cmd.c
cmd.h
CODING_STYLE
configure block: ssh: Use libssh2_sftp_fsync (if supported by libssh2) to flush to disk. 2013-04-15 10:18:05 +02:00
COPYING
COPYING.LIB
coroutine-gthread.c
coroutine-sigaltstack.c
coroutine-ucontext.c
coroutine-win32.c
cpu-exec.c Merge branch 'mingw' of git://qemu.weilnetz.de/qemu 2013-04-13 14:31:54 +02:00
cpus.c Check effective suspension of TCG thread 2013-04-12 18:27:16 +02:00
cputlb.c
device_tree.c
device-hotplug.c
disas.c
dma-helpers.c
dump-stub.c
dump.c
exec.c hw: move headers to include/ 2013-04-08 18:13:10 +02:00
gdbstub.c hw: move headers to include/ 2013-04-08 18:13:10 +02:00
HACKING
hmp-commands.hx Revert "New QMP command query-cpu-max and HMP command cpu_max" 2013-04-12 09:41:54 -04:00
hmp.c Revert "New QMP command query-cpu-max and HMP command cpu_max" 2013-04-12 09:41:54 -04:00
hmp.h Revert "New QMP command query-cpu-max and HMP command cpu_max" 2013-04-12 09:41:54 -04:00
iohandler.c
ioport.c
kvm-all.c
kvm-stub.c
LICENSE
main-loop.c main-loop: drop the BQL if the I/O appears to be spinning 2013-04-05 12:53:33 -05:00
MAINTAINERS MAINTAINERS: update for source code movement 2013-04-08 18:13:16 +02:00
Makefile Update Makefile to actually install the new efi-enabled nic roms that are used by default. 2013-04-15 10:22:04 -05:00
Makefile.objs configure: Don't fall back to gthread coroutine backend 2013-04-08 10:38:44 -05:00
Makefile.target
memory_mapping-stub.c
memory_mapping.c
memory.c
migration-exec.c
migration-fd.c
migration-tcp.c
migration-unix.c
migration.c oslib-posix: rename socket_set_nonblock() to qemu_set_nonblock() 2013-04-02 11:47:37 -04:00
monitor.c Revert "New QMP command query-cpu-max and HMP command cpu_max" 2013-04-12 09:41:54 -04:00
nbd.c oslib-posix: rename socket_set_nonblock() to qemu_set_nonblock() 2013-04-02 11:47:37 -04:00
os-posix.c
os-win32.c qemu-timer: move timeBeginPeriod/timeEndPeriod to os-win32 2013-04-12 18:27:16 +02:00
page_cache.c
qapi-schema-test.json
qapi-schema.json qapi: use valid JSON in schema 2013-04-12 09:41:54 -04:00
qdev-monitor.c
qdict-test-data.txt
qemu-bridge-helper.c qemu-bridge-helper: force usage of a very high MAC address for the bridge 2013-03-28 12:58:52 -05:00
qemu-char.c qemu-char: another io_add_watch_poll fix 2013-04-15 10:22:05 -05:00
qemu-coroutine-io.c
qemu-coroutine-lock.c
qemu-coroutine-sleep.c
qemu-coroutine.c
qemu-doc.texi block: ssh: Use libssh2_sftp_fsync (if supported by libssh2) to flush to disk. 2013-04-15 10:18:05 +02:00
qemu-img-cmds.hx
qemu-img.c
qemu-img.texi
qemu-io.c
qemu-log.c
qemu-nbd.c Add -f FMT / --format FMT arg to qemu-nbd 2013-04-15 14:29:20 -05:00
qemu-nbd.texi Add -f FMT / --format FMT arg to qemu-nbd 2013-04-15 14:29:20 -05:00
qemu-options-wrapper.h
qemu-options.h
qemu-options.hx block: Add support for Secure Shell (ssh) block device. 2013-04-15 10:18:05 +02:00
qemu-seccomp.c
qemu-tech.texi
qemu-timer.c qemu-timer: move timeBeginPeriod/timeEndPeriod to os-win32 2013-04-12 18:27:16 +02:00
qemu.sasl
qmp-commands.hx Revert "New QMP command query-cpu-max and HMP command cpu_max" 2013-04-12 09:41:54 -04:00
qmp.c
qtest.c
readline.c
README
rules.mak
savevm.c Merge remote-tracking branch 'stefanha/block' into staging 2013-04-15 08:02:41 -05:00
spice-qemu-char.c
tcg-runtime.c
tci.c tci: Make tcg temporaries local to tcg_qemu_tb_exec 2013-04-11 19:58:21 +02:00
thread-pool.c
thunk.c
trace-events xhci: remove unimplemented printfs 2013-04-03 09:55:49 +02:00
translate-all.c
translate-all.h
user-exec.c
VERSION
version.rc
vl.c Revert "New QMP command query-cpu-max and HMP command cpu_max" 2013-04-12 09:41:54 -04:00
xbzrle.c
xen-all.c hw: move headers to include/ 2013-04-08 18:13:10 +02:00
xen-mapcache.c hw: move headers to include/ 2013-04-08 18:13:10 +02:00
xen-stub.c hw: move headers to include/ 2013-04-08 18:13:10 +02:00

Read the documentation in qemu-doc.html or on http://wiki.qemu.org

- QEMU team