aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--GIDs2
-rw-r--r--security/libu2f-host/Makefile13
-rw-r--r--security/libu2f-host/files/pkg-message.in13
-rw-r--r--security/libu2f-host/files/u2f.conf.sample91
-rw-r--r--security/libu2f-host/pkg-plist1
5 files changed, 117 insertions, 3 deletions
diff --git a/GIDs b/GIDs
index 7b8c28edb492..f71d03de5701 100644
--- a/GIDs
+++ b/GIDs
@@ -57,7 +57,7 @@ dcc:*:112:
amavis:*:113:
dhis:*:114:
_symon:*:115:
-# free: 116
+u2f:*:116:
smokeping:*:117:
ircproxyd:*:118:
mythtv:*:119:
diff --git a/security/libu2f-host/Makefile b/security/libu2f-host/Makefile
index 09b5b084b2ab..390395ca0b5a 100644
--- a/security/libu2f-host/Makefile
+++ b/security/libu2f-host/Makefile
@@ -3,12 +3,13 @@
PORTNAME= libu2f-host
PORTVERSION= 1.1.3
DISTVERSIONPREFIX= ${PORTNAME}-
+PORTREVISION= 1
CATEGORIES= security devel
-MAINTAINER= bapt@FreeBSD.org
+MAINTAINER= cpm@FreeBSD.org
COMMENT= Yubico Universal 2nd Factor (U2F) Host C Library
-LICENSE= LGPL21 GPLv3
+LICENSE= LGPL21+ GPLv3+
LICENSE_COMB= multi
BUILD_DEPENDS= gengetopt:devel/gengetopt \
@@ -26,4 +27,12 @@ USE_LDCONFIG= yes
CONFIGRUE_ARGS= --disable-gtk-doc
INSTALL_TARGET= install-strip
+SUB_FILES= pkg-message
+
+GROUPS= u2f
+
+post-install:
+ ${INSTALL_DATA} ${FILESDIR}/u2f.conf.sample \
+ ${STAGEDIR}${PREFIX}/etc/devd
+
.include <bsd.port.mk>
diff --git a/security/libu2f-host/files/pkg-message.in b/security/libu2f-host/files/pkg-message.in
new file mode 100644
index 000000000000..123a08a44e53
--- /dev/null
+++ b/security/libu2f-host/files/pkg-message.in
@@ -0,0 +1,13 @@
+======================================================================
+
+The package requires read/write access to USB devices. To facilitate
+such access it comes with a devd.conf(5) file, but you still need to
+restart devd(8), add the desired users to "u2f" group and log those
+out of the current session. For example:
+
+$ pw group mod u2f -m <user>
+$ shutdown -r now
+
+For details, see %%PREFIX%%/etc/devd/u2f.conf
+
+======================================================================
diff --git a/security/libu2f-host/files/u2f.conf.sample b/security/libu2f-host/files/u2f.conf.sample
new file mode 100644
index 000000000000..54ab3951f9b5
--- /dev/null
+++ b/security/libu2f-host/files/u2f.conf.sample
@@ -0,0 +1,91 @@
+# Allow members of group u2f to access U2F devices
+
+# Yubico Yubikey
+notify 100 {
+ match "system" "USB";
+ match "subsystem" "DEVICE";
+ match "type" "ATTACH";
+ match "vendor" "0x1050";
+ match "product" "(0x0113|0x0114|0x0115|0x0116|0x0120|0x0420|0x0403|0x0406|0x0407|0x0410)";
+ action "chgrp u2f /dev/$cdev; chmod g+rw /dev/$cdev";
+};
+
+# Happlink (formerly Plug-Up) Security KEY
+notify 100 {
+ match "system" "USB";
+ match "subsystem" "DEVICE";
+ match "type" "ATTACH";
+ match "vendor" "0x2581";
+ match "product" "0xf1d0";
+ action "chgrp u2f /dev/$cdev; chmod g+rw /dev/$cdev";
+};
+
+# Neowave Keydo and Keydo AES
+notify 100 {
+ match "system" "USB";
+ match "subsystem" "DEVICE";
+ match "type" "ATTACH";
+ match "vendor" "0x1e0d";
+ match "product" "(0xf1d0|0xf1ae)";
+ action "chgrp u2f /dev/$cdev; chmod g+rw /dev/$cdev";
+};
+
+# HyperSecu HyperFIDO
+notify 100 {
+ match "system" "USB";
+ match "subsystem" "DEVICE";
+ match "type" "ATTACH";
+ match "vendor" "(0x096e|0x2ccf)";
+ match "product" "0x0880";
+ action "chgrp u2f /dev/$cdev; chmod g+rw /dev/$cdev";
+};
+
+# Feitian ePass FIDO
+notify 100 {
+ match "system" "USB";
+ match "subsystem" "DEVICE";
+ match "type" "ATTACH";
+ match "vendor" "0x096e";
+ match "product" "(0x0850|0x0852|0x0853|0x0854|0x0856|0x0858|0x085a|0x085b)";
+ action "chgrp u2f /dev/$cdev; chmod g+rw /dev/$cdev";
+};
+
+# JaCarta U2F
+notify 100 {
+ match "system" "USB";
+ match "subsystem" "DEVICE";
+ match "type" "ATTACH";
+ match "vendor" "0x24dc";
+ match "product" "0x0101";
+ action "chgrp u2f /dev/$cdev; chmod g+rw /dev/$cdev";
+};
+
+# U2F Zero
+notify 100 {
+ match "system" "USB";
+ match "subsystem" "DEVICE";
+ match "type" "ATTACH";
+ match "vendor" "0x10c4";
+ match "product" "0x8acf";
+ action "chgrp u2f /dev/$cdev; chmod g+rw /dev/$cdev";
+};
+
+# VASCO SeccureClick
+notify 100 {
+ match "system" "USB";
+ match "subsystem" "DEVICE";
+ match "type" "ATTACH";
+ match "vendor" "0x1a44";
+ match "product" "0x00bb";
+ action "chgrp u2f /dev/$cdev; chmod g+rw /dev/$cdev";
+};
+
+# Bluink Key
+notify 100 {
+ match "system" "USB";
+ match "subsystem" "DEVICE";
+ match "type" "ATTACH";
+ match "vendor" "0x2abe";
+ match "product" "0x1002";
+ action "chgrp u2f /dev/$cdev; chmod g+rw /dev/$cdev";
+};
diff --git a/security/libu2f-host/pkg-plist b/security/libu2f-host/pkg-plist
index 446ce63a809e..076187a49359 100644
--- a/security/libu2f-host/pkg-plist
+++ b/security/libu2f-host/pkg-plist
@@ -1,4 +1,5 @@
bin/u2f-host
+@sample etc/devd/u2f.conf.sample
include/u2f-host/u2f-host-types.h
include/u2f-host/u2f-host-version.h
include/u2f-host/u2f-host.h