From nobody Sun Feb 8 18:43:44 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 205.139.110.120 as permitted sender) client-ip=205.139.110.120; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-1.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.120 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1583771037; cv=none; d=zohomail.com; s=zohoarc; b=gJwwO0fmSGlfhn3iEMkzt674NQpPzY3/w2UNZEG/O4e0yE9re4lZf5bt1rSEFOEz/h05SlZttweBzCrM/2ed9WBODfKIQfW+6c5i+p2j7zJlqOSASKZ0xWrUsaZbMYCYlPwBe+xSJE15k1yqxQXfDh56fwzO8v2J8RdyM+iX2WY= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1583771037; h=Content-Type:Content-Transfer-Encoding:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=/9GEja28wgEJQmWM8nkrNonOYP+c54oKl+cIPByogN4=; b=hc/zpThiQhUeaqk8+q5imDAQS8gzSaFKuf3i10A+GtlOm0sgAavLQLEzEVPzxc0RnZlQ8S0O+g3fUBwyhUzC6lgMGWvXIAkfLPeSYE5AFTUqAapdr4N/jtLbrI9F3ronXRftL+r7SUpqmzvOgxhdVJt7c+fQzb05R4jyr8lN580= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 205.139.110.120 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from us-smtp-1.mimecast.com (us-smtp-delivery-1.mimecast.com [205.139.110.120]) by mx.zohomail.com with SMTPS id 158377103792726.649048284120454; Mon, 9 Mar 2020 09:23:57 -0700 (PDT) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-336-pKfggcnUNv2i7tSJzxjhTg-1; Mon, 09 Mar 2020 12:23:54 -0400 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 mimecast-mx01.redhat.com (Postfix) with ESMTPS id 72B8E8018A2; Mon, 9 Mar 2020 16:23:48 +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 497438D569; Mon, 9 Mar 2020 16:23:48 +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 F018F86A04; Mon, 9 Mar 2020 16:23:47 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 029GNSSc020832 for ; Mon, 9 Mar 2020 12:23:28 -0400 Received: by smtp.corp.redhat.com (Postfix) id D018B9051C; Mon, 9 Mar 2020 16:23:28 +0000 (UTC) Received: from angien.redhat.com (unknown [10.43.2.48]) by smtp.corp.redhat.com (Postfix) with ESMTP id 5648B90A03 for ; Mon, 9 Mar 2020 16:23:28 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1583771036; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=/9GEja28wgEJQmWM8nkrNonOYP+c54oKl+cIPByogN4=; b=DVOfUA31zFlSBFAqDkTzB1AztMkPu+zx6kZ66QZBjy2ya1Bq7VY2wm+dg+AZ3kjMxlG/jk wqGtWhuwMnekQZZ2nlrfvItWDx9duGkpBtXBNkgV/LY4ScZnR5Wbb08WJwp1ntky+AZEbB gmkJ2T+SMtF0vjCCv8LrfKv7P1u5cRg= X-MC-Unique: pKfggcnUNv2i7tSJzxjhTg-1 From: Peter Krempa To: libvir-list@redhat.com Subject: [PATCH 17/30] qemuxml2argvtest: Add test case for disks with http(s) source Date: Mon, 9 Mar 2020 17:22:57 +0100 Message-Id: In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13 X-loop: libvir-list@redhat.com 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: , 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-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) Content-Type: text/plain; charset="utf-8" Upcoming patches will implement the support for sslverify, cookies, readahead, and timeout properties. Add a test file which will collect the cases. Signed-off-by: Peter Krempa Reviewed-by: J=C3=A1n Tomko --- .../disk-network-http.x86_64-latest.args | 57 +++++++++++++++++++ tests/qemuxml2argvdata/disk-network-http.xml | 50 ++++++++++++++++ tests/qemuxml2argvtest.c | 1 + 3 files changed, 108 insertions(+) create mode 100644 tests/qemuxml2argvdata/disk-network-http.x86_64-latest.= args create mode 100644 tests/qemuxml2argvdata/disk-network-http.xml diff --git a/tests/qemuxml2argvdata/disk-network-http.x86_64-latest.args b/= tests/qemuxml2argvdata/disk-network-http.x86_64-latest.args new file mode 100644 index 0000000000..61daecf6f1 --- /dev/null +++ b/tests/qemuxml2argvdata/disk-network-http.x86_64-latest.args @@ -0,0 +1,57 @@ +LC_ALL=3DC \ +PATH=3D/bin \ +HOME=3D/tmp/lib/domain--1-QEMUGuest1 \ +USER=3Dtest \ +LOGNAME=3Dtest \ +XDG_DATA_HOME=3D/tmp/lib/domain--1-QEMUGuest1/.local/share \ +XDG_CACHE_HOME=3D/tmp/lib/domain--1-QEMUGuest1/.cache \ +XDG_CONFIG_HOME=3D/tmp/lib/domain--1-QEMUGuest1/.config \ +QEMU_AUDIO_DRV=3Dnone \ +/usr/bin/qemu-system-x86_64 \ +-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=3Dkvm,usb=3Doff,dump-guest-core=3Doff \ +-cpu qemu64 \ +-m 214 \ +-overcommit mem-lock=3Doff \ +-smp 1,sockets=3D1,cores=3D1,threads=3D1 \ +-uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ +-display none \ +-no-user-config \ +-nodefaults \ +-chardev socket,id=3Dcharmonitor,fd=3D1729,server,nowait \ +-mon chardev=3Dcharmonitor,id=3Dmonitor,mode=3Dcontrol \ +-rtc base=3Dutc \ +-no-shutdown \ +-no-acpi \ +-boot strict=3Don \ +-device piix3-usb-uhci,id=3Dusb,bus=3Dpci.0,addr=3D0x1.0x2 \ +-blockdev '{"driver":"http","url":"http://example.org:80/test.img",\ +"node-name":"libvirt-4-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-4-format","read-only":false,"driver":"raw= ",\ +"file":"libvirt-4-storage"}' \ +-device virtio-blk-pci,scsi=3Doff,bus=3Dpci.0,addr=3D0x2,drive=3Dlibvirt-4= -format,\ +id=3Dvirtio-disk0,bootindex=3D1 \ +-blockdev '{"driver":"https","url":"https://example.org:443/test2.img",\ +"node-name":"libvirt-3-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-3-format","read-only":false,"driver":"raw= ",\ +"file":"libvirt-3-storage"}' \ +-device virtio-blk-pci,scsi=3Doff,bus=3Dpci.0,addr=3D0x3,drive=3Dlibvirt-3= -format,\ +id=3Dvirtio-disk1 \ +-blockdev '{"driver":"http","url":"http://example.org:1234/test3.img",\ +"node-name":"libvirt-2-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-2-format","read-only":false,"driver":"raw= ",\ +"file":"libvirt-2-storage"}' \ +-device virtio-blk-pci,scsi=3Doff,bus=3Dpci.0,addr=3D0x4,drive=3Dlibvirt-2= -format,\ +id=3Dvirtio-disk2 \ +-blockdev '{"driver":"https","url":"https://example.org:1234/test4.img",\ +"node-name":"libvirt-1-storage","auto-read-only":true,"discard":"unmap"}' \ +-blockdev '{"node-name":"libvirt-1-format","read-only":false,"driver":"raw= ",\ +"file":"libvirt-1-storage"}' \ +-device virtio-blk-pci,scsi=3Doff,bus=3Dpci.0,addr=3D0x5,drive=3Dlibvirt-1= -format,\ +id=3Dvirtio-disk3 \ +-sandbox on,obsolete=3Ddeny,elevateprivileges=3Ddeny,spawn=3Ddeny,\ +resourcecontrol=3Ddeny \ +-msg timestamp=3Don diff --git a/tests/qemuxml2argvdata/disk-network-http.xml b/tests/qemuxml2a= rgvdata/disk-network-http.xml new file mode 100644 index 0000000000..83a9865c83 --- /dev/null +++ b/tests/qemuxml2argvdata/disk-network-http.xml @@ -0,0 +1,50 @@ + + QEMUGuest1 + c7a5fdbd-edaf-9455-926a-d65c16db1809 + 219136 + 219136 + 1 + + hvm + + + + destroy + restart + destroy + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/tests/qemuxml2argvtest.c b/tests/qemuxml2argvtest.c index 35d413d40b..e81d1d7fa1 100644 --- a/tests/qemuxml2argvtest.c +++ b/tests/qemuxml2argvtest.c @@ -1092,6 +1092,7 @@ mymain(void) QEMU_CAPS_OBJECT_TLS_CREDS_X509, QEMU_CAPS_NBD_TLS); DO_TEST_CAPS_VER("disk-network-tlsx509", "2.12.0"); DO_TEST_CAPS_LATEST("disk-network-tlsx509"); + DO_TEST_CAPS_LATEST("disk-network-http"); driver.config->vxhsTLS =3D 0; VIR_FREE(driver.config->vxhsTLSx509certdir); DO_TEST("disk-no-boot", NONE); --=20 2.24.1