[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH v9 07/20] block: deprecate "encryption=on" in fa
From: |
Daniel P. Berrange |
Subject: |
Re: [Qemu-devel] [PATCH v9 07/20] block: deprecate "encryption=on" in favor of "encrypt.format=aes" |
Date: |
Tue, 20 Jun 2017 13:02:06 +0100 |
User-agent: |
Mutt/1.8.0 (2017-02-23) |
On Tue, Jun 20, 2017 at 01:44:50PM +0200, Alberto Garcia wrote:
> On Mon 19 Jun 2017 07:34:42 PM CEST, Daniel P. Berrange wrote:
> > Historically the qcow & qcow2 image formats supported a property
> > "encryption=on" to enable their built-in AES encryption. We'll
> > soon be supporting LUKS for qcow2, so need a more general purpose
> > way to enable encryption, with a choice of formats.
> >
> > This introduces an "encrypt.format" option, which will later be
> > joined by a number of other "encrypt.XXX" options. The use of
> > a "encrypt." prefix instead of "encrypt-" is done to facilitate
> > mapping to a nested QAPI schema at later date.
> >
> > e.g. the preferred syntax is now
> >
> > qemu-img create -f qcow2 -o encrypt.format=aes demo.qcow2
> >
> > Signed-off-by: Daniel P. Berrange <address@hidden>
> > + if (encryptfmt) {
> > + buf = qemu_opt_get_del(opts, BLOCK_OPT_ENCRYPT);
> > + if (buf != NULL) {
> > + g_free(buf);
>
> If you use qemu_opt_get() instead then you don't need "buf" at all, do
> you?
IIRC, we needed to delete the option from opts, otherwise something
will later complain that there are opts that are not consumed.
>
> > + if (encryptfmt) {
> > + buf = qemu_opt_get_del(opts, BLOCK_OPT_ENCRYPT);
> > + if (buf != NULL) {
> > + g_free(buf);
>
> Same here.
>
> Everything else looks fine.
>
> Reviewed-by: Alberto Garcia <address@hidden>
Regards,
Daniel
--
|: https://berrange.com -o- https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org -o- https://fstop138.berrange.com :|
|: https://entangle-photo.org -o- https://www.instagram.com/dberrange :|
- [Qemu-devel] [PATCH v9 03/20] qcow: document another weakness of qcow AES encryption, (continued)
- [Qemu-devel] [PATCH v9 03/20] qcow: document another weakness of qcow AES encryption, Daniel P. Berrange, 2017/06/19
- [Qemu-devel] [PATCH v9 05/20] iotests: skip 042 with qcow which dosn't support zero sized images, Daniel P. Berrange, 2017/06/19
- [Qemu-devel] [PATCH v9 06/20] iotests: skip 048 with qcow which doesn't support resize, Daniel P. Berrange, 2017/06/19
- [Qemu-devel] [PATCH v9 08/20] qcow: make encrypt_sectors encrypt in place, Daniel P. Berrange, 2017/06/19
- [Qemu-devel] [PATCH v9 10/20] qcow2: make qcow2_encrypt_sectors encrypt in place, Daniel P. Berrange, 2017/06/19
- [Qemu-devel] [PATCH v9 09/20] qcow: convert QCow to use QCryptoBlock for encryption, Daniel P. Berrange, 2017/06/19
- [Qemu-devel] [PATCH v9 07/20] block: deprecate "encryption=on" in favor of "encrypt.format=aes", Daniel P. Berrange, 2017/06/19
[Qemu-devel] [PATCH v9 12/20] qcow2: extend specification to cover LUKS encryption, Daniel P. Berrange, 2017/06/19
[Qemu-devel] [PATCH v9 14/20] qcow2: add iotests to cover LUKS encryption support, Daniel P. Berrange, 2017/06/19
[Qemu-devel] [PATCH v9 11/20] qcow2: convert QCow2 to use QCryptoBlock for encryption, Daniel P. Berrange, 2017/06/19
[Qemu-devel] [PATCH v9 15/20] iotests: enable tests 134 and 158 to work with qcow (v1), Daniel P. Berrange, 2017/06/19
[Qemu-devel] [PATCH v9 16/20] block: rip out all traces of password prompting, Daniel P. Berrange, 2017/06/19
[Qemu-devel] [PATCH v9 13/20] qcow2: add support for LUKS encryption format, Daniel P. Berrange, 2017/06/19