From nobody Thu May 2 07:59:41 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; envelope-from=libvir-list-bounces@redhat.com; helo=mx1.redhat.com; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 1531840568443650.343658381362; Tue, 17 Jul 2018 08:16:08 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id CBAD8307D84A; Tue, 17 Jul 2018 15:16:06 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 77FD55D9C9; Tue, 17 Jul 2018 15:16:06 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 919384A469; Tue, 17 Jul 2018 15:16:05 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.rdu2.redhat.com [10.11.54.3]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id w6HFG2XJ006082 for ; Tue, 17 Jul 2018 11:16:02 -0400 Received: by smtp.corp.redhat.com (Postfix) id 70C99111DD0A; Tue, 17 Jul 2018 15:16:02 +0000 (UTC) Received: from icr.brq.redhat.com (unknown [10.43.2.100]) by smtp.corp.redhat.com (Postfix) with ESMTP id 11859111DD13 for ; Tue, 17 Jul 2018 15:16:01 +0000 (UTC) From: =?UTF-8?q?J=C3=A1n=20Tomko?= To: libvir-list@redhat.com Date: Tue, 17 Jul 2018 17:15:53 +0200 Message-Id: <4b039cfe738416f013a6521e30b7db2ef852d5b5.1531840536.git.jtomko@redhat.com> In-Reply-To: References: In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.78 on 10.11.54.3 X-loop: libvir-list@redhat.com Subject: [libvirt] [PATCH 1/4] tests: qemu: Remove disk from graphics-vnc-tls X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.48]); Tue, 17 Jul 2018 15:16:07 +0000 (UTC) X-ZohoMail: RSF_0 Z_629925259 SPT_0 The disk command line is tested elsewhere. Signed-off-by: J=C3=A1n Tomko --- tests/qemuxml2argvdata/graphics-vnc-tls.args | 2 -- tests/qemuxml2argvdata/graphics-vnc-tls.xml | 6 ------ tests/qemuxml2xmloutdata/graphics-vnc-tls.xml | 6 ------ 3 files changed, 14 deletions(-) diff --git a/tests/qemuxml2argvdata/graphics-vnc-tls.args b/tests/qemuxml2a= rgvdata/graphics-vnc-tls.args index b87c2116a3..3668fa889d 100644 --- a/tests/qemuxml2argvdata/graphics-vnc-tls.args +++ b/tests/qemuxml2argvdata/graphics-vnc-tls.args @@ -22,7 +22,5 @@ server,nowait \ -no-acpi \ -boot c \ -usb \ --drive file=3D/dev/HostVG/QEMUGuest1,format=3Draw,if=3Dnone,id=3Ddrive-ide= 0-0-0 \ --device ide-drive,bus=3Dide.0,unit=3D0,drive=3Ddrive-ide0-0-0,id=3Dide0-0-= 0 \ -vnc 127.0.0.1:3,tls,x509verify=3D/etc/pki/libvirt-vnc,sasl \ -vga cirrus diff --git a/tests/qemuxml2argvdata/graphics-vnc-tls.xml b/tests/qemuxml2ar= gvdata/graphics-vnc-tls.xml index d0729e830d..079f6241c4 100644 --- a/tests/qemuxml2argvdata/graphics-vnc-tls.xml +++ b/tests/qemuxml2argvdata/graphics-vnc-tls.xml @@ -14,12 +14,6 @@ destroy /usr/bin/qemu-system-i686 - - - - -
- diff --git a/tests/qemuxml2xmloutdata/graphics-vnc-tls.xml b/tests/qemuxml2= xmloutdata/graphics-vnc-tls.xml index 7b53c2ae1f..dcbc4bcf1d 100644 --- a/tests/qemuxml2xmloutdata/graphics-vnc-tls.xml +++ b/tests/qemuxml2xmloutdata/graphics-vnc-tls.xml @@ -14,12 +14,6 @@ destroy /usr/bin/qemu-system-i686 - - - - -
-
--=20 2.16.1 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list From nobody Thu May 2 07:59:41 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; envelope-from=libvir-list-bounces@redhat.com; helo=mx1.redhat.com; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 1531840578018489.9585271387584; Tue, 17 Jul 2018 08:16:18 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 6A6573082141; Tue, 17 Jul 2018 15:16:16 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 130F91001F4E; Tue, 17 Jul 2018 15:16:16 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id ABCD84BB78; Tue, 17 Jul 2018 15:16:15 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.rdu2.redhat.com [10.11.54.3]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id w6HFG3Lm006091 for ; Tue, 17 Jul 2018 11:16:03 -0400 Received: by smtp.corp.redhat.com (Postfix) id 1AD82111DD0A; Tue, 17 Jul 2018 15:16:03 +0000 (UTC) Received: from icr.brq.redhat.com (unknown [10.43.2.100]) by smtp.corp.redhat.com (Postfix) with ESMTP id AE8C6111DD13 for ; Tue, 17 Jul 2018 15:16:02 +0000 (UTC) From: =?UTF-8?q?J=C3=A1n=20Tomko?= To: libvir-list@redhat.com Date: Tue, 17 Jul 2018 17:15:54 +0200 Message-Id: <7fdda372107a94ea8f38dacb81ac643b5bfb626d.1531840536.git.jtomko@redhat.com> In-Reply-To: References: In-Reply-To: References: X-Scanned-By: MIMEDefang 2.78 on 10.11.54.3 X-loop: libvir-list@redhat.com Subject: [libvirt] [PATCH 2/4] FIXDOWN: copy graphics-vnc-tls args to versioned paths X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.84 on 10.5.11.22 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.42]); Tue, 17 Jul 2018 15:16:17 +0000 (UTC) X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" For easier review of how these tests are different from the one with capabilities listed. This commit will be absorbed by the next one. --- .../graphics-vnc-tls.x86_64-2.4.0.args | 26 ++++++++++++++++++= ++++ .../graphics-vnc-tls.x86_64-latest.args | 26 ++++++++++++++++++= ++++ 2 files changed, 52 insertions(+) create mode 100644 tests/qemuxml2argvdata/graphics-vnc-tls.x86_64-2.4.0.ar= gs create mode 100644 tests/qemuxml2argvdata/graphics-vnc-tls.x86_64-latest.a= rgs diff --git a/tests/qemuxml2argvdata/graphics-vnc-tls.x86_64-2.4.0.args b/te= sts/qemuxml2argvdata/graphics-vnc-tls.x86_64-2.4.0.args new file mode 100644 index 0000000000..3668fa889d --- /dev/null +++ b/tests/qemuxml2argvdata/graphics-vnc-tls.x86_64-2.4.0.args @@ -0,0 +1,26 @@ +LC_ALL=3DC \ +PATH=3D/bin \ +HOME=3D/home/test \ +USER=3Dtest \ +LOGNAME=3Dtest \ +SASL_CONF_PATH=3D/root/.sasl2 \ +QEMU_AUDIO_DRV=3Dnone \ +/usr/bin/qemu-system-i686 \ +-name QEMUGuest1 \ +-S \ +-machine pc,accel=3Dtcg,usb=3Doff,dump-guest-core=3Doff \ +-m 214 \ +-smp 1,sockets=3D1,cores=3D1,threads=3D1 \ +-uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ +-no-user-config \ +-nodefaults \ +-chardev socket,id=3Dcharmonitor,path=3D/tmp/lib/domain--1-QEMUGuest1/moni= tor.sock,\ +server,nowait \ +-mon chardev=3Dcharmonitor,id=3Dmonitor,mode=3Dcontrol \ +-rtc base=3Dutc \ +-no-shutdown \ +-no-acpi \ +-boot c \ +-usb \ +-vnc 127.0.0.1:3,tls,x509verify=3D/etc/pki/libvirt-vnc,sasl \ +-vga cirrus diff --git a/tests/qemuxml2argvdata/graphics-vnc-tls.x86_64-latest.args b/t= ests/qemuxml2argvdata/graphics-vnc-tls.x86_64-latest.args new file mode 100644 index 0000000000..3668fa889d --- /dev/null +++ b/tests/qemuxml2argvdata/graphics-vnc-tls.x86_64-latest.args @@ -0,0 +1,26 @@ +LC_ALL=3DC \ +PATH=3D/bin \ +HOME=3D/home/test \ +USER=3Dtest \ +LOGNAME=3Dtest \ +SASL_CONF_PATH=3D/root/.sasl2 \ +QEMU_AUDIO_DRV=3Dnone \ +/usr/bin/qemu-system-i686 \ +-name QEMUGuest1 \ +-S \ +-machine pc,accel=3Dtcg,usb=3Doff,dump-guest-core=3Doff \ +-m 214 \ +-smp 1,sockets=3D1,cores=3D1,threads=3D1 \ +-uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ +-no-user-config \ +-nodefaults \ +-chardev socket,id=3Dcharmonitor,path=3D/tmp/lib/domain--1-QEMUGuest1/moni= tor.sock,\ +server,nowait \ +-mon chardev=3Dcharmonitor,id=3Dmonitor,mode=3Dcontrol \ +-rtc base=3Dutc \ +-no-shutdown \ +-no-acpi \ +-boot c \ +-usb \ +-vnc 127.0.0.1:3,tls,x509verify=3D/etc/pki/libvirt-vnc,sasl \ +-vga cirrus --=20 2.16.1 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list From nobody Thu May 2 07:59:41 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; envelope-from=libvir-list-bounces@redhat.com; helo=mx1.redhat.com; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 1531840583688392.7540568093759; Tue, 17 Jul 2018 08:16:23 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 3BFAA81DEC; Tue, 17 Jul 2018 15:16:22 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id ECEF26016F; Tue, 17 Jul 2018 15:16:21 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 96CE44A465; Tue, 17 Jul 2018 15:16:21 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.rdu2.redhat.com [10.11.54.3]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id w6HFG3Yw006098 for ; Tue, 17 Jul 2018 11:16:04 -0400 Received: by smtp.corp.redhat.com (Postfix) id B8409111DD0A; Tue, 17 Jul 2018 15:16:03 +0000 (UTC) Received: from icr.brq.redhat.com (unknown [10.43.2.100]) by smtp.corp.redhat.com (Postfix) with ESMTP id 58DA3111DD15 for ; Tue, 17 Jul 2018 15:16:03 +0000 (UTC) From: =?UTF-8?q?J=C3=A1n=20Tomko?= To: libvir-list@redhat.com Date: Tue, 17 Jul 2018 17:15:55 +0200 Message-Id: <9f9b5b4a36341a292f79134aab6becce0737ced3.1531840536.git.jtomko@redhat.com> In-Reply-To: References: In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.78 on 10.11.54.3 X-loop: libvir-list@redhat.com Subject: [libvirt] [PATCH 3/4] tests: qemu: test more versions for graphics-vnc-tls X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.25]); Tue, 17 Jul 2018 15:16:23 +0000 (UTC) X-ZohoMail: RSF_0 Z_629925259 SPT_0 Add a test with QEMU 2.4.0 capabilites, as well as the latest caps. The code paths for formatting TLS options will be altered and 2.4.0 is the newest version where QEMU_CAPS_OBJECT_TLS_CREDS_X509 is not supported. Signed-off-by: J=C3=A1n Tomko --- .../qemuxml2argvdata/graphics-vnc-tls.x86_64-2.4.0.args | 12 +++++++----- .../graphics-vnc-tls.x86_64-latest.args | 17 +++++++++++--= ---- tests/qemuxml2argvtest.c | 2 ++ 3 files changed, 20 insertions(+), 11 deletions(-) diff --git a/tests/qemuxml2argvdata/graphics-vnc-tls.x86_64-2.4.0.args b/te= sts/qemuxml2argvdata/graphics-vnc-tls.x86_64-2.4.0.args index 3668fa889d..7b8e3a4aa6 100644 --- a/tests/qemuxml2argvdata/graphics-vnc-tls.x86_64-2.4.0.args +++ b/tests/qemuxml2argvdata/graphics-vnc-tls.x86_64-2.4.0.args @@ -6,10 +6,11 @@ LOGNAME=3Dtest \ SASL_CONF_PATH=3D/root/.sasl2 \ QEMU_AUDIO_DRV=3Dnone \ /usr/bin/qemu-system-i686 \ --name QEMUGuest1 \ +-name guest=3DQEMUGuest1,debug-threads=3Don \ -S \ --machine pc,accel=3Dtcg,usb=3Doff,dump-guest-core=3Doff \ +-machine pc-i440fx-2.4,accel=3Dtcg,usb=3Doff,dump-guest-core=3Doff \ -m 214 \ +-realtime mlock=3Doff \ -smp 1,sockets=3D1,cores=3D1,threads=3D1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ -no-user-config \ @@ -20,7 +21,8 @@ server,nowait \ -rtc base=3Dutc \ -no-shutdown \ -no-acpi \ --boot c \ --usb \ +-boot strict=3Don \ +-device piix3-usb-uhci,id=3Dusb,bus=3Dpci.0,addr=3D0x1.0x2 \ -vnc 127.0.0.1:3,tls,x509verify=3D/etc/pki/libvirt-vnc,sasl \ --vga cirrus +-device cirrus-vga,id=3Dvideo0,bus=3Dpci.0,addr=3D0x2 \ +-msg timestamp=3Don diff --git a/tests/qemuxml2argvdata/graphics-vnc-tls.x86_64-latest.args b/t= ests/qemuxml2argvdata/graphics-vnc-tls.x86_64-latest.args index 3668fa889d..01743eff2a 100644 --- a/tests/qemuxml2argvdata/graphics-vnc-tls.x86_64-latest.args +++ b/tests/qemuxml2argvdata/graphics-vnc-tls.x86_64-latest.args @@ -6,21 +6,26 @@ LOGNAME=3Dtest \ SASL_CONF_PATH=3D/root/.sasl2 \ QEMU_AUDIO_DRV=3Dnone \ /usr/bin/qemu-system-i686 \ --name QEMUGuest1 \ +-name guest=3DQEMUGuest1,debug-threads=3Don \ -S \ +-object secret,id=3DmasterKey0,format=3Draw,\ +file=3D/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ -machine pc,accel=3Dtcg,usb=3Doff,dump-guest-core=3Doff \ -m 214 \ +-realtime mlock=3Doff \ -smp 1,sockets=3D1,cores=3D1,threads=3D1 \ -uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ -no-user-config \ -nodefaults \ --chardev socket,id=3Dcharmonitor,path=3D/tmp/lib/domain--1-QEMUGuest1/moni= tor.sock,\ -server,nowait \ +-chardev socket,id=3Dcharmonitor,fd=3D1729,server,nowait \ -mon chardev=3Dcharmonitor,id=3Dmonitor,mode=3Dcontrol \ -rtc base=3Dutc \ -no-shutdown \ -no-acpi \ --boot c \ --usb \ +-boot strict=3Don \ +-device piix3-usb-uhci,id=3Dusb,bus=3Dpci.0,addr=3D0x1.0x2 \ -vnc 127.0.0.1:3,tls,x509verify=3D/etc/pki/libvirt-vnc,sasl \ --vga cirrus +-device cirrus-vga,id=3Dvideo0,bus=3Dpci.0,addr=3D0x2 \ +-sandbox on,obsolete=3Ddeny,elevateprivileges=3Ddeny,spawn=3Ddeny,\ +resourcecontrol=3Ddeny \ +-msg timestamp=3Don diff --git a/tests/qemuxml2argvtest.c b/tests/qemuxml2argvtest.c index a929e4314e..ca7b315567 100644 --- a/tests/qemuxml2argvtest.c +++ b/tests/qemuxml2argvtest.c @@ -1194,6 +1194,8 @@ mymain(void) driver.config->vncTLS =3D 1; driver.config->vncTLSx509verify =3D 1; DO_TEST("graphics-vnc-tls", QEMU_CAPS_VNC, QEMU_CAPS_DEVICE_CIRRUS_VGA= ); + DO_TEST_CAPS_VER("graphics-vnc-tls", "2.4.0"); + DO_TEST_CAPS_LATEST("graphics-vnc-tls"); driver.config->vncSASL =3D driver.config->vncTLSx509verify =3D driver.= config->vncTLS =3D 0; VIR_FREE(driver.config->vncSASLdir); VIR_FREE(driver.config->vncTLSx509certdir); --=20 2.16.1 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list From nobody Thu May 2 07:59:41 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; envelope-from=libvir-list-bounces@redhat.com; helo=mx1.redhat.com; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 1531840570545875.6444414130732; Tue, 17 Jul 2018 08:16:10 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 19A7C85363; Tue, 17 Jul 2018 15:16:09 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id B3CAF5D6A5; Tue, 17 Jul 2018 15:16:08 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 3A2521841C4A; Tue, 17 Jul 2018 15:16:08 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.rdu2.redhat.com [10.11.54.3]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id w6HFG4Ti006103 for ; Tue, 17 Jul 2018 11:16:04 -0400 Received: by smtp.corp.redhat.com (Postfix) id 66EF6111DD0A; Tue, 17 Jul 2018 15:16:04 +0000 (UTC) Received: from icr.brq.redhat.com (unknown [10.43.2.100]) by smtp.corp.redhat.com (Postfix) with ESMTP id 016D9111DD15 for ; Tue, 17 Jul 2018 15:16:03 +0000 (UTC) From: =?UTF-8?q?J=C3=A1n=20Tomko?= To: libvir-list@redhat.com Date: Tue, 17 Jul 2018 17:15:56 +0200 Message-Id: <7b246d6ea2df82c0295db9b1b1db4383fc44d4b1.1531840536.git.jtomko@redhat.com> In-Reply-To: References: In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.78 on 10.11.54.3 X-loop: libvir-list@redhat.com Subject: [libvirt] [PATCH 4/4] qemu: vnc: switch to tls-creds-x509 X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.25]); Tue, 17 Jul 2018 15:16:09 +0000 (UTC) X-ZohoMail: RSF_0 Z_629925259 SPT_0 The tls, x509 and x509verify options were deprecated in QEMU v2.5.0: commit 3e305e4a4752f70c0b5c3cf5b43ec957881714f7 Author: Daniel P. Berrange ui: convert VNC server to use QCryptoTLSSession Use the tls-creds-x509 object when available. https://bugzilla.redhat.com/show_bug.cgi?id=3D1598167 Signed-off-by: J=C3=A1n Tomko --- src/qemu/qemu_command.c | 26 +++++++++++++++++-= ---- .../graphics-vnc-tls.x86_64-latest.args | 4 +++- 2 files changed, 23 insertions(+), 7 deletions(-) diff --git a/src/qemu/qemu_command.c b/src/qemu/qemu_command.c index 44ae8dcef7..9326abbe63 100644 --- a/src/qemu/qemu_command.c +++ b/src/qemu/qemu_command.c @@ -7917,13 +7917,27 @@ qemuBuildGraphicsVNCCommandLine(virQEMUDriverConfig= Ptr cfg, virBufferAddLit(&opt, ",password"); =20 if (cfg->vncTLS) { - virBufferAddLit(&opt, ",tls"); - if (cfg->vncTLSx509verify) { - virBufferAddLit(&opt, ",x509verify=3D"); - virQEMUBuildBufferEscapeComma(&opt, cfg->vncTLSx509certdir); + if (virQEMUCapsGet(qemuCaps, QEMU_CAPS_OBJECT_TLS_CREDS_X509)) { + const char *alias =3D "vnc-tls-creds0"; + if (qemuBuildTLSx509CommandLine(cmd, + cfg->vncTLSx509certdir, + true, + cfg->vncTLSx509verify, + NULL, + alias, + qemuCaps) < 0) + goto error; + + virBufferAsprintf(&opt, ",tls-creds=3D%s", alias); } else { - virBufferAddLit(&opt, ",x509=3D"); - virQEMUBuildBufferEscapeComma(&opt, cfg->vncTLSx509certdir); + virBufferAddLit(&opt, ",tls"); + if (cfg->vncTLSx509verify) { + virBufferAddLit(&opt, ",x509verify=3D"); + virQEMUBuildBufferEscapeComma(&opt, cfg->vncTLSx509certdir= ); + } else { + virBufferAddLit(&opt, ",x509=3D"); + virQEMUBuildBufferEscapeComma(&opt, cfg->vncTLSx509certdir= ); + } } } =20 diff --git a/tests/qemuxml2argvdata/graphics-vnc-tls.x86_64-latest.args b/t= ests/qemuxml2argvdata/graphics-vnc-tls.x86_64-latest.args index 01743eff2a..97775fad42 100644 --- a/tests/qemuxml2argvdata/graphics-vnc-tls.x86_64-latest.args +++ b/tests/qemuxml2argvdata/graphics-vnc-tls.x86_64-latest.args @@ -24,7 +24,9 @@ file=3D/tmp/lib/domain--1-QEMUGuest1/master-key.aes \ -no-acpi \ -boot strict=3Don \ -device piix3-usb-uhci,id=3Dusb,bus=3Dpci.0,addr=3D0x1.0x2 \ --vnc 127.0.0.1:3,tls,x509verify=3D/etc/pki/libvirt-vnc,sasl \ +-object tls-creds-x509,id=3Dvnc-tls-creds0,dir=3D/etc/pki/libvirt-vnc,\ +endpoint=3Dserver,verify-peer=3Dyes \ +-vnc 127.0.0.1:3,tls-creds=3Dvnc-tls-creds0,sasl \ -device cirrus-vga,id=3Dvideo0,bus=3Dpci.0,addr=3D0x2 \ -sandbox on,obsolete=3Ddeny,elevateprivileges=3Ddeny,spawn=3Ddeny,\ resourcecontrol=3Ddeny \ --=20 2.16.1 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list