[PATCH 00/11] qemu: Fix crash when attempting to use authentication for HTTP backed disks

Peter Krempa pkrempa at redhat.com
Fri Apr 22 15:31:44 UTC 2022


The crash is fixed by properly instantiating the auth object.

Also this series cleans up some problems noticed along the way.

Peter Krempa (11):
  conf: schema: Fix alignment in 'diskSourceNetworkProtocolHTTPS' schema
    definition
  qemuDomainValidateStorageSource: Reorganize encryption config
    validation
  qemuDomainValidateStorageSource: Add validation of 'encryption'
    support
  qemuBlockStorageSourceGetRBDProps: Simplify handling of encryption
    format
  virDomainDiskDefValidateSourceChainOne: Reject authentication for
    protocols which don't support it
  qemuDomainStorageSourceHasAuth: Don't decide based on protocol
  qemu: domain: Inline qemuDomainDiskHasEncryptionSecret
  qemu: domain: Inline qemuDomainStorageSourceHasAuth
  conf: schemas: Split out definition for 'ftp' protocol
  conf: schema: Allow authentication for FTP(S) and HTTP(S) disks
  tests: qemuxml2*: Add testing of authenticated http/ftp disks

 src/conf/domain_validate.c                    |  34 ++++++
 src/conf/schemas/domaincommon.rng             |  35 +++++-
 src/qemu/qemu_block.c                         |  10 +-
 src/qemu/qemu_domain.c                        | 103 ++++++------------
 src/qemu/qemu_domain.h                        |   3 -
 .../disk-cdrom-network.x86_64-4.1.0.args      |   6 +-
 .../disk-cdrom-network.x86_64-latest.args     |   6 +-
 tests/qemuxml2argvdata/disk-cdrom-network.xml |   6 +
 .../disk-encryption-wrong.x86_64-latest.err   |   1 +
 .../disk-encryption-wrong.xml                 |  37 +++++++
 ...-network-rbd-encryption.x86_64-latest.args |   2 +-
 .../disk-network-rbd-encryption.xml           |   2 +-
 tests/qemuxml2argvtest.c                      |   1 +
 .../disk-cdrom-network.x86_64-latest.xml      |  72 ++++++++++++
 ...k-network-rbd-encryption.x86_64-latest.xml |   2 +-
 tests/qemuxml2xmltest.c                       |   1 +
 16 files changed, 233 insertions(+), 88 deletions(-)
 create mode 100644 tests/qemuxml2argvdata/disk-encryption-wrong.x86_64-latest.err
 create mode 100644 tests/qemuxml2argvdata/disk-encryption-wrong.xml
 create mode 100644 tests/qemuxml2xmloutdata/disk-cdrom-network.x86_64-latest.xml

-- 
2.35.1



More information about the libvir-list mailing list