qemu/qga
Marc-André Lureau 8d769ec777 qga: add ssh-{add,remove}-authorized-keys
Add new commands to add and remove SSH public keys from
~/.ssh/authorized_keys.

I took a different approach for testing, including the unit tests right
with the code. I wanted to overwrite the function to get the user
details, I couldn't easily do that over QMP. Furthermore, I prefer
having unit tests very close to the code, and unit files that are domain
specific (commands-posix is too crowded already). FWIW, that
coding/testing style is Rust-style (where tests can or should even be
part of the documentation!).

Fixes:
https://bugzilla.redhat.com/show_bug.cgi?id=1885332

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Michal Privoznik <mprivozn@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
*squashed in fix-ups for setting file ownership and use of QAPI
 conditionals for CONFIG_POSIX instead of stub definitions
*disable qga-ssh-test for now due to G_TEST_OPTION_ISOLATE_DIRS
 triggering leak detector in build-oss-fuzz
*fix disallowed g_assert* usage reported by checkpatch
Signed-off-by: Michael Roth <michael.roth@amd.com>
2020-11-02 19:58:15 -06:00
..
installer meson: convert qemu-ga 2020-08-21 06:30:12 -04:00
vss-win32 meson: convert dummy Windows qga/qemu-ga target 2020-08-21 06:30:12 -04:00
channel-posix.c util: rename qemu_open() to qemu_open_old() 2020-09-16 10:33:48 +01:00
channel-win32.c qga: Fix a memory leak 2020-03-09 13:36:15 +01:00
channel.h qga: add systemd socket activation support 2017-03-06 00:54:18 -06:00
commands-common.h qga: Extract qmp_guest_file_read() to common commands.c 2020-04-15 09:15:53 -05:00
commands-posix-ssh.c qga: add ssh-{add,remove}-authorized-keys 2020-11-02 19:58:15 -06:00
commands-posix.c qga: add implementation of guest-get-disks for Linux 2020-11-02 11:32:15 -06:00
commands-win32.c qga: add implementation of guest-get-disks for Windows 2020-11-02 11:36:16 -06:00
commands.c qemu/atomic.h: rename atomic_ to qatomic_ 2020-09-23 16:07:44 +01:00
guest-agent-command-state.c qga: use local path for local headers 2018-06-01 19:20:38 +03:00
guest-agent-core.h Include qemu-common.h exactly where needed 2019-06-12 13:20:20 +02:00
main.c qmp: Call monitor_set_cur() only in qmp_dispatch() 2020-10-09 07:08:19 +02:00
meson.build qga: add ssh-{add,remove}-authorized-keys 2020-11-02 19:58:15 -06:00
qapi-schema.json qga: add ssh-{add,remove}-authorized-keys 2020-11-02 19:58:15 -06:00
service-win32.c
service-win32.h qga-win: changing --retry-path option behavior 2018-10-31 09:04:20 -05:00
vss-win32.c qga-win: add support for qmp_guest_fsfreeze_freeze_list 2018-10-30 16:48:49 -05:00
vss-win32.h qga-win: add support for qmp_guest_fsfreeze_freeze_list 2018-10-30 16:48:49 -05:00