qemu-block
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v3] qcow2: Forbid discard in qcow2 v2 images with backing fil


From: Alberto Garcia
Subject: Re: [PATCH v3] qcow2: Forbid discard in qcow2 v2 images with backing files
Date: Fri, 27 Mar 2020 20:13:28 +0100
User-agent: Notmuch/0.18.2 (http://notmuchmail.org) Emacs/24.4.1 (i586-pc-linux-gnu)

On Fri 27 Mar 2020 07:57:40 PM CET, Eric Blake wrote:
>> +    /* If the image does not support QCOW_OFLAG_ZERO then discarding
>> +     * clusters could expose stale data from the backing file. */
>> +    if (s->qcow_version < 3 && bs->backing) {
>> +        return -ENOTSUP;
>> +    }
>
> Hmm. Should we blindly always fail for v2, or can we be a little bit
> smarter and still discard a cluster in the top layer if the backing
> layer does not also have it allocated?

Not sure if that's worth it. I only wanted to fix what looks like a
potential security bug so I prefer to keep it simple. qcow2 v3 has been
out for many years already.

Berto



reply via email to

[Prev in Thread] Current Thread [Next in Thread]