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

abi <abi/3.0>,

include <tunables/global>

@{exec_path} = @{lib}/helper-scripts/tor_bootstrap_check.py 
profile tor-bootstrap-check @{exec_path} {
  include <abstractions/base>
  include <abstractions/python>

  @{exec_path} mr,

  @{lib}/helper-scripts/{,**} r,

  owner /tmp/tmp.@{rand10} rw,

  @{run}/tor/control.authcookie r,

  include if exists <local/tor-bootstrap-check>
}

# vim:syntax=apparmor
