From 1cc9932700339042e83c6c54114734231630548c Mon Sep 17 00:00:00 2001 From: aidaleuc Date: Wed, 24 Apr 2024 08:40:28 -0600 Subject: qga: Refactor common SSH functions MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Message-Id: <20240424144029.30665-2-aidan_leuck@selinc.com> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 8bit In preparation of a Windows implementation, move the non-POSIX specific code to commands-common-ssh. Signed-off-by: Aidan Leuck Reviewed-by: Philippe Mathieu-Daudé Tested-by: Dehan Meng Reviewed-by: Konstantin Kostiuk Link: https://lore.kernel.org/r/20240424144029.30665-2-aidan_leuck@selinc.com Signed-off-by: Konstantin Kostiuk --- qga/commands-common-ssh.h | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 qga/commands-common-ssh.h (limited to 'qga/commands-common-ssh.h') diff --git a/qga/commands-common-ssh.h b/qga/commands-common-ssh.h new file mode 100644 index 0000000000..14d955fa84 --- /dev/null +++ b/qga/commands-common-ssh.h @@ -0,0 +1,10 @@ +/* + * This work is licensed under the terms of the GNU GPL, version 2 or later. + * See the COPYING file in the top-level directory. + */ + +#include "qapi/qapi-builtin-types.h" + +GStrv read_authkeys(const char *path, Error **errp); +bool check_openssh_pub_keys(strList *keys, size_t *nkeys, Error **errp); +bool check_openssh_pub_key(const char *key, Error **errp); -- cgit 1.4.1