qemu-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-commits] [qemu/qemu] 49e562: ui: Check numeric part of expire_pass


From: Peter Maydell
Subject: [Qemu-commits] [qemu/qemu] 49e562: ui: Check numeric part of expire_password argument...
Date: Fri, 20 Jan 2023 05:17:28 -0800

  Branch: refs/heads/master
  Home:   https://github.com/qemu/qemu
  Commit: 49e56287cccfe8b5def4bc4916f367b9a0303161
      
https://github.com/qemu/qemu/commit/49e56287cccfe8b5def4bc4916f367b9a0303161
  Author: Markus Armbruster <armbru@redhat.com>
  Date:   2023-01-19 (Thu, 19 Jan 2023)

  Changed paths:
    M monitor/qmp-cmds.c

  Log Message:
  -----------
  ui: Check numeric part of expire_password argument @time properly

When argument @time isn't 'now' or 'never', we parse it as an integer,
optionally prefixed with '+'.  If parsing fails, we silently assume
zero.  Report an error and fail instead.

While there, use qemu_strtou64() instead of strtoull() so
checkpatch.pl won't complain.

Aside: encoding numbers in strings is bad QMP practice.

Signed-off-by: Markus Armbruster <armbru@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230109190321.1056914-2-armbru@redhat.com>


  Commit: 147c48791be34f3d28faa00b625780c881095be9
      
https://github.com/qemu/qemu/commit/147c48791be34f3d28faa00b625780c881095be9
  Author: Markus Armbruster <armbru@redhat.com>
  Date:   2023-01-19 (Thu, 19 Jan 2023)

  Changed paths:
    M monitor/hmp-cmds.c

  Log Message:
  -----------
  ui: Fix silent truncation of numeric keys in HMP sendkey

Keys are int.  HMP sendkey assigns them from the value strtoul(),
silently truncating values greater than INT_MAX.  Fix to reject them.

Signed-off-by: Markus Armbruster <armbru@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230109190321.1056914-3-armbru@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>


  Commit: 5c167b5301fc95731134886dfa61ce8c2de9f8c3
      
https://github.com/qemu/qemu/commit/5c167b5301fc95731134886dfa61ce8c2de9f8c3
  Author: Markus Armbruster <armbru@redhat.com>
  Date:   2023-01-19 (Thu, 19 Jan 2023)

  Changed paths:
    M meson.build
    M ui/vdagent.c

  Log Message:
  -----------
  ui/spice: Require spice-protocol >= 0.14.0

Version 0.14.0 is now old enough to have made it into the major
distributions:

   Debian 11: 0.14.3
   RHEL-8: 0.14.2
   FreeBSD (ports): 0.14.4
   Fedora 35: 0.14.0
   Ubuntu 20.04: 0.14.0
   OpenSUSE Leap 15.3: 0.14.3

Requiring it lets us drop two version checks in ui/vdagent.c.  It also
enables the next commit.

Signed-off-by: Markus Armbruster <armbru@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230109190321.1056914-4-armbru@redhat.com>


  Commit: f4c1bcb8c447cde358c9560672d13b90018074e8
      
https://github.com/qemu/qemu/commit/f4c1bcb8c447cde358c9560672d13b90018074e8
  Author: Markus Armbruster <armbru@redhat.com>
  Date:   2023-01-19 (Thu, 19 Jan 2023)

  Changed paths:
    M monitor/hmp-cmds.c

  Log Message:
  -----------
  Revert "hmp: info spice: take out webdav"

This reverts commit 7c6044a94e52db8aef9a71d616c7a0914adb71ab.

We had to take it out because SPICE_CHANNEL_WEBDAV requires
spice-protocol 0.12.7, but we had only 0.12.3.  We have 0.14.0 now, so
put it back in.

Signed-off-by: Markus Armbruster <armbru@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230109190321.1056914-5-armbru@redhat.com>


  Commit: 34d55725e664445ccd5621165b1ef805197a530e
      
https://github.com/qemu/qemu/commit/34d55725e664445ccd5621165b1ef805197a530e
  Author: Markus Armbruster <armbru@redhat.com>
  Date:   2023-01-19 (Thu, 19 Jan 2023)

  Changed paths:
    M chardev/spice.c
    M hw/display/qxl.c
    M hw/display/qxl.h
    M include/ui/qemu-spice.h
    M include/ui/spice-display.h
    M meson.build

  Log Message:
  -----------
  ui/spice: Require spice-server >= 0.14.0

Version 0.14.0 is now old enough to have made it into the major
distributions:

     Debian 11: 0.14.3
     RHEL-8: 0.14.3
     FreeBSD (ports): 0.15.0
     Fedora 35: 0.15.0
     Ubuntu 20.04: 0.14.2
     OpenSUSE Leap 15.3: 0.14.3

Requiring it lets us drop a number of version checks.  The next commit
will clean up some more.

Signed-off-by: Markus Armbruster <armbru@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230109190321.1056914-6-armbru@redhat.com>


  Commit: dfa258481649edc383c444b3e3eb578a5bf93aa6
      
https://github.com/qemu/qemu/commit/dfa258481649edc383c444b3e3eb578a5bf93aa6
  Author: Markus Armbruster <armbru@redhat.com>
  Date:   2023-01-19 (Thu, 19 Jan 2023)

  Changed paths:
    M hw/display/qxl.c
    M hw/display/trace-events
    M include/ui/qemu-spice.h
    M ui/spice-display.c

  Log Message:
  -----------
  ui/spice: QXLInterface method set_mm_time() is now dead, drop

SPICE_NEEDS_SET_MM_TIME is now always off.  Bury the dead code.

Signed-off-by: Markus Armbruster <armbru@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230109190321.1056914-7-armbru@redhat.com>


  Commit: 10e3c47a5d62dc746375f55b7b7313f0343dab1d
      
https://github.com/qemu/qemu/commit/10e3c47a5d62dc746375f55b7b7313f0343dab1d
  Author: Markus Armbruster <armbru@redhat.com>
  Date:   2023-01-19 (Thu, 19 Jan 2023)

  Changed paths:
    M monitor/hmp-cmds.c

  Log Message:
  -----------
  ui/spice: Give hmp_info_spice()'s channel_names[] static linkage

Suggested-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Message-Id: <20230109190321.1056914-8-armbru@redhat.com>


  Commit: 61d7f2a9569b56ac1970d52fe3c7683e70998ed8
      
https://github.com/qemu/qemu/commit/61d7f2a9569b56ac1970d52fe3c7683e70998ed8
  Author: Markus Armbruster <armbru@redhat.com>
  Date:   2023-01-19 (Thu, 19 Jan 2023)

  Changed paths:
    M monitor/hmp-cmds.c
    M monitor/qmp-cmds.c

  Log Message:
  -----------
  ui: Clean up a few things checkpatch.pl would flag later on

Fix a few style violations so that checkpatch.pl won't complain when I
move this code.

Signed-off-by: Markus Armbruster <armbru@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Message-Id: <20230109190321.1056914-9-armbru@redhat.com>


  Commit: 9949b06e2e95f821a76215194413bb78aa782d53
      
https://github.com/qemu/qemu/commit/9949b06e2e95f821a76215194413bb78aa782d53
  Author: Markus Armbruster <armbru@redhat.com>
  Date:   2023-01-19 (Thu, 19 Jan 2023)

  Changed paths:
    M monitor/qmp-cmds.c
    M ui/meson.build
    A ui/ui-qmp-cmds.c

  Log Message:
  -----------
  ui: Move QMP commands from monitor to new ui/ui-qmp-cmds.c

This moves these commands from MAINTAINERS section "QMP" to
"Graphics".

Command add-client applies to socket character devices in addition to
display devices.  Move it anyway.  Aside: the way @protocol character
device IDs and display types is bad design.

Signed-off-by: Markus Armbruster <armbru@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Message-Id: <20230109190321.1056914-10-armbru@redhat.com>


  Commit: 3125af295e92825834031e8cbb8ca55c718a6fcb
      
https://github.com/qemu/qemu/commit/3125af295e92825834031e8cbb8ca55c718a6fcb
  Author: Markus Armbruster <armbru@redhat.com>
  Date:   2023-01-19 (Thu, 19 Jan 2023)

  Changed paths:
    A include/monitor/qmp-helpers.h
    M monitor/qmp-cmds.c
    M ui/ui-qmp-cmds.c

  Log Message:
  -----------
  ui: Factor out qmp_add_client() parts and move to ui/ui-qmp-cmds.c

Signed-off-by: Markus Armbruster <armbru@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Message-Id: <20230109190321.1056914-11-armbru@redhat.com>


  Commit: 5011d262f0580ae7d9acf35256697520db2f1720
      
https://github.com/qemu/qemu/commit/5011d262f0580ae7d9acf35256697520db2f1720
  Author: Markus Armbruster <armbru@redhat.com>
  Date:   2023-01-19 (Thu, 19 Jan 2023)

  Changed paths:
    M include/monitor/hmp.h
    M monitor/hmp-cmds.c
    M monitor/misc.c
    M ui/meson.build
    A ui/ui-hmp-cmds.c

  Log Message:
  -----------
  ui: Move HMP commands from monitor to new ui/ui-hmp-cmds.c

This moves these commands from MAINTAINERS section "Human
Monitor (HMP)" to "Graphics".

Signed-off-by: Markus Armbruster <armbru@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Message-Id: <20230109190321.1056914-12-armbru@redhat.com>


  Commit: f8f2e9a859a1450756972266b0d6f4c081e6486c
      
https://github.com/qemu/qemu/commit/f8f2e9a859a1450756972266b0d6f4c081e6486c
  Author: Markus Armbruster <armbru@redhat.com>
  Date:   2023-01-19 (Thu, 19 Jan 2023)

  Changed paths:
    M monitor/hmp-cmds.c

  Log Message:
  -----------
  ui: Improve "change vnc" error reporting

Switch from monitor_printf() to error_setg() and hmp_handle_error().
This makes "this is an error" more obvious both in the source and in
the monitor, where hmp_handle_error() prefixes the message with
"Error: ".

Signed-off-by: Markus Armbruster <armbru@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Message-Id: <20230109190321.1056914-13-armbru@redhat.com>


  Commit: f916a1751e735d3202a2dfc051d324a206831b69
      
https://github.com/qemu/qemu/commit/f916a1751e735d3202a2dfc051d324a206831b69
  Author: Markus Armbruster <armbru@redhat.com>
  Date:   2023-01-19 (Thu, 19 Jan 2023)

  Changed paths:
    M include/monitor/hmp.h
    M monitor/hmp-cmds.c
    M monitor/qmp-cmds.c
    M ui/ui-hmp-cmds.c

  Log Message:
  -----------
  ui: Factor out hmp_change_vnc(), and move to ui/ui-hmp-cmds.c

Signed-off-by: Markus Armbruster <armbru@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Message-Id: <20230109190321.1056914-14-armbru@redhat.com>


  Commit: bcaf1fde57cfcb8952a8778ede0d4cf4136420b6
      
https://github.com/qemu/qemu/commit/bcaf1fde57cfcb8952a8778ede0d4cf4136420b6
  Author: Markus Armbruster <armbru@redhat.com>
  Date:   2023-01-19 (Thu, 19 Jan 2023)

  Changed paths:
    M ui/ui-hmp-cmds.c

  Log Message:
  -----------
  ui: Reduce nesting in hmp_change_vnc() slightly

Transform

    if (good) {
        do stuff
    } else {
        handle error
    }

to

    if (!good) {
        handle error
        return;
    }
    do stuff

Signed-off-by: Markus Armbruster <armbru@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Message-Id: <20230109190321.1056914-15-armbru@redhat.com>


  Commit: 006e79cdf4273b52a854f36b119ebd2ea954ea92
      
https://github.com/qemu/qemu/commit/006e79cdf4273b52a854f36b119ebd2ea954ea92
  Author: Markus Armbruster <armbru@redhat.com>
  Date:   2023-01-19 (Thu, 19 Jan 2023)

  Changed paths:
    M ui/input.c

  Log Message:
  -----------
  ui: Don't check for mode change after mouse_set error

hmp_mouse_set() doesn't bail out when it can't find a mouse.
Harmless, since qemu_input_check_mode_change() should be a no-op then.
Clean it up anyway.

Signed-off-by: Markus Armbruster <armbru@redhat.com>
Message-Id: <20230109190321.1056914-16-armbru@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>


  Commit: ec843b97f2c02b85115c7c5c8799ea4d02ddfba7
      
https://github.com/qemu/qemu/commit/ec843b97f2c02b85115c7c5c8799ea4d02ddfba7
  Author: Markus Armbruster <armbru@redhat.com>
  Date:   2023-01-19 (Thu, 19 Jan 2023)

  Changed paths:
    M include/monitor/hmp.h
    M include/ui/console.h
    M monitor/misc.c
    M ui/input.c
    M ui/ui-hmp-cmds.c

  Log Message:
  -----------
  ui: Split hmp_mouse_set() and move the HMP part to ui/

Signed-off-by: Markus Armbruster <armbru@redhat.com>
Message-Id: <20230109190321.1056914-17-armbru@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>


  Commit: a0506b7c8fc72f7bca272647f359d76cc40a02c1
      
https://github.com/qemu/qemu/commit/a0506b7c8fc72f7bca272647f359d76cc40a02c1
  Author: Markus Armbruster <armbru@redhat.com>
  Date:   2023-01-19 (Thu, 19 Jan 2023)

  Changed paths:
    M ui/input.c

  Log Message:
  -----------
  ui: Simplify control flow in qemu_mouse_set()

Signed-off-by: Markus Armbruster <armbru@redhat.com>
Message-Id: <20230109190321.1056914-18-armbru@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>


  Commit: 70d17c3eedefe36b0f423575b57dc9708c4a9d57
      
https://github.com/qemu/qemu/commit/70d17c3eedefe36b0f423575b57dc9708c4a9d57
  Author: Peter Maydell <peter.maydell@linaro.org>
  Date:   2023-01-19 (Thu, 19 Jan 2023)

  Changed paths:
    M chardev/spice.c
    M hw/display/qxl.c
    M hw/display/qxl.h
    M hw/display/trace-events
    M include/monitor/hmp.h
    A include/monitor/qmp-helpers.h
    M include/ui/console.h
    M include/ui/qemu-spice.h
    M include/ui/spice-display.h
    M meson.build
    M monitor/hmp-cmds.c
    M monitor/misc.c
    M monitor/qmp-cmds.c
    M ui/input.c
    M ui/meson.build
    M ui/spice-display.c
    A ui/ui-hmp-cmds.c
    A ui/ui-qmp-cmds.c
    M ui/vdagent.c

  Log Message:
  -----------
  Merge tag 'pull-monitor-2023-01-19' of https://repo.or.cz/qemu/armbru into 
staging

Monitor patches for 2023-01-19

# -----BEGIN PGP SIGNATURE-----
#
# iQJGBAABCAAwFiEENUvIs9frKmtoZ05fOHC0AOuRhlMFAmPJO+8SHGFybWJydUBy
# ZWRoYXQuY29tAAoJEDhwtADrkYZTbBwP/RsZLLDCz6moSet4Hly+vPTWibyYYDkS
# uk6a70Ja7fsAcONumBaXdpoinPtbED662eYxidbLFr//tAjnKu57jnwAIFTTOKJc
# sCVtdgOlbNSZFrqyIr8ctY6yKJLLBaa02in/BczFIQphPatpUwvxrvrdgxc58NNK
# qaeKDnWKXvZ6EUaYPpruxqE5J/NV0ykyab9Rc8rNJqdUMnqbd662zHcA0l31misH
# gAfKBhReo53XUbfvoFS9kaoBQaTJPk4CcKHaT7NJXR8ezlIEQVLtFzdfAf04kSdG
# 8VRwwx5NDpmafATEaMXJhJ74Fyc8biDWXoQ6aA1jdUCu39B2EPl1H1qlCG9ZYp7w
# CkbJU6UwtOYsG11NU8Mr1u9rMlAgAVkkLsMYiiI4cpLBkI0vkoV66ms3oZgYUtbq
# /TgCpfjKpE87ZBLIwJjGsg+TMN2AH5lpt/49HV8QEFA8mI7h29oo2HvheXE7PPzH
# b9iIe9ADrKwB5DpJW2vigPj+fSHqoSGd3R/hUcMVOubKnJme97mys2hD+sfxga/H
# qfKLzgTqQI2dGhfow/8wzfYdfYmkii+ggDyzcxLAxx2ITO/fLWJygmTgXJmA3dl6
# pnpZvhOu4dEgK4VstugXcvgCVHUVXd9wqI9wxJAc+mKanTmZIJBnxCm/QVG2/w/d
# 5IgmP9Se7vb0
# =7OEC
# -----END PGP SIGNATURE-----
# gpg: Signature made Thu 19 Jan 2023 12:47:43 GMT
# gpg:                using RSA key 354BC8B3D7EB2A6B68674E5F3870B400EB918653
# gpg:                issuer "armbru@redhat.com"
# gpg: Good signature from "Markus Armbruster <armbru@redhat.com>" [full]
# gpg:                 aka "Markus Armbruster <armbru@pond.sub.org>" [full]
# Primary key fingerprint: 354B C8B3 D7EB 2A6B 6867  4E5F 3870 B400 EB91 8653

* tag 'pull-monitor-2023-01-19' of https://repo.or.cz/qemu/armbru:
  ui: Simplify control flow in qemu_mouse_set()
  ui: Split hmp_mouse_set() and move the HMP part to ui/
  ui: Don't check for mode change after mouse_set error
  ui: Reduce nesting in hmp_change_vnc() slightly
  ui: Factor out hmp_change_vnc(), and move to ui/ui-hmp-cmds.c
  ui: Improve "change vnc" error reporting
  ui: Move HMP commands from monitor to new ui/ui-hmp-cmds.c
  ui: Factor out qmp_add_client() parts and move to ui/ui-qmp-cmds.c
  ui: Move QMP commands from monitor to new ui/ui-qmp-cmds.c
  ui: Clean up a few things checkpatch.pl would flag later on
  ui/spice: Give hmp_info_spice()'s channel_names[] static linkage
  ui/spice: QXLInterface method set_mm_time() is now dead, drop
  ui/spice: Require spice-server >= 0.14.0
  Revert "hmp: info spice: take out webdav"
  ui/spice: Require spice-protocol >= 0.14.0
  ui: Fix silent truncation of numeric keys in HMP sendkey
  ui: Check numeric part of expire_password argument @time properly

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>


Compare: https://github.com/qemu/qemu/compare/239b8b0699a2...70d17c3eedef



reply via email to

[Prev in Thread] Current Thread [Next in Thread]