summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDiego Elio Pettenò <flameeyes@gentoo.org>2009-09-29 12:03:21 +0000
committerDiego Elio Pettenò <flameeyes@gentoo.org>2009-09-29 12:03:21 +0000
commite6feb19472c1092f2754c1b60a2bba3bc15a66c9 (patch)
treec9010087b880a7493c65cd7490c5e40d448a344d /app-crypt
parentamd64/x86 stable, bug #279386 (diff)
downloadhistorical-e6feb19472c1092f2754c1b60a2bba3bc15a66c9.tar.gz
historical-e6feb19472c1092f2754c1b60a2bba3bc15a66c9.tar.bz2
historical-e6feb19472c1092f2754c1b60a2bba3bc15a66c9.zip
New revision, thanks to the comments from Rob Kendrick (upstream); the init script now uses lsusb, and is only installed for non-Linux systems, while the correct udev rules are installed on Linux. Add a check for the CDC driver, and also add warnings about both the userland USB and CDC options.
Package-Manager: portage-2.2_rc42/cvs/Linux x86_64
Diffstat (limited to 'app-crypt')
-rw-r--r--app-crypt/ekeyd/ChangeLog13
-rw-r--r--app-crypt/ekeyd/Manifest14
-rw-r--r--app-crypt/ekeyd/ekeyd-1.0.5-r2.ebuild (renamed from app-crypt/ekeyd/ekeyd-1.0.5-r1.ebuild)60
-rw-r--r--app-crypt/ekeyd/files/ekey-ulusbd.conf4
-rw-r--r--app-crypt/ekeyd/files/ekey-ulusbd.init17
5 files changed, 75 insertions, 33 deletions
diff --git a/app-crypt/ekeyd/ChangeLog b/app-crypt/ekeyd/ChangeLog
index 6e4c380d37ac..97d368d117bd 100644
--- a/app-crypt/ekeyd/ChangeLog
+++ b/app-crypt/ekeyd/ChangeLog
@@ -1,6 +1,17 @@
# ChangeLog for app-crypt/ekeyd
# Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/app-crypt/ekeyd/ChangeLog,v 1.2 2009/09/28 18:29:35 flameeyes Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-crypt/ekeyd/ChangeLog,v 1.3 2009/09/29 12:03:20 flameeyes Exp $
+
+*ekeyd-1.0.5-r2 (29 Sep 2009)
+
+ 29 Sep 2009; Diego E. Pettenò <flameeyes@gentoo.org>
+ -ekeyd-1.0.5-r1.ebuild, +ekeyd-1.0.5-r2.ebuild, files/ekey-ulusbd.conf,
+ files/ekey-ulusbd.init:
+ New revision, thanks to the comments from Rob Kendrick (upstream); the
+ init script now uses lsusb, and is only installed for non-Linux systems,
+ while the correct udev rules are installed on Linux. Add a check for the
+ CDC driver, and also add warnings about both the userland USB and CDC
+ options.
*ekeyd-1.0.5-r1 (28 Sep 2009)
diff --git a/app-crypt/ekeyd/Manifest b/app-crypt/ekeyd/Manifest
index e9a999991469..73a062a6a47a 100644
--- a/app-crypt/ekeyd/Manifest
+++ b/app-crypt/ekeyd/Manifest
@@ -1,17 +1,17 @@
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
-AUX ekey-ulusbd.conf 579 RMD160 2a8782a79e9a17bc308aa9b67ddbab8d8b61037e SHA1 dc32017824cba6a3921d2df6282f85f2af042836 SHA256 d18a974adc61f465c85a9bf83377de1486be9cb792ee04a72bd978c885e1b5b7
-AUX ekey-ulusbd.init 1173 RMD160 bffa19688ac673f6128a4e1abaabb085473bff6b SHA1 08589b116dc5864f20aabae363304f31a167f320 SHA256 ea3ddeb21667b4875f31c8f87066a8854429b7746169bb9485efd73520eed243
+AUX ekey-ulusbd.conf 579 RMD160 0fb73018df4b96197fb1bd245f98e078b9e84501 SHA1 c7b287b34080c6cc941e217e21768f290803ca98 SHA256 7077c2634fe54d1c1a6af9f48d4e76b53b8c8f2b110c44ec50a4998f7e797fa9
+AUX ekey-ulusbd.init 1037 RMD160 2995e11c7ed31362ed9b88d8c8dd77e1848089de SHA1 9cf03418dd2eb55ad92be59a67de23c5ba7059e6 SHA256 6dff19623a7ec64e724741f7a9da7884f8e17ef4b2f118fc2e7d55b53e9d62cd
AUX ekeyd.init 763 RMD160 3506c2400360e67cd4b5a375de7cb0669ec74578 SHA1 8fa7d722ea8f3a1cccaffee5a54d81a8b7abffe0 SHA256 c8e7ba5b34618fabfb9d161e64f6112f82c0a2bc644a4f5a14a2569783b43946
DIST ekeyd-1.0.5.tar.gz 87743 RMD160 986b596b8988a731ce43a1eeafa8dbd7f71c9384 SHA1 95b1f54315746ee979b38d62383c0fa7c25ace90 SHA256 fc82c4e1c9d702c74bd98df3e4b18f5d1c9dc9ba59ad0a3569d79def02b847e1
-EBUILD ekeyd-1.0.5-r1.ebuild 3127 RMD160 1d27a4a8563eaa9cc8ec65a1225fa165362a4df5 SHA1 5e870cea94c54a1b7baf55d6016978a0ffdc6c54 SHA256 27fbbbf65e84e6ea3f5cd580bdb43226ff8d7cb1eb60e1ddba9d0940fe12f146
-MISC ChangeLog 872 RMD160 9fc2e1845ad548ae1b68d3db7696627868547ec1 SHA1 31b44ccc2f7a40d1da678b8476fc19472a383798 SHA256 ea7b8f6807bdaed2dee3103ebf10761b98d57862b82c3f430d73f76671837b89
+EBUILD ekeyd-1.0.5-r2.ebuild 4108 RMD160 6f82ede24717e2c3466219023588223a7153d157 SHA1 a51e060d69f28a5728a462771ef9eb39cbba71a6 SHA256 ffe562af8c9c69731212d18742c0a9e42afe35c6df456a19dd27512e96de467d
+MISC ChangeLog 1366 RMD160 c0feb156558dd03cb857680c88430fab5327eafd SHA1 18781014a4e730f9efa7992836cd6884d4256e54 SHA256 e814c396a18f221d98bbc9797c9c2c47f421c40dd3d9fb529f86d71cfd614d18
MISC metadata.xml 401 RMD160 988224226b2b1e56ca024b6866deb0291faf3ab7 SHA1 17ae474fa2c6964cc4feab7173ec86f1062b9197 SHA256 3e04add274d3b051cdc073d9b3b8272861caff36bec655e6c86cf2a4fabb66c4
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.11 (GNU/Linux)
-iEYEARECAAYFAkrBAJEACgkQAiZjviIA2XgxmQCcCSUkbgGtzQd6kmmqTb01jJ8H
-E2EAoM+ZK8QkeNm/57cerc4D5rMTyM9R
-=Aah6
+iEYEARECAAYFAkrB94cACgkQAiZjviIA2XgeggCggdqxQIU67J9M1apn/mJedoxT
+6q0AoJdUYBQ9CXuz9a3vnyKBGOk0m4Fa
+=x+UZ
-----END PGP SIGNATURE-----
diff --git a/app-crypt/ekeyd/ekeyd-1.0.5-r1.ebuild b/app-crypt/ekeyd/ekeyd-1.0.5-r2.ebuild
index dee57d21b439..49374e9cbfc4 100644
--- a/app-crypt/ekeyd/ekeyd-1.0.5-r1.ebuild
+++ b/app-crypt/ekeyd/ekeyd-1.0.5-r2.ebuild
@@ -1,10 +1,10 @@
# Copyright 1999-2009 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/app-crypt/ekeyd/ekeyd-1.0.5-r1.ebuild,v 1.1 2009/09/28 18:29:35 flameeyes Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-crypt/ekeyd/ekeyd-1.0.5-r2.ebuild,v 1.1 2009/09/29 12:03:20 flameeyes Exp $
EAPI=2
-inherit multilib
+inherit multilib linux-info
DESCRIPTION="Entropy Key userspace daemon"
HOMEPAGE="http://www.entropykey.co.uk/"
@@ -23,7 +23,16 @@ RDEPEND="dev-lang/lua
DEPEND="${RDEPEND}"
RDEPEND="${RDEPEND}
dev-libs/luasocket
- kernel_linux? ( sys-fs/udev )"
+ kernel_linux? ( sys-fs/udev )
+ usb? ( !kernel_linux? ( sys-apps/usbutils ) )"
+
+CONFIG_CHECK="USB_ACM"
+
+pkg_setup() {
+ if use kernel_linux && ! use usb && linux_config_exists; then
+ check_extra_config
+ fi
+}
src_prepare() {
# - avoid using -Werror;
@@ -33,6 +42,10 @@ src_prepare() {
-e 's:-Werror::' \
-e '/gzip/d' \
daemon/Makefile || die
+
+ # We moved the binaries around
+ sed -i -e 's:$BINPATH/ekey-ulusbd:/usr/libexec/ekey-ulusbd:' \
+ doc/ekeyd-udev || die
}
src_compile() {
@@ -84,8 +97,10 @@ src_install() {
newinitd "${FILESDIR}"/${PN}.init ${PN} || die
if use usb; then
- newinitd "${FILESDIR}"/ekey-ulusbd.init ekey-ulusbd || die
- newconfd "${FILESDIR}"/ekey-ulusbd.conf ekey-ulusbd || die
+ if ! use kernel_linux; then
+ newinitd "${FILESDIR}"/ekey-ulusbd.init ekey-ulusbd || die
+ newconfd "${FILESDIR}"/ekey-ulusbd.conf ekey-ulusbd || die
+ fi
doman daemon/ekey-ulusbd.8 || die
fi
@@ -93,7 +108,11 @@ src_install() {
if use kernel_linux; then
insinto /etc/udev/rules.d
- newins doc/60-UDEKEY01.rules 70-${PN}.rules || die
+ if use usb; then
+ newins doc/60-UDEKEY01-UDS.rules 70-ekey-ulusbd.rules || die
+ else
+ newins doc/60-UDEKEY01.rules 70-${PN}.rules || die
+ fi
exeinto /$(get_libdir)/udev
doexe doc/ekeyd-udev || die
@@ -107,16 +126,29 @@ pkg_postinst() {
elog "The service supports multiplexing if you wish to use multiple"
elog "keys, just symlink /etc/init.d/ekeyd → /etc/init.d/ekeyd.identifier"
elog "and it'll be looking for /etc/init.d/identifier.conf"
+ elog ""
if use usb; then
+ if use kernel_linux; then
+ elog "You're going to use the userland USB daemon, the udev rules"
+ elog "will be used accordingly. If you want to use the CDC driver"
+ elog "please disable the usb USE flag."
+ else
+ elog "You're going to use the userland USB daemon, since your OS"
+ elog "does not support udev, you should start the ekey-ulusbd"
+ elog "service before ekeyd."
+ fi
+ else
+ if use kernel_linux; then
+ elog "Some versions of Linux have a faulty CDC ACM driver that stops"
+ elog "EntropyKey from working properly; please check the compatibility"
+ elog "table at http://www.entropykey.co.uk/download/"
+ else
+ elog "Make sure your operating system supports the CDC ACM driver"
+ elog "or otherwise you won't be able to use the EntropyKey."
+ fi
elog ""
- elog "If you don't want (or can't) use the CDC ACM driver in your"
- elog "kernel, you may use the Userland USB Daemon to access the"
- elog "EntropyKey."
- elog ""
- elog "To do so, make sure to start the ekey-ulusbd service, after"
- elog "having configured /etc/conf.d/ekey-ulusbd."
- elog "This service is also multiplexed so you can run it for any"
- elog "number of keys."
+ elog "If you're unsure about the working state of the CDC ACM driver"
+ elog "enable the usb USE flag and use the userland USB daemon"
fi
}
diff --git a/app-crypt/ekeyd/files/ekey-ulusbd.conf b/app-crypt/ekeyd/files/ekey-ulusbd.conf
index 80bf0c1aec13..1a6100854df8 100644
--- a/app-crypt/ekeyd/files/ekey-ulusbd.conf
+++ b/app-crypt/ekeyd/files/ekey-ulusbd.conf
@@ -1,6 +1,6 @@
# Copyright 2009 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/app-crypt/ekeyd/files/ekey-ulusbd.conf,v 1.1 2009/09/28 18:29:36 flameeyes Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-crypt/ekeyd/files/ekey-ulusbd.conf,v 1.2 2009/09/29 12:03:21 flameeyes Exp $
# The userland USB daemon has to know the USB path of the EntopyKey to
# work properly; in alternative to providing these statically, they
@@ -13,4 +13,4 @@ EKEY_SERIAL=""
#USB_BUS=""
#USB_DEV=""
-SOCKET_PATH="/var/run/ekey.ulusbd.${EKEY_SERIAL}"
+SOCKET_PATH="/var/run/ekey-ulusbd-${EKEY_SERIAL}"
diff --git a/app-crypt/ekeyd/files/ekey-ulusbd.init b/app-crypt/ekeyd/files/ekey-ulusbd.init
index f1ee32bcc54a..8a955c5ecec5 100644
--- a/app-crypt/ekeyd/files/ekey-ulusbd.init
+++ b/app-crypt/ekeyd/files/ekey-ulusbd.init
@@ -1,7 +1,7 @@
#!/sbin/runscript
# Copyright 2009 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/app-crypt/ekeyd/files/ekey-ulusbd.init,v 1.1 2009/09/28 18:29:36 flameeyes Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-crypt/ekeyd/files/ekey-ulusbd.init,v 1.2 2009/09/29 12:03:21 flameeyes Exp $
INSTANCE="${SVCNAME#*.}"
if [ -z "${INSTANCE}" ] || [ "${SVCNAME}" = "ekey-ulusbd" ]; then
@@ -14,14 +14,13 @@ depend() {
start() {
if [ -z ${USB_BUS} ]; then
- local devdir=$(fgrep -l 20df /sys/bus/usb/devices/*/idVendor \
- | xargs -n1 dirname \
- | xargs -I{} fgrep -l 0001 {}/idProduct \
- | xargs -n1 dirname \
- | xargs -I{} fgrep -l ${EKEY_SERIAL} {}/serial \
- | xargs -n1 dirname)
- USB_BUS=$(< ${devdir}/busnum)
- USB_DEV=$(< ${devdir}/devnum)
+ set -- $(lsusb -v -d 20df:0001 | \
+ egrep '(^Bus|iSerial)' | \
+ grep -B1 "${EKEY_SERIAL}" | \
+ head -n 1 | \
+ cut -c 5-7,15-18)
+ USB_BUS=$1
+ USB_DEV=$2
fi
ebegin "Starting EntropyKey Userland USB Daemon"