qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Christophe Fergeau <cfergeau@redhat.com>
To: qemu-devel@nongnu.org
Subject: Re: [Qemu-devel] [PATCH v2] spice: Allow to set password even if disable-ticketing was used
Date: Fri, 9 Oct 2015 18:43:38 +0200	[thread overview]
Message-ID: <20151009164338.GA3653@edamame.cdg.redhat.com> (raw)
In-Reply-To: <1439565057-18889-1-git-send-email-cfergeau@redhat.com>

[-- Attachment #1: Type: text/plain, Size: 1563 bytes --]

Hey,

On Fri, Aug 14, 2015 at 05:10:57PM +0200, Christophe Fergeau wrote:
> Before commit b1ea7b79e1, it was possible to start with -spice
> disable-ticketing, and then use the "set_password spice" command to
> enable ticketing with SPICE. Since commit b1ea7b79e1 this is no longer
> possible as qemu_spice_set_ticket() will return an error unless the
> 'auth' type is "spice". When ticketing is disabled, 'auth' is "none" so
> the attempt to set password fails.
> 
> This commit allows to call qemu_spice_set_ticket() when 'auth' is "none"
> and changes 'auth' to "spice" when this happens.
> 
> Signed-off-by: Christophe Fergeau <cfergeau@redhat.com>
> Reviewed-by: Daniel P. Berrange <berrange@redhat.com>

Any taker for that patch?

Thanks,

Christophe


> ---
> Changes since v1:
> - added Reviewed-by and missing Signed-off-by tags
> 
> 
>  ui/spice-core.c | 4 ++++
>  1 file changed, 4 insertions(+)
> 
> diff --git a/ui/spice-core.c b/ui/spice-core.c
> index 4da3042..3b20c6c 100644
> --- a/ui/spice-core.c
> +++ b/ui/spice-core.c
> @@ -882,6 +882,10 @@ static int qemu_spice_set_ticket(bool fail_if_conn, bool disconnect_if_conn)
>  int qemu_spice_set_passwd(const char *passwd,
>                            bool fail_if_conn, bool disconnect_if_conn)
>  {
> +    if (strcmp(auth, "none") == 0) {
> +        /* Allow to set a password when started with 'disable-ticketing' */
> +        auth = "spice";
> +    }
>      if (strcmp(auth, "spice") != 0) {
>          return -1;
>      }
> -- 
> 2.4.3
> 
> 

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 819 bytes --]

  reply	other threads:[~2015-10-09 16:45 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-08-14 15:10 [Qemu-devel] [PATCH v2] spice: Allow to set password even if disable-ticketing was used Christophe Fergeau
2015-10-09 16:43 ` Christophe Fergeau [this message]
2015-10-12  7:57   ` Gerd Hoffmann

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=20151009164338.GA3653@edamame.cdg.redhat.com \
    --to=cfergeau@redhat.com \
    --cc=qemu-devel@nongnu.org \
    /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).