mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-11-02 19:31:18 +00:00
bc680e1381
Fix the null pointer access when UUID is not specified. Introduce a bool 'uuidUsable' to virStoragePoolAuthCephx that indicates if uuid was specified or not and use it instead of the pointless comparison of the static UUID array to NULL. Add an error message if both uuid and usage are specified. Fixes: Error: FORWARD_NULL (CWE-476): libvirt-0.10.2/src/conf/storage_conf.c:461: var_deref_model: Passing null pointer "uuid" to function "virUUIDParse(char const *, unsigned char *)", which dereferences it. (The dereference is assumed on the basis of the 'nonnull' parameter attribute.) Error: NO_EFFECT (CWE-398): libvirt-0.10.2/src/conf/storage_conf.c:979: array_null: Comparing an array to null is not useful: "src->auth.cephx.secret.uuid != NULL". |
||
---|---|---|
.. | ||
parthelper.c | ||
storage_backend_disk.c | ||
storage_backend_disk.h | ||
storage_backend_fs.c | ||
storage_backend_fs.h | ||
storage_backend_iscsi.c | ||
storage_backend_iscsi.h | ||
storage_backend_logical.c | ||
storage_backend_logical.h | ||
storage_backend_mpath.c | ||
storage_backend_mpath.h | ||
storage_backend_rbd.c | ||
storage_backend_rbd.h | ||
storage_backend_scsi.c | ||
storage_backend_scsi.h | ||
storage_backend_sheepdog.c | ||
storage_backend_sheepdog.h | ||
storage_backend.c | ||
storage_backend.h | ||
storage_driver.c | ||
storage_driver.h |