• P
    conf: Don't crash on invalid chardev source definition of RNGs and other · 79552754
    Peter Krempa 提交于
    Since commit 297c99a5 an invalid source definition XML of a character
    device that is used as backend for RNG devices, smartcards and redirdevs
    causes crash of the daemon when parsing such a definition.
    
    The device types mentioned above are not a part of a regular character
    device but are backends for other types. Thus when parsing such device
    NULL is passed as the argument @chr_def. Later when checking the
    validity of the definition @chr_def was dereferenced when parsing a UNIX
    socket backend with missing path of the socket and crashed the daemon.
    
    Sample offending configuration:
      <devices>
      ...
        <rng model='virtio'>
          <backend model='egd' type='unix'>
            <source mode='bind' service='1024'/>
          </backend>
        </rng>
      </devices>
    
    Resolves: https://bugzilla.redhat.com/show_bug.cgi?id=1012196
    79552754
qemuxml2argv-virtio-rng-egd-crash.xml 879 字节