qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Fabian Ebner <f.ebner@proxmox.com>
To: Markus Armbruster <armbru@redhat.com>
Cc: w.bumiller@proxmox.com, berrange@redhat.com,
	qemu-devel@nongnu.org, dgilbert@redhat.com,
	marcandre.lureau@gmail.com, kraxel@redhat.com,
	pbonzini@redhat.com, marcandre.lureau@redhat.com,
	eblake@redhat.com, t.lamprecht@proxmox.com
Subject: Re: [PATCH v9 3/3] qapi/monitor: allow VNC display id in set/expire_password
Date: Fri, 25 Feb 2022 13:23:00 +0100	[thread overview]
Message-ID: <39e1b9b4-d82b-4efc-2a5d-9ce904ecbffe@proxmox.com> (raw)
In-Reply-To: <874k4nkwmb.fsf@pond.sub.org>

Am 25.02.22 um 12:34 schrieb Markus Armbruster:
> Fabian Ebner <f.ebner@proxmox.com> writes:
> 
>> From: Stefan Reiter <s.reiter@proxmox.com>
>>
>> It is possible to specify more than one VNC server on the command line,
>> either with an explicit ID or the auto-generated ones à la "default",
>> "vnc2", "vnc3", ...
>>
>> It is not possible to change the password on one of these extra VNC
>> displays though. Fix this by adding a "display" parameter to the
>> "set_password" and "expire_password" QMP and HMP commands.
>>
>> For HMP, the display is specified using the "-d" value flag.
>>
>> For QMP, the schema is updated to explicitly express the supported
>> variants of the commands with protocol-discriminated unions.
>>
>> Signed-off-by: Stefan Reiter <s.reiter@proxmox.com>
>> [FE: update "Since: " from 6.2 to 7.0
>>      make @connected a common member of @SetPasswordOptions]
>> Signed-off-by: Fabian Ebner <f.ebner@proxmox.com>
> 
> [...]
> 
>> diff --git a/qapi/ui.json b/qapi/ui.json
>> index e112409211..4a13f883a3 100644
>> --- a/qapi/ui.json
>> +++ b/qapi/ui.json
>> @@ -38,20 +38,47 @@
>>    'data': [ 'keep', 'fail', 'disconnect' ] }
>>  
>>  ##
>> -# @set_password:
>> +# @SetPasswordOptions:
>>  #
>> -# Sets the password of a remote display session.
>> +# Options for set_password.
>>  #
>>  # @protocol: - 'vnc' to modify the VNC server password
>>  #            - 'spice' to modify the Spice server password
>>  #
>>  # @password: the new password
>>  #
>> -# @connected: how to handle existing clients when changing the
>> -#             password.  If nothing is specified, defaults to 'keep'
>> -#             'fail' to fail the command if clients are connected
>> -#             'disconnect' to disconnect existing clients
>> -#             'keep' to maintain existing clients
>> +# @connected: How to handle existing clients when changing the
>> +#             password. If nothing is specified, defaults to 'keep'.
>> +#             For VNC, only 'keep' is currently implemented.
>> +#
>> +# Since: 7.0
>> +#
>> +##
>> +{ 'union': 'SetPasswordOptions',
>> +  'base': { 'protocol': 'DisplayProtocol',
>> +            'password': 'str',
>> +            '*connected': 'SetPasswordAction' },
>> +  'discriminator': 'protocol',
>> +  'data': { 'vnc': 'SetPasswordOptionsVnc' } }
>> +
>> +##
>> +# @SetPasswordOptionsVnc:
>> +#
>> +# Options for set_password specific to the VNC procotol.
>> +#
>> +# @display: The id of the display where the password should be changed.
>> +#           Defaults to the first.
> 
> Is this default equivalent to any value?  "The first" suggests it's not.
> 

The value will be NULL and QTAILQ_FIRST(&vnc_displays) is picked, which
means the display defaults to the first display. But yeah, the value
doesn't actually default to the id of the first display, it just behaves
as if it did.



  reply	other threads:[~2022-02-25 12:28 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-02-25  8:49 [PATCH v9 0/3] VNC-related HMP/QMP fixes Fabian Ebner
2022-02-25  8:49 ` [PATCH v9 1/3] monitor/hmp: add support for flag argument with value Fabian Ebner
2022-02-25  8:49 ` [PATCH v9 2/3] qapi/monitor: refactor set/expire_password with enums Fabian Ebner
2022-02-25  8:49 ` [PATCH v9 3/3] qapi/monitor: allow VNC display id in set/expire_password Fabian Ebner
2022-02-25 11:34   ` Markus Armbruster
2022-02-25 12:23     ` Fabian Ebner [this message]
2022-02-25 12:44       ` Markus Armbruster
2022-03-01 11:29   ` Dr. David Alan Gilbert
2022-03-02 11:26 ` [PATCH v9 0/3] VNC-related HMP/QMP fixes Dr. David Alan Gilbert

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=39e1b9b4-d82b-4efc-2a5d-9ce904ecbffe@proxmox.com \
    --to=f.ebner@proxmox.com \
    --cc=armbru@redhat.com \
    --cc=berrange@redhat.com \
    --cc=dgilbert@redhat.com \
    --cc=eblake@redhat.com \
    --cc=kraxel@redhat.com \
    --cc=marcandre.lureau@gmail.com \
    --cc=marcandre.lureau@redhat.com \
    --cc=pbonzini@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=t.lamprecht@proxmox.com \
    --cc=w.bumiller@proxmox.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).