aboutsummaryrefslogtreecommitdiff
path: root/data/41-nitrokey.rules
diff options
context:
space:
mode:
authorSzczepan Zalega <szczepan@nitrokey.com>2019-02-11 15:34:09 +0100
committerSzczepan Zalega <szczepan@nitrokey.com>2019-02-11 15:34:09 +0100
commit3788515d6546971a3ac6e46769fb8d6e6d24e159 (patch)
tree1e5645b4d0eb54c8f6c2cbb526e7f6ec9b63e3c2 /data/41-nitrokey.rules
parent1bf90425d2006558ce4f4aac0ed5680d31b77918 (diff)
parentf1969fc5f9076c0bc38f1b9d4358b2e5588af288 (diff)
downloadlibnitrokey-3788515d6546971a3ac6e46769fb8d6e6d24e159.tar.gz
libnitrokey-3788515d6546971a3ac6e46769fb8d6e6d24e159.tar.bz2
Merge branch '136-fido-u2f-rules-update'
Update Udev rules files Fixes #136
Diffstat (limited to 'data/41-nitrokey.rules')
-rw-r--r--data/41-nitrokey.rules44
1 files changed, 38 insertions, 6 deletions
diff --git a/data/41-nitrokey.rules b/data/41-nitrokey.rules
index 764f4bf..0099edf 100644
--- a/data/41-nitrokey.rules
+++ b/data/41-nitrokey.rules
@@ -1,20 +1,52 @@
+#
+# Copyright (c) 2015-2019 Nitrokey UG
+#
+# This file is part of libnitrokey.
+#
+# libnitrokey is free software: you can redistribute it and/or modify
+# it under the terms of the GNU Lesser General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# any later version.
+#
+# libnitrokey is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU Lesser General Public License
+# along with libnitrokey. If not, see <http://www.gnu.org/licenses/>.
+#
+# SPDX-License-Identifier: LGPL-3.0
+#
+
+# Here rules in new style should be provided. Matching devices should be tagged with 'uaccess'.
+# File prefix number should be lower than 73, to be correctly processed by the Udev.
+# Recommended udev version: >= 188.
+#
+ACTION!="add|change", GOTO="u2f_end"
+
# Nitrokey U2F
-KERNEL=="hidraw*", SUBSYSTEM=="hidraw", MODE="0664", GROUP="plugdev", ATTRS{idVendor}=="2581", ATTRS{idProduct}=="f1d0"
+KERNEL=="hidraw*", SUBSYSTEM=="hidraw", ATTRS{idVendor}=="2581", ATTRS{idProduct}=="f1d0", TAG+="uaccess"
+# Nitrokey FIDO U2F
+KERNEL=="hidraw*", SUBSYSTEM=="hidraw", ATTRS{idVendor}=="20a0", ATTRS{idProduct}=="4287", TAG+="uaccess"
+
+LABEL="u2f_end"
+
SUBSYSTEM!="usb", GOTO="gnupg_rules_end"
ACTION!="add", GOTO="gnupg_rules_end"
# USB SmartCard Readers
## Crypto Stick 1.2
-ATTR{idVendor}=="20a0", ATTR{idProduct}=="4107", ENV{ID_SMARTCARD_READER}="1", ENV{ID_SMARTCARD_READER_DRIVER}="gnupg", GROUP+="plugdev", TAG+="uaccess"
+ATTR{idVendor}=="20a0", ATTR{idProduct}=="4107", ENV{ID_SMARTCARD_READER}="1", ENV{ID_SMARTCARD_READER_DRIVER}="gnupg", TAG+="uaccess"
## Nitrokey Pro
-ATTR{idVendor}=="20a0", ATTR{idProduct}=="4108", ENV{ID_SMARTCARD_READER}="1", ENV{ID_SMARTCARD_READER_DRIVER}="gnupg", GROUP+="plugdev", TAG+="uaccess"
+ATTR{idVendor}=="20a0", ATTR{idProduct}=="4108", ENV{ID_SMARTCARD_READER}="1", ENV{ID_SMARTCARD_READER_DRIVER}="gnupg", TAG+="uaccess"
## Nitrokey Storage
-ATTR{idVendor}=="20a0", ATTR{idProduct}=="4109", ENV{ID_SMARTCARD_READER}="1", ENV{ID_SMARTCARD_READER_DRIVER}="gnupg", GROUP+="plugdev", TAG+="uaccess"
+ATTR{idVendor}=="20a0", ATTR{idProduct}=="4109", ENV{ID_SMARTCARD_READER}="1", ENV{ID_SMARTCARD_READER_DRIVER}="gnupg", TAG+="uaccess"
## Nitrokey Start
-ATTR{idVendor}=="20a0", ATTR{idProduct}=="4211", ENV{ID_SMARTCARD_READER}="1", ENV{ID_SMARTCARD_READER_DRIVER}="gnupg", GROUP+="plugdev", TAG+="uaccess"
+ATTR{idVendor}=="20a0", ATTR{idProduct}=="4211", ENV{ID_SMARTCARD_READER}="1", ENV{ID_SMARTCARD_READER_DRIVER}="gnupg", TAG+="uaccess"
## Nitrokey HSM
-ATTR{idVendor}=="20a0", ATTR{idProduct}=="4230", ENV{ID_SMARTCARD_READER}="1", ENV{ID_SMARTCARD_READER_DRIVER}="gnupg", GROUP+="plugdev", TAG+="uaccess"
+ATTR{idVendor}=="20a0", ATTR{idProduct}=="4230", ENV{ID_SMARTCARD_READER}="1", ENV{ID_SMARTCARD_READER_DRIVER}="gnupg", TAG+="uaccess"
LABEL="gnupg_rules_end"