e4fc8781db
QED's metadata caching strategy allows two parallel requests to race for metadata lookup. The first one to complete will populate the metadata cache and the second one will drop the data it just read in favor of the cached data. There is a use-after-free in qed_read_l2_table_cb() and qed_commit_l2_update() where l2_table->offset was used after the l2_table may have been freed due to a metadata lookup race. Fix this by keeping the l2_offset in a local variable and not reaching into the possibly freed l2_table. Reported-by: Amit Shah <amit.shah@redhat.com> Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com> |
||
---|---|---|
.. | ||
blkdebug.c | ||
blkverify.c | ||
bochs.c | ||
cloop.c | ||
cow.c | ||
curl.c | ||
dmg.c | ||
nbd.c | ||
parallels.c | ||
qcow2-cache.c | ||
qcow2-cluster.c | ||
qcow2-refcount.c | ||
qcow2-snapshot.c | ||
qcow2.c | ||
qcow2.h | ||
qcow.c | ||
qed-check.c | ||
qed-cluster.c | ||
qed-gencb.c | ||
qed-l2-cache.c | ||
qed-table.c | ||
qed.c | ||
qed.h | ||
raw-posix-aio.h | ||
raw-posix.c | ||
raw-win32.c | ||
raw.c | ||
rbd.c | ||
sheepdog.c | ||
vdi.c | ||
vmdk.c | ||
vpc.c | ||
vvfat.c |