Thu, 04 Oct 2012 20:30:05 +0200
Correct out of date build configuration, porting to Solaris 11 network
link infrastructure and new libpcap logic. This additionally allows for
device drivers in subdirectories of /dev. Correct packaged nmap
personalities and signatures to work out of the box. Finally, hack
arpd logic to properly close sockets and quit on TERM by repeating
signaling in the run command script. Sadly, all this fails to correct
the run time behaviour of honeyd which fails to bind to the IP layer.
michael@572 | 1 | ## |
michael@572 | 2 | ## cracklib.spec -- OpenPKG RPM Package Specification |
michael@572 | 3 | ## Copyright (c) 2000-2012 OpenPKG Foundation e.V. <http://openpkg.net/> |
michael@572 | 4 | ## |
michael@572 | 5 | ## Permission to use, copy, modify, and distribute this software for |
michael@572 | 6 | ## any purpose with or without fee is hereby granted, provided that |
michael@572 | 7 | ## the above copyright notice and this permission notice appear in all |
michael@572 | 8 | ## copies. |
michael@572 | 9 | ## |
michael@572 | 10 | ## THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED |
michael@572 | 11 | ## WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF |
michael@572 | 12 | ## MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. |
michael@572 | 13 | ## IN NO EVENT SHALL THE AUTHORS AND COPYRIGHT HOLDERS AND THEIR |
michael@572 | 14 | ## CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, |
michael@572 | 15 | ## SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT |
michael@572 | 16 | ## LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF |
michael@572 | 17 | ## USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND |
michael@572 | 18 | ## ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, |
michael@572 | 19 | ## OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT |
michael@572 | 20 | ## OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF |
michael@572 | 21 | ## SUCH DAMAGE. |
michael@572 | 22 | ## |
michael@572 | 23 | |
michael@572 | 24 | # package information |
michael@572 | 25 | Name: cracklib |
michael@572 | 26 | Summary: Filter Guessable Passwords |
michael@572 | 27 | URL: http://cracklib.sourceforge.net/ |
michael@572 | 28 | Vendor: Alec Muffett et al. |
michael@572 | 29 | Packager: OpenPKG Foundation e.V. |
michael@572 | 30 | Distribution: OpenPKG Community |
michael@572 | 31 | Class: PLUS |
michael@572 | 32 | Group: Security |
michael@572 | 33 | License: Artistic |
michael@572 | 34 | Version: 2.8.19 |
michael@573 | 35 | Release: 20120800 |
michael@572 | 36 | |
michael@572 | 37 | # list of sources |
michael@572 | 38 | Source0: http://switch.dl.sourceforge.net/cracklib/cracklib-%{version}.tar.gz |
michael@572 | 39 | Source1: http://switch.dl.sourceforge.net/cracklib/cracklib-words.gz |
michael@572 | 40 | Source2: ftp://ftp.cerias.purdue.edu/pub/dict/wordlists/computer/common-passwords.txt.gz |
michael@572 | 41 | Source3: ftp://ftp.cerias.purdue.edu/pub/dict/wordlists/computer/Jargon.gz |
michael@572 | 42 | Source4: http://www.freebsd.org/cgi/cvsweb.cgi/~checkout~/src/share/dict/web2 |
michael@572 | 43 | Source5: http://www.freebsd.org/cgi/cvsweb.cgi/~checkout~/src/share/dict/web2a |
michael@572 | 44 | Source6: http://www.freebsd.org/cgi/cvsweb.cgi/~checkout~/src/share/dict/propernames |
michael@572 | 45 | Source7: Makefile |
michael@572 | 46 | |
michael@572 | 47 | # build information |
michael@572 | 48 | BuildPreReq: OpenPKG, openpkg >= 20100101, make |
michael@572 | 49 | PreReq: OpenPKG, openpkg >= 20100101, make |
michael@572 | 50 | |
michael@572 | 51 | %description |
michael@572 | 52 | CrackLib is a library which may be used in a "passwd"-like program. |
michael@572 | 53 | The idea is simple: try to prevent users from choosing passwords |
michael@572 | 54 | that could be guessed by "Crack" by filtering them out, at source. |
michael@572 | 55 | |
michael@572 | 56 | %track |
michael@572 | 57 | prog cracklib = { |
michael@572 | 58 | version = %{version} |
michael@572 | 59 | url = http://sourceforge.net/projects/cracklib/files/ |
michael@572 | 60 | regex = cracklib-(__VER__)\.tar\.gz |
michael@572 | 61 | } |
michael@572 | 62 | |
michael@572 | 63 | %prep |
michael@572 | 64 | %setup -q |
michael@572 | 65 | |
michael@572 | 66 | %build |
michael@572 | 67 | # configure library |
michael@572 | 68 | CC="%{l_cc}" \ |
michael@572 | 69 | CFLAGS="%{l_cflags -O}" \ |
michael@573 | 70 | CPPFLAGS="%{l_cppflags} -D_POSIX_PTHREAD_SEMANTICS" \ |
michael@572 | 71 | ./configure \ |
michael@572 | 72 | --prefix=%{l_prefix} \ |
michael@572 | 73 | --with-default-dict=%{l_prefix}/lib/cracklib/pw_dict \ |
michael@572 | 74 | --without-python \ |
michael@572 | 75 | --disable-shared \ |
michael@572 | 76 | --disable-nls |
michael@572 | 77 | |
michael@572 | 78 | # build library |
michael@573 | 79 | %{l_make} %{l_mflags -O} |
michael@572 | 80 | |
michael@572 | 81 | %install |
michael@572 | 82 | # install library |
michael@572 | 83 | %{l_make} %{l_mflags} install DESTDIR=$RPM_BUILD_ROOT |
michael@572 | 84 | |
michael@572 | 85 | # strip down installation files |
michael@572 | 86 | rm -f $RPM_BUILD_ROOT%{l_prefix}/sbin/create-cracklib-dict |
michael@572 | 87 | rm -f $RPM_BUILD_ROOT%{l_prefix}/share/cracklib/cracklib.magic |
michael@572 | 88 | |
michael@572 | 89 | # install dictionaries |
michael@572 | 90 | mv $RPM_BUILD_ROOT%{l_prefix}/share/cracklib/cracklib-small \ |
michael@572 | 91 | $RPM_BUILD_ROOT%{l_prefix}/share/cracklib/cracklib-small.txt |
michael@572 | 92 | %{l_gzip} -d -c %{SOURCE cracklib-words.gz} \ |
michael@572 | 93 | >$RPM_BUILD_ROOT%{l_prefix}/share/cracklib/cracklib-large.txt |
michael@572 | 94 | %{l_gzip} -d -c %{SOURCE common-passwords.txt.gz} \ |
michael@572 | 95 | >$RPM_BUILD_ROOT%{l_prefix}/share/cracklib/common-passwords.txt |
michael@572 | 96 | %{l_gzip} -d -c %{SOURCE Jargon.gz} \ |
michael@572 | 97 | >$RPM_BUILD_ROOT%{l_prefix}/share/cracklib/jargon-words.txt |
michael@572 | 98 | cp %{SOURCE web2} \ |
michael@572 | 99 | $RPM_BUILD_ROOT%{l_prefix}/share/cracklib/freebsd-web2.txt |
michael@572 | 100 | cp %{SOURCE web2a} \ |
michael@572 | 101 | $RPM_BUILD_ROOT%{l_prefix}/share/cracklib/freebsd-web2a.txt |
michael@572 | 102 | cp %{SOURCE propernames} \ |
michael@572 | 103 | $RPM_BUILD_ROOT%{l_prefix}/share/cracklib/freebsd-propernames.txt |
michael@572 | 104 | |
michael@572 | 105 | # install dictionary generation stuff |
michael@572 | 106 | %{l_shtool} install -c -m 644 %{l_value -s -a} \ |
michael@572 | 107 | %{SOURCE Makefile} $RPM_BUILD_ROOT%{l_prefix}/share/cracklib/ |
michael@572 | 108 | %{l_shtool} mkdir -f -p -m 755 \ |
michael@572 | 109 | $RPM_BUILD_ROOT%{l_prefix}/lib/cracklib |
michael@572 | 110 | |
michael@572 | 111 | # determine installation files |
michael@572 | 112 | %{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT %{l_files_std} |
michael@572 | 113 | |
michael@572 | 114 | %files -f files |
michael@572 | 115 | |
michael@572 | 116 | %clean |
michael@572 | 117 | |
michael@572 | 118 | %post |
michael@573 | 119 | # (re)generate runtime password dictionary |
michael@573 | 120 | ( echo "(Re)Generating runtime password dictionary" |
michael@572 | 121 | ) | %{l_rpmtool} msg -b -t warn |
michael@572 | 122 | ( cd $RPM_INSTALL_PREFIX/share/cracklib && \ |
michael@572 | 123 | $RPM_INSTALL_PREFIX/bin/make |
michael@572 | 124 | ) >/dev/null 2>&1 |
michael@572 | 125 | |
michael@572 | 126 | %preun |
michael@572 | 127 | if [ $1 -eq 0 ]; then |
michael@572 | 128 | rm -f $RPM_INSTALL_PREFIX/share/cracklib/* >/dev/null 2>&1 || true |
michael@572 | 129 | fi |
michael@572 | 130 |