Get images from a scanner

This commit is contained in:
Roman Beslik 2024-09-26 13:33:27 +03:00 committed by Alex
parent 91fc3adb63
commit 779377ce4c
2 changed files with 42 additions and 1 deletions

View File

@ -16,6 +16,8 @@ profile gimp @{exec_path} {
include <abstractions/thumbnails-cache-write>
include <abstractions/user-download-strict>
signal (send) set=(term, kill) peer=xsane-gimp,
#aa:dbus talk bus=session name=org.gnome.Shell.Screenshot label=gnome-shell
#aa:dbus talk bus=session name=org.gtk.vfs label="gvfsd{,-*}"
@ -23,7 +25,8 @@ profile gimp @{exec_path} {
@{lib}/gimp/*/plug-ins/** rix,
@{open_path} rPx -> child-open-help,
@{bin}/xsane-gimp rPx,
@{open_path} rPx -> child-open-help,
/usr/share/gimp/{,**} r,
/usr/share/mypaint-data/{,**} r,

View File

@ -0,0 +1,38 @@
# apparmor.d - Full set of apparmor profiles
# Copyright (C) 2024 Roman Beslik <me@beroal.in.ua>
# SPDX-License-Identifier: GPL-2.0-only
abi <abi/3.0>,
include <tunables/global>
@{exec_path} = @{bin}/xsane-gimp
profile xsane-gimp /{,usr/}{,s}bin/xsane-gimp {
include <abstractions/base>
include <abstractions/gnome-strict>
include <abstractions/devices-usb>
signal (receive) set=(term, kill) peer=gimp,
network inet dgram,
network inet6 dgram,
network netlink raw,
@{exec_path} mr,
@{system_share_dirs}/gimp/{,**} r,
@{system_share_dirs}/sane/xsane/{,**} r,
@{system_share_dirs}/snmp/mibs/{,**} r, # network
/etc/sane.d/{,**} r,
owner @{HOME}/.sane/{,**} rw,
owner @{tmp}/xsane-* rw,
@{sys}/devices/@{pci}/{model,type,vendor} r,
@{PROC}/sys/dev/parport/{,parport@{int}/{base-addr,irq}} r,
# SCSI
@{sys}/bus/scsi/devices/ r,
@{PROC}/scsi/scsi r,
include if exists <local/xsane-gimp>
}
# vim:syntax=apparmor