2021-04-01 17:17:47 +02:00
|
|
|
# apparmor.d - Full set of apparmor profiles
|
|
|
|
# Copyright (C) 2020-2021 Mikhail Morfikov
|
2024-02-07 00:16:21 +01:00
|
|
|
# Copyright (C) 2021-2024 Alexandre Pujol <alexandre@pujol.io>
|
2021-04-01 17:17:47 +02:00
|
|
|
# SPDX-License-Identifier: GPL-2.0-only
|
2020-09-12 17:19:23 +02:00
|
|
|
|
2020-12-10 22:33:39 +01:00
|
|
|
abi <abi/3.0>,
|
2020-09-12 17:19:23 +02:00
|
|
|
|
2020-12-10 22:33:39 +01:00
|
|
|
include <tunables/global>
|
2020-09-12 17:19:23 +02:00
|
|
|
|
2023-07-09 15:59:53 +02:00
|
|
|
@{exec_path} = @{bin}/syncthing
|
2020-09-12 17:19:23 +02:00
|
|
|
profile syncthing @{exec_path} {
|
2020-12-10 22:33:39 +01:00
|
|
|
include <abstractions/base>
|
|
|
|
include <abstractions/nameservice-strict>
|
|
|
|
include <abstractions/ssl_certs>
|
|
|
|
|
|
|
|
network inet dgram,
|
|
|
|
network inet6 dgram,
|
|
|
|
network inet stream,
|
|
|
|
network inet6 stream,
|
|
|
|
network netlink raw,
|
2020-09-12 17:19:23 +02:00
|
|
|
|
|
|
|
@{exec_path} mrix,
|
|
|
|
|
2023-12-18 00:43:14 +01:00
|
|
|
@{open_path} rPx -> child-open,
|
2023-07-09 15:59:53 +02:00
|
|
|
@{bin}/ip rix,
|
2020-09-12 17:19:23 +02:00
|
|
|
|
2024-04-10 00:48:33 +02:00
|
|
|
/usr/share/mime/{,**} r,
|
2020-09-12 17:19:23 +02:00
|
|
|
|
|
|
|
/etc/mime.types r,
|
|
|
|
|
2022-02-08 19:16:45 +01:00
|
|
|
owner @{HOME}/ r,
|
2023-08-17 20:28:10 +02:00
|
|
|
owner @{HOME}/@{XDG_DATA_DIR}/syncthing/{,**} rwk,
|
2022-02-08 19:16:45 +01:00
|
|
|
owner @{user_config_dirs}/syncthing/{,**} rwk,
|
2024-04-08 20:17:01 +02:00
|
|
|
owner @{user_state_dirs}/syncthing/{,**} rwk,
|
2020-09-12 17:19:23 +02:00
|
|
|
|
2022-02-08 19:16:45 +01:00
|
|
|
/home/ r,
|
2021-10-07 15:50:46 +02:00
|
|
|
@{user_sync_dirs}/{,**} rw,
|
2020-09-12 17:19:23 +02:00
|
|
|
|
2021-10-07 15:50:46 +02:00
|
|
|
@{sys}/kernel/mm/transparent_hugepage/hpage_pmd_size r,
|
2020-09-12 17:19:23 +02:00
|
|
|
|
2021-10-07 15:50:46 +02:00
|
|
|
@{PROC}/sys/net/core/somaxconn r,
|
|
|
|
@{PROC}/@{pids}/net/route r,
|
2020-09-12 17:19:23 +02:00
|
|
|
|
2020-12-10 22:33:39 +01:00
|
|
|
include if exists <local/syncthing>
|
2020-09-12 17:19:23 +02:00
|
|
|
}
|