blob: cf86d931a84cc0ed473f7e9e6bc6494adb1bb4ac (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
|
# Copyright 1999-2012 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/sys-auth/skey/skey-1.1.5-r8.ebuild,v 1.2 2012/01/05 18:47:48 ulm Exp $
EAPI=4
inherit flag-o-matic eutils toolchain-funcs
DESCRIPTION="Linux Port of OpenBSD Single-key Password System"
HOMEPAGE="http://www.openbsd.org/faq/faq8.html#SKey"
SRC_URI="mirror://gentoo/${P}.tar.bz2
mirror://gentoo/skey-1.1.5-patches-2.tar.xz"
LICENSE="BSD MIT RSA-MD4 RSA-MD5 BEER-WARE"
SLOT="0"
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86"
IUSE="static-libs"
DEPEND="dev-lang/perl
app-arch/xz-utils"
RDEPEND="dev-lang/perl
sys-libs/cracklib"
src_prepare() {
EPATCH_SUFFIX=patch epatch
}
src_configure() {
tc-export CC
econf --sysconfdir=/etc/skey
}
src_install() {
into /
dolib.so libskey.so{.${PV},.${PV%.*},.${PV%%.*},}
into /usr
dobin skey skeyinit skeyinfo
newbin skeyaudit.sh skeyaudit
newsbin skeyprune.pl skeyprune
dosym skey /usr/bin/otp-md4
dosym skey /usr/bin/otp-md5
dosym skey /usr/bin/otp-sha1
if use static-libs; then
dolib.a libskey.a
gen_usr_ldscript libskey.so
fi
doman skey.1 skeyaudit.1 skeyinfo.1 skeyinit.1 skey.3 skeyprune.8
insinto /usr/include
doins skey.h
keepdir /etc/skey
# only root needs to have access to these files.
fperms go-rx /etc/skey
# skeyinit and skeyinfo must be suid root so users
# can generate their passwords.
fperms u+s,go-r /usr/bin/skeyinit /usr/bin/skeyinfo
dodoc README CHANGES
}
pkg_postinst() {
# do not include /etc/skey/skeykeys in the package, as quickpkg
# may package sensitive information.
# This also fixes the etc-update issue with #64974.
# skeyinit will not function if this file is not present.
touch /etc/skey/skeykeys
# these permissions are applied by the skey system if missing.
chmod 0600 /etc/skey/skeykeys
elog "For an introduction into using s/key authentication, take"
elog "a look at the EXAMPLES section from the skey(1) manpage."
}
|