]> git.proxmox.com Git - mirror_qemu.git/commitdiff
ui: deprecate "password" option for SPICE server
authorDaniel P. Berrangé <berrange@redhat.com>
Thu, 11 Mar 2021 11:43:43 +0000 (11:43 +0000)
committerGerd Hoffmann <kraxel@redhat.com>
Mon, 15 Mar 2021 16:37:44 +0000 (17:37 +0100)
With the new "password-secret" option, there is no reason to use the old
inecure "password" option with -spice, so it can be deprecated.

Signed-off-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20210311114343.439820-4-berrange@redhat.com>
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
docs/system/deprecated.rst
qemu-options.hx
ui/spice-core.c

index 5e3a31c1236148443fa2ea5eec92a9f308ca3416..8cba672a7b4ae9c7b62bdc8f49bf8a25673db01a 100644 (file)
@@ -174,6 +174,14 @@ Input parameters that take a size value should only use a size suffix
 the value is hexadecimal.  That is, '0x20M' is deprecated, and should
 be written either as '32M' or as '0x2000000'.
 
+``-spice password=string`` (since 6.0)
+''''''''''''''''''''''''''''''''''''''
+
+This option is insecure because the SPICE password remains visible in
+the process listing. This is replaced by the new ``password-secret``
+option which lets the password be securely provided on the command
+line using a ``secret`` object instance.
+
 QEMU Machine Protocol (QMP) commands
 ------------------------------------
 
index a98f8e84a29d661f1f5a9661fb3213c994cd006b..4da3f4f48c033ce1c677c9a5c07bd7213d168c9a 100644 (file)
@@ -1928,6 +1928,10 @@ SRST
     ``password=<string>``
         Set the password you need to authenticate.
 
+        This option is deprecated and insecure because it leaves the
+        password visible in the process listing. Use ``password-secret``
+        instead.
+
     ``password-secret=<secret-id>``
         Set the ID of the ``secret`` object containing the password
         you need to authenticate.
index b9d8aced91dfd45c209ba8bee6364e1fc6b66dda..272d19b0c152e52f3e24316f92ab8e6d12b26ff6 100644 (file)
@@ -686,6 +686,8 @@ static void qemu_spice_init(void)
     } else {
         str = qemu_opt_get(opts, "password");
         if (str) {
+            warn_report("'password' option is deprecated and insecure, "
+                        "use 'password-secret' instead");
             password = g_strdup(str);
         }
     }