[libvirt] [PATCH] allow '#' as valid character for domain name

Laine Stump laine at laine.org
Fri Nov 19 18:00:39 UTC 2010


On 11/19/2010 05:29 AM, Osier Yang wrote:
> * docs/schemas/domain.rng
> ---
>   docs/schemas/domain.rng |    2 +-
>   1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/docs/schemas/domain.rng b/docs/schemas/domain.rng
> index bbbc846..815134d 100644
> --- a/docs/schemas/domain.rng
> +++ b/docs/schemas/domain.rng
> @@ -2003,7 +2003,7 @@
>     </define>
>     <define name="domainName">
>       <data type="string">
> -<param name="pattern">[A-Za-z0-9_\.\+\-&:/]+</param>
> +<param name="pattern">[A-Za-z0-9_\.\+\-\\#&:/]+</param>
>       </data>
>     </define>
>     <define name="diskSerial">

What's your motivation for this?

If domain.rng is used similarly to the other .rng files I'm more 
familiar with, it's only actually examined during the tests run as part 
of "make check", so it won't have any effect on actual operation. Is 
this what you intended?

"#" seems like a problematic character to put in a domain name - for 
example it would need to be escaped or quoted if it was ever on a 
commandline - what happens when that name gets passed to qemu, for 
example? Or a user-written shell script that calls virsh? Also, 
virt-manager doesn't allow it.




More information about the libvir-list mailing list