From eb97897d936060bad0bc760156e89aa216bbf3ac Mon Sep 17 00:00:00 2001 From: doublez13 Date: Tue, 6 Feb 2024 13:34:26 -0700 Subject: [PATCH] Restructure --- apparmor.d/profiles-m-r/mutt | 75 ++++++++++++++++++------------------ 1 file changed, 37 insertions(+), 38 deletions(-) diff --git a/apparmor.d/profiles-m-r/mutt b/apparmor.d/profiles-m-r/mutt index 34342d0fb..aff1f887c 100644 --- a/apparmor.d/profiles-m-r/mutt +++ b/apparmor.d/profiles-m-r/mutt @@ -24,6 +24,42 @@ profile mutt @{exec_path} { @{exec_path} mr, + # Used to exec programs defined in the mailcap. + # There are countless programs that can be executed from the mailcap. + # This profile includes only the most basic. + @{bin}/{,ba,da}sh rix, + + @{bin}/sendmail rPUx, + /usr/libexec/sendmail/sendmail rPUx, + @{bin}/ispell rPUx, + # TODO: Add a profile for abook (Most distros don't ship this anymore though) + @{bin}/abook rPUx, + @{bin}/mutt_dotlock rix, + # Misc mutt scripts + @{lib}/mutt/* rix, + + @{bin}/w3m rCx -> html-renderer, + @{bin}/lynx rCx -> html-renderer, + @{bin}/vim rCx -> editor, + @{bin}/vim.* rCx -> editor, + @{bin}/sensible-editor rCx -> editor, + @{bin}/more rCx -> pager, + @{bin}/less rCx -> pager, + @{bin}/pager rCx -> pager, + @{bin}/gpg{2,} rCx -> gpg, + @{bin}/gpgconf rCx -> gpg, + @{bin}/gpgsm rCx -> gpg, + @{bin}/pgpewrap rCx -> gpg, + + /usr/share/terminfo/** r, + + /etc/mime.types r, + + # Mutt mailcap search path + /etc/{mutt/,}mailcap r, + /usr/{local/,}etc/mailcap r, + owner @{HOME}/.mailcap r, + # Mutt config files /usr/share/mutt/** r, /etc/{mutt/,}Muttrc r, @@ -42,7 +78,7 @@ profile mutt @{exec_path} { owner /{var/,}tmp/mutt* lrwk, # Needed for the edit operation. - @{HOME}/ r, + owner @{HOME}/ r, # User mbox # Could be a file or dir depending on mbox_type variable @@ -66,43 +102,6 @@ profile mutt @{exec_path} { # Common location for mail aliases owner @{HOME}/.mail_aliases r, - /usr/share/terminfo/** r, - - /etc/mime.types r, - - # Mutt mailcap search path - owner @{HOME}/.mailcap r, - /etc/{mutt/,}mailcap r, - /usr/{local/,}etc/mailcap r, - - # Used to exec programs defined in the mailcap. - # There are countless programs that can be executed from the mailcap. - # This profile includes only the most basic. - @{bin}/{,ba,da}sh rix, - - @{bin}/sendmail rPUx, - /usr/libexec/sendmail/sendmail rPUx, - @{bin}/ispell rPUx, - # TODO: Add a profile for abook (Most distros don't ship this anymore though) - @{bin}/abook rPUx, - @{bin}/mutt_dotlock rix, - #Misc mutt scripts - @{lib}/mutt/* rix, - - @{bin}/w3m rCx -> html-renderer, - @{bin}/lynx rCx -> html-renderer, - @{bin}/vim rCx -> editor, - @{bin}/vim.* rCx -> editor, - @{bin}/sensible-editor rCx -> editor, - @{bin}/more rCx -> pager, - @{bin}/less rCx -> pager, - @{bin}/pager rCx -> pager, - @{bin}/gpg{2,} rCx -> gpg, - @{bin}/gpgconf rCx -> gpg, - @{bin}/gpgsm rCx -> gpg, - @{bin}/pgpewrap rCx -> gpg, - - profile html-renderer { include