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

abi <abi/3.0>,

include <tunables/global>

@{exec_path} = @{lib}/vlc/vlc-cache-gen
profile vlc-cache-gen @{exec_path} {
  include <abstractions/base>
  include <abstractions/consoles>

  @{exec_path} mr,

  @{lib}/vlc/plugins/{,*} rw,

  @{sys}/devices/system/node/ r,
  @{sys}/devices/system/node/node@{int}/meminfo r,

  # Inherit silencer
  deny network inet6 stream,
  deny network inet stream,

  include if exists <local/vlc-cache-gen>
}

# vim:syntax=apparmor
