Add update-ca-trust

This commit is contained in:
Alexandre Pujol 2021-06-12 15:21:28 +01:00
parent 6bbe50573b
commit d084023120
No known key found for this signature in database
GPG Key ID: C5469996F0DF68EC

View File

@ -0,0 +1,40 @@
# apparmor.d - Full set of apparmor profiles
# Copyright (C) 2021 Alexandre Pujol <alexandre@pujol.io>
# SPDX-License-Identifier: GPL-2.0-only
abi <abi/3.0>,
include <tunables/global>
@{exec_path} = /{usr/,}bin/update-ca-trust
profile update-ca-trust @{exec_path} {
include <abstractions/base>
include <abstractions/ssl_certs>
capability dac_read_search,
@{exec_path} mr,
/{usr/,}bin/bash rix,
/{usr/,}bin/find rix,
/{usr/,}bin/ln rix,
/{usr/,}bin/trust rix,
/ r,
/usr/share/p11-kit/modules/{,*} r,
/etc/ca-certificates/extracted/{tls,email,objsign}-ca-bundle.pem{,.*} w,
/etc/ca-certificates/extracted/ca-bundle.trust.crt{,.*} w,
/etc/ca-certificates/extracted/cadir/{,*} rw,
/etc/ca-certificates/extracted/edk2-cacerts.bin{,.*} w,
/etc/ssl/certs/{,*} rw,
/etc/ssl/certs/java/cacerts{,.*} w,
/dev/tty rw,
# Silencer
deny network inet6 stream,
deny network inet stream,
include if exists <local/update-ca-trust>
}