commit bcd71184ad3dcbb26d2162cd56022fa573360e9c
Author: Simone Caronni <negativo17(a)gmail.com>
Date: Fri Jan 18 22:37:59 2019 +0100
Update udev controller rules to use uacces
99-shield-controller.rules | 4 +-
steam-controller-gamepad-emulation.patch | 11 ----
steam-udev-relax-console-user.patch | 91 ++++++++++++++++++++++++++++++++
steam.spec | 11 ++--
4 files changed, 100 insertions(+), 17 deletions(-)
---
diff --git a/99-shield-controller.rules b/99-shield-controller.rules
index e21092f..1a9787f 100644
--- a/99-shield-controller.rules
+++ b/99-shield-controller.rules
@@ -1,4 +1,4 @@
# NVIDIA Shield Portable (2013)
-SUBSYSTEM=="input", ENV{ID_MODEL}=="NVIDIA_Controller_v01.01",
MODE="0666", ENV{ID_INPUT_JOYSTICK}="1",
ENV{ID_INPUT_MOUSE}=""
+SUBSYSTEM=="input", ENV{ID_MODEL}=="NVIDIA_Controller_v01.01",
MODE="0660", TAG+="uaccess", ENV{ID_INPUT_JOYSTICK}="1",
ENV{ID_INPUT_MOUSE}=""
# NVIDIA Shield Controller (2015)
-SUBSYSTEM=="input", ENV{ID_MODEL}=="NVIDIA_Controller_v01.03",
MODE="0666", ENV{ID_INPUT_JOYSTICK}="1",
ENV{ID_INPUT_MOUSE}=""
+SUBSYSTEM=="input", ENV{ID_MODEL}=="NVIDIA_Controller_v01.03",
MODE="0660", TAG+="uaccess", ENV{ID_INPUT_JOYSTICK}="1",
ENV{ID_INPUT_MOUSE}=""
diff --git a/steam-udev-relax-console-user.patch b/steam-udev-relax-console-user.patch
new file mode 100644
index 0000000..893ddaa
--- /dev/null
+++ b/steam-udev-relax-console-user.patch
@@ -0,0 +1,91 @@
+diff -Naur steam.old/lib/udev/rules.d/60-steam-input.rules
steam/lib/udev/rules.d/60-steam-input.rules
+--- steam.old/lib/udev/rules.d/60-steam-input.rules 2019-01-18 22:09:13.955398708 +0100
++++ steam/lib/udev/rules.d/60-steam-input.rules 2019-01-18 23:01:34.022657738 +0100
+@@ -1,64 +1,65 @@
+ # Valve USB devices
+-SUBSYSTEM=="usb", ATTRS{idVendor}=="28de", MODE="0666"
++SUBSYSTEM=="usb", ATTRS{idVendor}=="28de", MODE="0660",
TAG+="uaccess"
++
+ # Steam Controller udev write access
+-KERNEL=="uinput", SUBSYSTEM=="misc", TAG+="uaccess"
++KERNEL=="uinput", SUBSYSTEM=="misc", TAG+="uaccess",
OPTIONS+="static_node=uinput"
+
+ # Valve HID devices over USB hidraw
+-KERNEL=="hidraw*", ATTRS{idVendor}=="28de", MODE="0666"
++KERNEL=="hidraw*", ATTRS{idVendor}=="28de", MODE="0660",
TAG+="uaccess"
+
+ # Valve HID devices over bluetooth hidraw
+-KERNEL=="hidraw*", KERNELS=="*28DE:*", MODE="0666"
++KERNEL=="hidraw*", KERNELS=="*28DE:*", MODE="0660",
TAG+="uaccess"
+
+ # DualShock 4 over USB hidraw
+-KERNEL=="hidraw*", ATTRS{idVendor}=="054c",
ATTRS{idProduct}=="05c4", MODE="0666"
++KERNEL=="hidraw*", ATTRS{idVendor}=="054c",
ATTRS{idProduct}=="05c4", MODE="0660", TAG+="uaccess"
+
+ # DualShock 4 wireless adapter over USB hidraw
+-KERNEL=="hidraw*", ATTRS{idVendor}=="054c",
ATTRS{idProduct}=="0ba0", MODE="0666"
++KERNEL=="hidraw*", ATTRS{idVendor}=="054c",
ATTRS{idProduct}=="0ba0", MODE="0660", TAG+="uaccess"
+
+ # DualShock 4 Slim over USB hidraw
+-KERNEL=="hidraw*", ATTRS{idVendor}=="054c",
ATTRS{idProduct}=="09cc", MODE="0666"
++KERNEL=="hidraw*", ATTRS{idVendor}=="054c",
ATTRS{idProduct}=="09cc", MODE="0660", TAG+="uaccess"
+
+ # DualShock 4 over bluetooth hidraw
+-KERNEL=="hidraw*", KERNELS=="*054C:05C4*", MODE="0666"
++KERNEL=="hidraw*", KERNELS=="*054C:05C4*", MODE="0660",
TAG+="uaccess"
+
+ # DualShock 4 Slim over bluetooth hidraw
+-KERNEL=="hidraw*", KERNELS=="*054C:09CC*", MODE="0666"
++KERNEL=="hidraw*", KERNELS=="*054C:09CC*", MODE="0660",
TAG+="uaccess"
+
+ # Nintendo Switch Pro Controller over USB hidraw
+-KERNEL=="hidraw*", ATTRS{idVendor}=="057e",
ATTRS{idProduct}=="2009", MODE="0666"
++KERNEL=="hidraw*", ATTRS{idVendor}=="057e",
ATTRS{idProduct}=="2009", MODE="0660", TAG+="uaccess"
+
+ # Nintendo Switch Pro Controller over bluetooth hidraw
+-KERNEL=="hidraw*", KERNELS=="*057E:2009*", MODE="0666"
++KERNEL=="hidraw*", KERNELS=="*057E:2009*", MODE="0660",
TAG+="uaccess"
+
+ # Nacon PS4 Revolution Pro Controller
+-KERNEL=="hidraw*", ATTRS{idVendor}=="146b",
ATTRS{idProduct}=="0d01", MODE="0666"
++KERNEL=="hidraw*", ATTRS{idVendor}=="146b",
ATTRS{idProduct}=="0d01", MODE="0660", TAG+="uaccess"
+
+ # Razer Raiju PS4 Controller
+-KERNEL=="hidraw*", ATTRS{idVendor}=="1532",
ATTRS{idProduct}=="1000", MODE="0666"
++KERNEL=="hidraw*", ATTRS{idVendor}=="1532",
ATTRS{idProduct}=="1000", MODE="0660", TAG+="uaccess"
+
+ # Razer Panthera Arcade Stick
+-KERNEL=="hidraw*", ATTRS{idVendor}=="1532",
ATTRS{idProduct}=="0401", MODE="0666"
++KERNEL=="hidraw*", ATTRS{idVendor}=="1532",
ATTRS{idProduct}=="0401", MODE="0660", TAG+="uaccess"
+
+ # Mad Catz - Street Fighter V Arcade FightPad PRO
+-KERNEL=="hidraw*", ATTRS{idVendor}=="0738",
ATTRS{idProduct}=="8250", MODE="0666"
++KERNEL=="hidraw*", ATTRS{idVendor}=="0738",
ATTRS{idProduct}=="8250", MODE="0660", TAG+="uaccess"
+
+ # Mad Catz - Street Fighter V Arcade FightStick TE S+
+-KERNEL=="hidraw*", ATTRS{idVendor}=="0738",
ATTRS{idProduct}=="8384", MODE="0666"
++KERNEL=="hidraw*", ATTRS{idVendor}=="0738",
ATTRS{idProduct}=="8384", MODE="0660", TAG+="uaccess"
+
+ # EMiO Elite Controller for PS4
+-KERNEL=="hidraw*", ATTRS{idVendor}=="0c12",
ATTRS{idProduct}=="1cf6", MODE="0666"
++KERNEL=="hidraw*", ATTRS{idVendor}=="0c12",
ATTRS{idProduct}=="1cf6", MODE="0660", TAG+="uaccess"
+
+ # HORI RAP4
+-KERNEL=="hidraw*", ATTRS{idVendor}=="0f0d",
ATTRS{idProduct}=="008a", MODE="0666"
++KERNEL=="hidraw*", ATTRS{idVendor}=="0f0d",
ATTRS{idProduct}=="008a", MODE="0660", TAG+="uaccess"
+
+ # HORIPAD 4 FPS
+-KERNEL=="hidraw*", ATTRS{idVendor}=="0f0d",
ATTRS{idProduct}=="0055", MODE="0666"
++KERNEL=="hidraw*", ATTRS{idVendor}=="0f0d",
ATTRS{idProduct}=="0055", MODE="0660", TAG+="uaccess"
+
+ # HORIPAD 4 FPS Plus
+-KERNEL=="hidraw*", ATTRS{idVendor}=="0f0d",
ATTRS{idProduct}=="0066", MODE="0666"
++KERNEL=="hidraw*", ATTRS{idVendor}=="0f0d",
ATTRS{idProduct}=="0066", MODE="0660", TAG+="uaccess"
+
+ # Armor Armor 3 Pad PS4
+-KERNEL=="hidraw*", ATTRS{idVendor}=="0c12",
ATTRS{idProduct}=="0e10", MODE="0666"
++KERNEL=="hidraw*", ATTRS{idVendor}=="0c12",
ATTRS{idProduct}=="0e10", MODE="0660", TAG+="uaccess"
+
+ # STRIKEPAD PS4 Grip Add-on
+-KERNEL=="hidraw*", ATTRS{idVendor}=="054c",
ATTRS{idProduct}=="05c5", MODE="0666"
++KERNEL=="hidraw*", ATTRS{idVendor}=="054c",
ATTRS{idProduct}=="05c5", MODE="0660", TAG+="uaccess"
diff --git a/steam.spec b/steam.spec
index c666995..c905366 100644
--- a/steam.spec
+++ b/steam.spec
@@ -3,7 +3,7 @@
Name: steam
Version: 1.0.0.59
-Release: 5%{?dist}
+Release: 6%{?dist}
Summary: Installer for the Steam software distribution service
# Redistribution and repackaging for Linux is allowed, see license file
License: Steam License Agreement
@@ -38,9 +38,9 @@ Patch0: %{name}-3570.patch
#
https://github.com/ValveSoftware/steam-for-linux/issues/3273
Patch1: %{name}-3273.patch
-# Make Steam Controller usable as a GamePad:
-#
https://steamcommunity.com/app/353370/discussions/0/490123197956024380/
-Patch2: %{name}-controller-gamepad-emulation.patch
+# Use uaccess on device files so only the local console users have access to
+# the files instead of using 666 permissions.
+Patch2: %{name}-udev-relax-console-user.patch
BuildRequires: desktop-file-utils
BuildRequires: firewalld-filesystem
@@ -221,6 +221,9 @@ fi
%endif
%changelog
+* Fri Jan 18 2019 Simone Caronni <negativo17(a)gmail.com> - 1.0.0.59-6
+- Update udev controller rules to use uacces.
+
* Fri Jan 18 2019 Simone Caronni <negativo17(a)gmail.com> - 1.0.0.59-5
- Firewall definitions already bundled in firewalld 0.6.2 on Fedora 29+.
- Update firewall definitions to align with Fedora 29+.