From 833c475d34b3d10821addb400ce4c078ae8a11c4 Mon Sep 17 00:00:00 2001 From: Roman Beslik Date: Tue, 22 Feb 2022 20:13:19 +0200 Subject: [PATCH] initial --- apparmor.d/groups/ssh/ssh-keygen | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 apparmor.d/groups/ssh/ssh-keygen diff --git a/apparmor.d/groups/ssh/ssh-keygen b/apparmor.d/groups/ssh/ssh-keygen new file mode 100644 index 000000000..356337514 --- /dev/null +++ b/apparmor.d/groups/ssh/ssh-keygen @@ -0,0 +1,23 @@ +# vim:syntax=apparmor +# Copyright 2022 by Roman Beslik +# SPDX-License-Identifier: GPL-3.0-only + +abi , + +include + +@{exec_path} = /{usr/,}bin/ssh-keygen + +profile ssh-keygen @{exec_path} { + include + include + include + include # for entering a passphrase for a key + + @{exec_path} mr, + + owner @{HOME}/@{XDG_SSH_DIR}/ w, + owner @{HOME}/@{XDG_SSH_DIR}/*_*{,.pub} rw, + + include if exists +}