From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:52328) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WORE5-0007Qk-E3 for qemu-devel@nongnu.org; Fri, 14 Mar 2014 08:28:42 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WORE0-00088f-IA for qemu-devel@nongnu.org; Fri, 14 Mar 2014 08:28:37 -0400 Received: from mx1.redhat.com ([209.132.183.28]:34928) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WORE0-00088H-8P for qemu-devel@nongnu.org; Fri, 14 Mar 2014 08:28:32 -0400 Received: from int-mx01.intmail.prod.int.phx2.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id s2ECSUGm022840 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Fri, 14 Mar 2014 08:28:31 -0400 Message-ID: <5322F5ED.8080509@redhat.com> Date: Fri, 14 Mar 2014 06:28:29 -0600 From: Eric Blake MIME-Version: 1.0 References: <1394785368-24437-1-git-send-email-armbru@redhat.com> In-Reply-To: <1394785368-24437-1-git-send-email-armbru@redhat.com> Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="3veqDlTM4ACrkuFbDHoFGsbkNADWpR6gP" Subject: Re: [Qemu-devel] [PATCH v2 for-2.0] blockdev: Refuse to open encrypted image unless paused List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Markus Armbruster , qemu-devel@nongnu.org Cc: kwolf@redhat.com, pbonzini@redhat.com, famz@redhat.com, stefanha@redhat.com This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --3veqDlTM4ACrkuFbDHoFGsbkNADWpR6gP Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable On 03/14/2014 02:22 AM, Markus Armbruster wrote: > Opening an encrypted image takes an additional step: setting the key. > Between open and the key set, the image must not be used. >=20 > We have some protection against accidental use in place: you can't > unpause a guest while we're missing keys. You can, however, hot-plug > block devices lacking keys into a running guest just fine, or insert > media lacking keys. In the latter case, notifying the guest of the > insert is delayed until the key is set, which may suffice to protect > at least some guests in common usage. >=20 > This patch makes the protection apply in more cases, in a rather > heavy-handed way: it doesn't let you open encrypted images unless > we're in a paused state. >=20 > It doesn't extend the protection to users other than the guest (block > jobs?). Use of runstate_check() from block.c is disgusting. Best I > can do right now. >=20 > Signed-off-by: Markus Armbruster > --- > v2: > * Don't break -incoming [Paolo] > * Update qemu-iotests/087 [Fam] Reviewed-by: Eric Blake --=20 Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org --3veqDlTM4ACrkuFbDHoFGsbkNADWpR6gP Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 Comment: Public key at http://people.redhat.com/eblake/eblake.gpg Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/ iQEcBAEBCAAGBQJTIvXtAAoJEKeha0olJ0Nq/SEIAKAcCtTGGviu/wfPdXf0r8J1 pO/hnotIg57+DLRF/xHF10nDe2i5yR9anV94VrI3nfs73vFInVWOzjs+yHcBlIPN Rh8HBMM23sjyNBeGiuENK4sET2hpG+mduS+qdoATdojEkX3KUT/IwazCSqlRPIxR JMrHRoUzeGT+dJWO4i++8SbVjSo9RRvDJDaBYo8u2OGk4RVcsiCCPQ0GyeZOaaMv ZOxc+gHCiNRFIy6RmB7+c7rc4TfxfGYJhtEZ+PCUGEt9+sbXNVxqsMRMuTOSMOhL YV9sgAnvXt5O+irKMW1YArZYZUq4v8gWNrTUe0n2KPhejdlOzdauoeeYy/3S94I= =/RPT -----END PGP SIGNATURE----- --3veqDlTM4ACrkuFbDHoFGsbkNADWpR6gP--