Add another disk to luks-disks-source-qcow2 case to cover a backing
chain with encrypted members.
Signed-off-by: Peter Krempa <pkrempa(a)redhat.com>
---
.../luks-disks-source-qcow2.args | 8 ++++++++
.../luks-disks-source-qcow2.xml | 18 ++++++++++++++++++
2 files changed, 26 insertions(+)
diff --git a/tests/qemuxml2argvdata/luks-disks-source-qcow2.args
b/tests/qemuxml2argvdata/luks-disks-source-qcow2.args
index 2ccdb7e49f..ab1c864cf6 100644
--- a/tests/qemuxml2argvdata/luks-disks-source-qcow2.args
+++ b/tests/qemuxml2argvdata/luks-disks-source-qcow2.args
@@ -69,4 +69,12 @@ encrypt.key-secret=virtio-disk4-luks-secret0,format=qcow2,if=none,\
id=drive-virtio-disk4' \
-device virtio-blk-pci,bus=pci.0,addr=0x8,drive=drive-virtio-disk4,\
id=virtio-disk4 \
+-object secret,id=virtio-disk5-luks-secret0,\
+data=9eao5F8qtkGt+seB1HYivWIxbtwUu6MQtg1zpj/oDtUsPr1q8wBYM91uEHCn6j/1,\
+keyid=masterKey0,iv=AAECAwQFBgcICQoLDA0ODw==,format=base64 \
+-drive file=/storage/guest_disks/encryptdisk5,encrypt.format=luks,\
+encrypt.key-secret=virtio-disk5-luks-secret0,format=qcow2,if=none,\
+id=drive-virtio-disk5 \
+-device virtio-blk-pci,bus=pci.0,addr=0x9,drive=drive-virtio-disk5,\
+id=virtio-disk5 \
-device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3
diff --git a/tests/qemuxml2argvdata/luks-disks-source-qcow2.xml
b/tests/qemuxml2argvdata/luks-disks-source-qcow2.xml
index 92b31fb8bd..4dacc79ff4 100644
--- a/tests/qemuxml2argvdata/luks-disks-source-qcow2.xml
+++ b/tests/qemuxml2argvdata/luks-disks-source-qcow2.xml
@@ -68,6 +68,24 @@
</source>
<target dev='vde' bus='virtio'/>
</disk>
+ <disk type='file' device='disk'>
+ <driver name='qemu' type='qcow2'/>
+ <source file='/storage/guest_disks/encryptdisk5'>
+ <encryption format='luks'>
+ <secret type='passphrase'
uuid='0a81f5b2-8403-7b23-c8d6-21ccc2f80d6f'/>
+ </encryption>
+ </source>
+ <backingStore type='file'>
+ <format type='qcow2'/>
+ <source file='/storage/guest_disks/base.qcow2'>
+ <encryption format='luks'>
+ <secret type='passphrase'
uuid='0a81f5b2-8403-7b23-c8d6-21ccc2f80d6f'/>
+ </encryption>
+ </source>
+ <backingStore/>
+ </backingStore>
+ <target dev='vdf' bus='virtio'/>
+ </disk>
<controller type='usb' index='0'>
<address type='pci' domain='0x0000' bus='0x00'
slot='0x01' function='0x2'/>
</controller>
--
2.24.1