On Tue, Mar 06, 2018 at 08:49:35 -0500, John Ferlan wrote: > > > On 03/02/2018 11:56 AM, Peter Krempa wrote: > > Nobody should use format detection due to security implications. > > While I cannot disagree technically - would it be "useful" from a code > coverage viewpoint to have just "one" do the allowDiskFormatProbing > assignment similar to how various *TLS assignments are done in the > qemuxml2argvtest.c? With the appropriate comment regarding the security
Well I'd not have any problems with that if we'd do this in the xml2argv test where we do have more interresting code paths to validate. In the XML2XML test alone I don't think it really makes much sense at all. At any rate I'll do it separately together with adding a xml2argv test since without it it does not make much sense. > implications of format testing. Doesn't matter which one - just choose > one and don't have the output file altered. Of course that'll be the > *one* test that everyone copies to create their xml2xml tests ;-) > > Might be useful to note in the commit message that disabling resulted in > (I assume) default output of "<driver name='qemu' type='raw'/>" being > added to outputs for disks and "<format type='raw'/>" for mirrors... All > the input files that changed are just targets of links for output files. > > > > > Signed-off-by: Peter Krempa <pkre...@redhat.com> > > --- [...] > > diff --git a/tests/qemuxml2xmloutdata/disk-mirror-old.xml > > b/tests/qemuxml2xmloutdata/disk-mirror-old.xml > > index e390bc02f2..f8a885aec8 100644 > > --- a/tests/qemuxml2xmloutdata/disk-mirror-old.xml > > +++ b/tests/qemuxml2xmloutdata/disk-mirror-old.xml > > @@ -15,15 +15,18 @@ > > <devices> > > <emulator>/usr/bin/qemu-system-i686</emulator> > > <disk type='block' device='disk'> > > + <driver name='qemu' type='raw'/> > > <source dev='/dev/HostVG/QEMUGuest1'/> > > <backingStore/> > > - <mirror type='file' file='/dev/HostVG/QEMUGuest1Copy' job='copy' > > ready='yes'> > > + <mirror type='file' file='/dev/HostVG/QEMUGuest1Copy' format='raw' > > job='copy' ready='yes'> > > + <format type='raw'/> > > Interesting that "format type='raw'" essentially appears twice... > > Does this point out a bug in virDomainDiskDefFormat when printing > <mirror...> as formatStr is printed twice. IIRC the attribute is the old way nad the element is the new way. Even the filename is duplicated.
Description: PGP signature
-- libvir-list mailing list firstname.lastname@example.org https://www.redhat.com/mailman/listinfo/libvir-list