]> git.proxmox.com Git - pve-qemu.git/blob - debian/patches/pve/0015-PVE-qapi-modify-spice-query.patch
drop patch force-disabling smm
[pve-qemu.git] / debian / patches / pve / 0015-PVE-qapi-modify-spice-query.patch
1 From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
2 From: Wolfgang Bumiller <w.bumiller@proxmox.com>
3 Date: Mon, 6 Apr 2020 12:16:45 +0200
4 Subject: [PATCH] PVE: qapi: modify spice query
5
6 Provide the last ticket in the SpiceInfo struct optionally.
7
8 Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
9 ---
10 qapi/ui.json | 3 +++
11 ui/spice-core.c | 5 +++++
12 2 files changed, 8 insertions(+)
13
14 diff --git a/qapi/ui.json b/qapi/ui.json
15 index 1052ca9c38..16bf03224f 100644
16 --- a/qapi/ui.json
17 +++ b/qapi/ui.json
18 @@ -216,11 +216,14 @@
19 #
20 # @channels: a list of @SpiceChannel for each active spice channel
21 #
22 +# @ticket: The last ticket set with set_password
23 +#
24 # Since: 0.14
25 ##
26 { 'struct': 'SpiceInfo',
27 'data': {'enabled': 'bool', 'migrated': 'bool', '*host': 'str', '*port': 'int',
28 '*tls-port': 'int', '*auth': 'str', '*compiled-version': 'str',
29 + '*ticket': 'str',
30 'mouse-mode': 'SpiceQueryMouseMode', '*channels': ['SpiceChannel']},
31 'if': 'defined(CONFIG_SPICE)' }
32
33 diff --git a/ui/spice-core.c b/ui/spice-core.c
34 index 9719214f19..982b1dc05f 100644
35 --- a/ui/spice-core.c
36 +++ b/ui/spice-core.c
37 @@ -534,6 +534,11 @@ static SpiceInfo *qmp_query_spice_real(Error **errp)
38 micro = SPICE_SERVER_VERSION & 0xff;
39 info->compiled_version = g_strdup_printf("%d.%d.%d", major, minor, micro);
40
41 + if (auth_passwd) {
42 + info->has_ticket = true;
43 + info->ticket = g_strdup(auth_passwd);
44 + }
45 +
46 if (port) {
47 info->has_port = true;
48 info->port = port;