libvirt/tests/qemuxmlconfdata/serial-tcp-chardev-telnets.xml
Peter Krempa 24d468993c qemu: Reject unsupported chardev backend protocols
QEMU supports only 'raw' and 'telnet' in the

 <protocol type='telnets'/>

element. Reject 'telnets' and 'tls'. TLS transport for qemu chardevs is
configured via "tls='yes'" attribute added to the "<source>" element
instead, so this prevents potential misconfig as the value would be
silently accepted.

Closes: https://gitlab.com/libvirt/libvirt/-/issues/412
Signed-off-by: Peter Krempa <pkrempa@redhat.com>
Reviewed-by: Ján Tomko <jtomko@redhat.com>
2024-09-19 10:30:15 +02:00

24 lines
672 B
XML

<domain type='qemu'>
<name>QEMUGuest1</name>
<uuid>c7a5fdbd-edaf-9455-926a-d65c16db1809</uuid>
<memory unit='KiB'>219136</memory>
<vcpu placement='static'>1</vcpu>
<os>
<type arch='x86_64' machine='pc'>hvm</type>
</os>
<devices>
<emulator>/usr/bin/qemu-system-x86_64</emulator>
<serial type='tcp'>
<source mode='connect' host='127.0.0.1' service='9999'/>
<protocol type='tls'/>
<target port='0'/>
</serial>
<console type='tcp'>
<source mode='connect' host='127.0.0.1' service='9999'/>
<protocol type='telnets'/>
<target port='0'/>
</console>
<memballoon model='virtio'/>
</devices>
</domain>