summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorMartin T. H. Sandsmark2021-10-07 11:33:14 +0200
committerMartin T. H. Sandsmark2021-10-07 11:49:47 +0200
commit283ba60fe9bada8efe77895d0bcc4b11ea522047 (patch)
treeab2ead5039386f5d9bf2c51f81ff8c5eb53c5821
downloadaur-283ba60fe9bada8efe77895d0bcc4b11ea522047.tar.gz
init
-rw-r--r--.SRCINFO12
-rw-r--r--PKGBUILD15
-rw-r--r--udev-uaccess-fix.rules4
3 files changed, 31 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..7333d4b373a7
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,12 @@
+pkgbase = udev-uaccess-fix
+ pkgdesc = Workaround for udev's uaccess ACL hack, to give all users access to devices
+ pkgver = 1
+ pkgrel = 1
+ url = https://github.com/sandsmark
+ arch = any
+ license = GPL3
+ depends = udev
+ source = udev-uaccess-fix.rules
+ md5sums = SKIP
+
+pkgname = udev-uaccess-fix
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..9849840569f7
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,15 @@
+pkgname=udev-uaccess-fix
+pkgver=1
+pkgrel=1
+pkgdesc="Workaround for udev's uaccess ACL hack, to give all users access to devices"
+arch=(any)
+url="https://github.com/sandsmark"
+depends=(udev)
+license=(GPL3)
+source=("udev-uaccess-fix.rules")
+md5sums=("SKIP") # handled by git
+
+package() {
+ # Run first, so if any other rules set a group this is overridden
+ install -D -m644 udev-uaccess-fix.rules "${pkgdir}/usr/lib/udev/rules.d/00-udev-uaccess-fix.rules"
+}
diff --git a/udev-uaccess-fix.rules b/udev-uaccess-fix.rules
new file mode 100644
index 000000000000..de379323b30c
--- /dev/null
+++ b/udev-uaccess-fix.rules
@@ -0,0 +1,4 @@
+# The 'uaccess' tag is a magic tag that makes udev try to look up the currently active user,
+# and set an ACL for that user to access the device.
+# This hack makes sure that there it at least one group a user can be part of to get the same access.
+TAG=="uaccess", GROUP="users"