mirror of
https://github.com/libvirt/libvirt.git
synced 2026-08-09 04:28:32 -05:00
conf: domain: reject name containing '/'
Trying to define a domain name containing an embedded '/' will immediately fail when trying to write the XML to disk for our stateful drivers. This patch explicitly rejects names containing a '/', and provides an xmlopt feature for drivers to avoid this validation check, which is enabled in every non-stateful driver that already has xmlopt handling wired up. (Technically this could reject a previously accepted vmname like '/foo', however at least for the qemu driver that falls over later when starting qemu) https://bugzilla.redhat.com/show_bug.cgi?id=639923
This commit is contained in:
@@ -273,6 +273,7 @@ static virDomainDefParserConfig vboxDomainDefParserConfig = {
|
||||
.macPrefix = { 0x08, 0x00, 0x27 },
|
||||
.devicesPostParseCallback = vboxDomainDeviceDefPostParse,
|
||||
.domainPostParseCallback = vboxDomainDefPostParse,
|
||||
.features = VIR_DOMAIN_DEF_FEATURE_NAME_SLASH,
|
||||
};
|
||||
|
||||
static virDomainXMLOptionPtr
|
||||
|
||||
Reference in New Issue
Block a user