# apparmor.d - Full set of apparmor profiles
# Copyright (C) 2023-2024 Alexandre Pujol <alexandre@pujol.io>
# SPDX-License-Identifier: GPL-2.0-only

abi <abi/4.0>,

include <tunables/global>

@{exec_path} = @{bin}/akonadi_migration_agent
profile akonadi_migration_agent @{exec_path} {
  include <abstractions/base>
  include <abstractions/graphics>
  include <abstractions/kde-strict>
  include <abstractions/nameservice-strict>

  @{exec_path} mr,

  owner @{user_config_dirs}/akonadi-migrationrc r,
  owner @{user_config_dirs}/akonadi/ rw,
  owner @{user_config_dirs}/akonadi/** rwlk -> @{user_config_dirs}/akonadi/**,

  owner @{user_share_dirs}/akonadi_migration_agent/{,**} rw,
  
  /dev/tty r,

  include if exists <local/akonadi_migration_agent>
}

# vim:syntax=apparmor
