Arch Linux

Please read this before reporting a bug:

Do NOT report bugs when a package is just outdated, or it is in Unsupported. Use the 'flag out of date' link on the package page, or the Mailing List.

REPEAT: Do NOT report bugs for outdated packages!

FS#57391 - [sane] switch to ACL-based udev.rules to avoid conflict with default printer rules

Attached to Project: Arch Linux
Opened by Arseniy (ettavolt) - Tuesday, 06 February 2018, 11:35 GMT
Last edited by Doug Newgard (Scimmia) - Tuesday, 06 February 2018, 16:15 GMT
Task Type Feature Request
Category Packages: Extra
Status Assigned
Assigned To Tobias Powalowski (tpowa)
Architecture All
Severity Medium
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 0%
Votes 0
Private No


By default sane-backends generates 49-sane.rules that change MODE to 0660 and GROUP to scanner. For MFDs 50-udev-defaults (from systemd) changes GROUP to lp. Thanks to 70-uaccess libsane_matched=yes devices are available to current 'driving' user, but scanner group can't use it.
To avoid that I propose to switch to ACL-based rules.
It could be done as patching generator (where is formatting help, btw?):

diff --git a/sane/trunk/PKGBUILD b/sane/trunk/PKGBUILD
index d386351..50ac38f 100644
--- a/sane/trunk/PKGBUILD
+++ b/sane/trunk/PKGBUILD
@@ -6,7 +6,7 @@

pkgdesc="Scanner Access Now Easy"
@@ -24,6 +24,7 @@ prepare() {
cd "${srcdir}/${pkgname}-backends-${pkgver}"
# fix
patch -Np1 -i ${srcdir}/network.patch
+ sed -e 's/sane-desc -m udev /sane-desc -m udev+acl /' -i tools/

build() {

Or we can change build phase to invoke sane-desc again ourselves.

Additional info:
* sane 1.0.27-1
* systemd 236.81-1

Found this while investigating problems with
This task depends upon

Comment by Arseniy (ettavolt) - Thursday, 10 September 2020, 11:48 GMT
49-sane.rules and 50-udev-defaults are still in conflict of single-USB-connected Multi-Funcation Devices.