Commit graph

730 commits

Author SHA1 Message Date
Christian Boltz
f651633281 abstractions/php: allow ICU (unicode support) data tables
Reported by darix on IRC, and also something I noticed in my own usage
of PHP.

PR: https://gitlab.com/apparmor/apparmor/merge_requests/184
(cherry picked from commit e396f9dae9)
Signed-off-by: John Johansen <john.johansen@canonical.com>
2018-09-11 18:22:59 -07:00
Vincas Dargis
ec0c5d470a Add kde-icon-cache-write abstraction
KIconLoader uses ~/.cache/icon-cache.kcache, and it is opened in
read-write mode. Because access to it does not seem to be critical, and
read-only mode is not used, rules for accessing this cache is added to
it's own new "write" abstraction, instead of making kde abstraction more
permissive by default.

(cherry picked from commit 94014c09f0)
Signed-off-by: John Johansen <john.johansen@canonical.com>
2018-08-14 16:56:04 -07:00
Vincas Dargis
925cf94cdc Add kde-language-write abstraction
Currently, kde abstraction only allows reading
~/.config/klanguageoverridesrc file (by design). Some KDE applications
has option to change language for it's interface, and this needs write
access. This is fixed by introducing new abstraction.

(cherry picked from commit 7345f61e9c)
Signed-off-by: John Johansen <john.johansen@canonical.com>
2018-08-14 16:55:42 -07:00
Vincas Dargis
090e9986f1 Add kde-globals-write abstraction
Currently, kde abstraction only allows reading ~/.config/kdeglobals (by
design), though some applications might need to update it's contents
such as KFileDialog settings. This patch fixes it by introducing new
abstraction.

(cherry picked from commit fae93f1b6c)
Signed-off-by: John Johansen <john.johansen@canonical.com>
2018-08-14 16:55:16 -07:00
Vincas Dargis
2eb9ab0913 Add recent-documents-write abstraction
Add abstraction for updating recent documents list.

(cherry picked from commit 4fe8ae97c4)
Signed-off-by: John Johansen <john.johansen@canonical.com>
2018-08-14 16:38:22 -07:00
Christian Boltz
7f0aed7fb8 add dehydrated certificate location to ssl_* abstractions
I don't use dehydrated myself, therefore this is based on the comments
on https://build.opensuse.org/request/show/533380

(cherry picked from commit 2e8b902248)
Signed-off-by: John Johansen <john.johansen@canonical.com>
2018-08-07 23:55:16 -07:00
Christian Boltz
3abf501527 Fix typo (double /) in opencl-pocl abstraction
(cherry picked from commit a054855433)
Signed-off-by: John Johansen <john.johansen@canonical.com>
2018-08-07 03:13:01 -07:00
Vincas Dargis
a5eeed7c63 Add OpenCL abstractions
(cherry picked from commit 8237d6e776)
Signed-off-by: John Johansen <john.johansen@canonical.com>
2018-08-07 03:13:01 -07:00
Christian Boltz
b3dfe3366a Merge branch 'add-path-to-abstractions-python' into 'master'
Allow /usr/local/lib/python3/dist-packages in abstractions/python

See merge request apparmor/apparmor!160

Acked-by: John Johansen <john.johansen@canonical.com>

Acked-by: Christian Boltz <apparmor@cboltz.de> for 2.10..master

(cherry picked from commit 763a6787d8)

6a10f076 Allow /usr/local/lib/python3/dist-packages in abstractions/python
2018-08-06 18:11:50 +00:00
intrigeri
249b68c92e tunables/share: make variables value more readable by avoiding the use of too many alternations.
Thanks to Christian Boltz for the suggestion and the patch!
2018-07-29 23:42:09 +00:00
intrigeri
749d94297f Rename @{usr_share} → @{system_share_dirs} and @{home_local_share} → @{user_share_dirs}.
Thanks a lot to Simon McVittie for the much better names suggestion.
2018-07-29 23:42:02 +00:00
intrigeri
8a8349d14d freedesktop.org abstraction: refactor (factorize) for consistency.
This change makes the @{home_local_share} rules similar to the
@{usr_share} ones.
2018-07-29 23:41:57 +00:00
intrigeri
7cc2c0dfad freedesktop.org abstraction: simplify by not attempting to guess the exhaustive list of files that can exist in {~/.local/share,/usr/share}/applications/.
As Simon McVittie wrote, "if a specification or library creates extra caches, or
has .desktop files in a subdirectory, or anything like that, then I don't see
why we wouldn't want to allow reading those too".
2018-07-29 23:41:53 +00:00
intrigeri
bb0a9c76e3 kde abstraction: drop redundant rules for icons access.
These rules are already in abstractions/freedesktop.org that's included
by the abstractions/kde.
2018-07-29 23:41:42 +00:00
intrigeri
b86917dc95 freedesktop.org abstraction: treat Flatpak exports the same way as bits shipped by the distro.
As Simon McVittie <smcv@collabora.com> wrote on
https://bugs.debian.org/865206 and on the AppArmor mailing list:

"Anything in /var/lib/flatpak/exports/share or
~/.local/share/flatpak/exports/share is essentially equivalent to
the corresponding path in /usr/{local/,}share, and is something
that has deliberately been "exported" to the rest of the system by a
Flatpak-confined app.

The only reason to prevent reading those directories would be if you do
not want the AppArmor-confined app to be able to enumerate the other
software you have installed on your system, as an anti-fingerprinting
mechanism.".

Bug-Debian: https://bugs.debian.org/865206
2018-07-29 23:41:37 +00:00
intrigeri
9d8b6f4dbd freedesktop.org abstraction: DRY by factorizing duplicated path components with variables.
These alternations will need to grow quite a bit in order to support Flatpak
exports. Let's avoid repeating ourselves too much.
2018-07-29 23:41:28 +00:00
Dimitri John Ledkov
40ba8bf047
Profiles: Patch usr.sbin.useradd to support usr-merge.
(cherry picked from commit e99fa6c605)
Signed-off-by: Steve Beattie <steve.beattie@canonical.com>
PR: https://gitlab.com/apparmor/apparmor/merge_requests/152
2018-07-27 10:33:47 -07:00
Christian Boltz
d9d3cae2aa
adjust abstractions/python for python 3.7
Python 3.7 was released yesterday - and to make the abstraction
future-proof, also cover 3.8 and 3.9 in advance ;-)

(cherry picked from commit 01f41fbff8)

Signed-off-by: Steve Beattie <steve.beattie@canonical.com>
PR: https://gitlab.com/apparmor/apparmor/merge_requests/139/
2018-06-29 11:19:31 -07:00
Christian Boltz
90c0d2b3c3
profiles: update samba profiles
- allow smbd to load new shared libraries
- allow winbindd to read and write new kerberos cache location

Based on a patch by "Samuel Cabrero" <scabrero@suse.com>

(cherry picked from commit 23b5f29b80)

References: https://bugzilla.opensuse.org/show_bug.cgi?id=1092099

Acked-by: Steve Beattie <steve@nxnw.org>
PR: https://gitlab.com/apparmor/apparmor/merge_requests/121
2018-05-09 14:02:02 -07:00
Christian Boltz
64c196a487
Merge branch 'Talkless/apparmor-nvidia-update'
See https://gitlab.com/apparmor/apparmor/merge_requests/92

Acked-by: John Johansen <john.johansen@canonical.com>
2018-04-14 23:38:29 +02:00
Christian Boltz
a7ffae4396 mlmmj-send-profile: allow reading digesters.d/*
Reported by Per Jessen by mail
2018-04-14 21:25:09 +00:00
Christian Boltz
c4e607199c
dovecot/config: allow dac_read_search and reading ssl-parameters.dat
References: https://bugzilla.opensuse.org/show_bug.cgi?id=1087753#c12
2018-04-14 22:53:40 +02:00
Christian Boltz
26a8b72225 allow dovecot/auth to write /run/dovecot/old-stats-user
References: https://bugzilla.opensuse.org/show_bug.cgi?id=1087753#c4
            (3rd bullet point)
2018-04-13 13:55:05 +00:00
Christian Boltz
36bdd6ea70 add dovecot/stats profile, and allow dovecot to run it
References: https://bugzilla.opensuse.org/show_bug.cgi?id=1088161
2018-04-13 13:55:05 +00:00
Vincas Dargis
0d0a196077 Allow nvidia abstraction to read memory block size
Fix DENIED message detected with NVIDIA 390.48 drivers.
2018-04-12 20:36:56 +03:00
Vincas Dargis
0c2690d819 Fix ubuntu-browsers for 64bit openSUSE
On 64 bit openSUSE system, Chromium and Firefox browsers are installed in
/usr/lib64/ directory.
2018-04-01 16:48:13 +03:00
Christian Boltz
208933829f Fix $(PWD) when using "make -C profiles"
By default, it stays at the "calling directory" instead of the directory
of the Makefile, which breaks "make -C profiles check".
Explicitely set it in the Makefile to get the right directory.
2018-03-18 18:09:04 +00:00
intrigeri
22e94633c3 dnsmasq profile: allow chown capability.
dnsmasq on Debian sid now chown's its PID file.

Bug-Debian: https://bugs.debian.org/889806
Signed-off-by: John Johansen <john.johansen@canonical.com>
2018-03-05 23:51:23 -08:00
Christian Boltz
8ef7b59454
mlmmj-sub: fix moderated subscription
/var/spool/mlmmj/*/moderation/subscribe* rw, is needed for lists with
moderated subscription

References: http://bugzilla.opensuse.org/show_bug.cgi?id=1082230
2018-02-22 22:57:51 +01:00
Vincas Dargis
11e7dab95e Allow to create .nv directory
Update nvidia abstraction to allow creating NVIDIA-specific user directories in
case it is missing (due to fresh $HOME or if manually removed for any reason).
2018-02-16 16:54:32 +02:00
Christian Boltz
e88af93322 Merge branch 'update-base-abstraction' into 'master'
Update base abstraction for ld.so.conf and friends.

See merge request apparmor/apparmor!62

Acked-by: Christian Boltz <apparmor@cboltz.de> for 2.9..master
2018-02-15 20:14:38 +00:00
Vincas Dargis
b0456adbd8 Add dri-enumerate abstraction
Create new dri-enumerate abstraction with rules needed for some GUI applications
allowing to get GPU device information.
2018-02-04 16:01:27 +02:00
Vincas Dargis
8dd517f6dd Move DRI-specific rules into it's own abstraction
Add new dri-common abstraction to contain basic DRI-specific rules.

This refactoring is based on a decision to have set of dri-* abstractions for
fine grained control on case-by-case basis. While dri-common is included in X
abstraction by default, additional DRI-related abstractions can be introduced
(such as for enumerating graphics devices) while keeping them logically together
with same dri- prefix.
2018-02-04 14:21:16 +02:00
Vincas Dargis
6d22c871bf Update base abstraction for ld.so.conf and friends.
Fix denies for latest Thunderbird and Firefox on Debian Sid due to
missing access to /etc/ld.so.conf and /etc/ld.so.conf.d/*.
2018-01-26 19:55:31 +02:00
Christian Boltz
85f8cace12 Merge branch 'cboltz-ntpd' into 'master'
allow access to ntp clockstats

See merge request apparmor/apparmor!54
2018-01-23 23:02:16 +00:00
Rene Engelhard
8fc3dcb312 abstractions/gnupg: allow pubring.kbx 2018-01-20 23:54:08 +01:00
John Johansen
62dbd29656 Merge branch 'dovecot-lda-protocols' into 'master'
Allow dovecot-lda to read anything under /usr/share/dovecot/protocols.d/

See merge request apparmor/apparmor!57

Acked-by: John Johansen <john.johansen@canonical.com>
2018-01-20 08:18:07 +00:00
intrigeri
1b51dac4c9 Allow dovecot-lda to read anything under /usr/share/dovecot/protocols.d/.
On current Debian sid it needs to read
/usr/share/dovecot/protocols.d/imapd.protocol, which is not surprising given it
already needed read access to /usr/share/dovecot/protocols.d/.
2018-01-20 06:25:25 +00:00
Christian Boltz
1541175c36
dovecot/lmtp: allow dac_read_search
Fixes https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=887591
2018-01-18 18:15:43 +01:00
Christian Boltz
1b58f226ce
allow access to ntp clockstats
References: http://bugzilla.opensuse.org/show_bug.cgi?id=1076247
2018-01-16 21:15:41 +01:00
John Johansen
e55583ff27 profile: fix syslog-ng startup for some configurations
buglink: https://bugs.launchpad.net/bugs/1739909

Signed-off-by: John Johansen <john.johansen@canonical.com>
2017-12-24 00:13:58 -08:00
John Johansen
a3693f56f3 Merge branch 'cboltz-netstat' into 'master'
netstat: allow capability sys_ptrace,

See merge request apparmor/apparmor!46
2017-12-22 20:50:11 +00:00
Christian Boltz
81ca52d948
netstat: allow capability sys_ptrace,
Denying it means netstat -p (actually tested with -tulpen) can't find
out the program name.

sys_ptrace is "only" needed for tracing processes that run under a
different uid.

Also add  ptrace (read),  for systems that support ptrace rules.
2017-12-22 21:43:54 +01:00
John Johansen
f8b208ee80 Merge branch 'cboltz-dovecot' into 'master'
Update /usr/lib/dovecot/* profiles

See merge request apparmor/apparmor!42

Acked-by: John Johansen <john.johansen@canonical.com>
2017-12-22 19:20:07 +00:00
John Johansen
bcfb735b9a Merge branch 'cboltz-xauth' into 'master'
abstractions/X: add another location for .Xauthority

See merge request apparmor/apparmor!39

Acked-by: John Johansen <john.johansen@canonical.com>
2017-12-22 19:00:36 +00:00
Christian Boltz
06928db1ce
Update /usr/lib/dovecot/* profiles
- dict needs abstractions/openssl (seen with dovecot 2.2.31 since
  using openssl 1.1)
- imap needs to write tempfiles (seen with dovecot 2.2.31)
- managesieve-login needs access to the login-master-notify socket
  (seen with dovecot 2.2.33)
- pop3-login needs access to the anvil socket (reported by pfak on
  IRC some months ago)
2017-12-18 17:00:35 +01:00
Christian Boltz
6713f9d94a Merge branch 'fix-pulse-config' into 'master'
Fix local pulseaudio config file access

See merge request apparmor/apparmor!38


Acked-by: Christian Boltz <apparmor@cboltz.de> for 2.9..trunk
2017-12-17 16:19:42 +00:00
Christian Boltz
bb96e38a90
abstractions/X: add another location for .Xauthority
With the latest sddm, .Xauthority is now located at
  @{HOME}/.local/share/sddm/.Xauthority
2017-12-17 15:38:26 +01:00
Vincas Dargis
f73627cbb5 Fix local pulseaudio config file access
Add rules to allow reading .conf files from $HOME/.config/pulse
and $HOME/.config/pulse/client.conf.d directories.
2017-12-17 15:56:21 +02:00
Vincas Dargis
9f24650ef9 Fix signal sending for usr.sbin.dovecot
Add signal rules to allow dovecot master daemon to send signals
to various child daemons (for reloading/restarting).
2017-12-15 18:17:48 +02:00