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

  abi <abi/4.0>,

  include <abstractions/consoles>

  @{bin}/depmod    mr,
  @{bin}/insmod    mr,
  @{bin}/kmod      mr,
  @{bin}/lsmod     mr,
  @{bin}/modinfo   mr,
  @{bin}/modprobe  mr,
  @{bin}/rmmod     mr,

  @{lib}/modprobe.d/ r,
  @{lib}/modprobe.d/*.conf r,

  /etc/depmod.d/ r,
  /etc/depmod.d/*.conf r,
  /etc/modprobe.d/ r,
  /etc/modprobe.d/*.conf r,

  @{PROC}/cmdline r,
  @{PROC}/modules r,

  include if exists <abstractions/app/kmod.d>

# vim:syntax=apparmor
