Blob Blame History Raw
Summary:   Password cracker
Name:      crack
Version:   5.0a
Release:   3%{?dist}
License:   Artistic
Group:     Applications/System
Patch:     %{name}-chris.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildRequires: words

Crack is a password guessing program that is designed to quickly locate
insecurities in Unix (or other) password files by scanning the contents of a
password file, looking for users who have misguidedly chosen a weak login

This package creates a group named "crack" and the Crack program puts all
its results in the /var/lib/crack/run directory, which belongs to that group.
Only users in the crack group can use this package.

%setup -q -n c50a
# Make sure we do not use libdes
rm -rf src/libdes
# select proper crypt routine and related checks
rm -f src/util/elcid.c
ln src/util/elcid.c,bsd src/util/elcid.c
mkdir run bin
# Try not to pollute bin namespace
sed -i -e 's/Reporter/CrackReporter/g' doc/gui.txt manual.html manual.txt
%patch -p1 -b .chris
sed -i 's|/usr/dict/|/usr/share/dict/|g' conf/dictgrps.conf

make XDIR=../../bin XCC=gcc XCFLAGS="$RPM_OPT_FLAGS $C5FLAGS" XLIBS=-lcrypt utils
CRACK_HOME=. ./Crack -makedict

rm -f bin/libc5.a bin/stdlib-cracker
mkdir -p $RPM_BUILD_ROOT/var/lib/crack
cp -a bin conf dict run scripts $RPM_BUILD_ROOT/var/lib/crack
install -D Crack $RPM_BUILD_ROOT%{_bindir}/Crack
install Reporter $RPM_BUILD_ROOT%{_bindir}/CrackReporter


if [ $1 -eq 1 ]; then
    groupadd -r crack >/dev/null 2>&1 || :

%defattr(-, root, root)
%doc LICENCE manual.* doc
%attr(00750, root, crack) %{_bindir}/*
%dir /var/lib/crack/
%attr(02770, root, crack) %dir /var/lib/crack/run/
%attr(02770, root, crack) %dir /var/lib/crack/run/dict/
%attr(00640, root, crack) /var/lib/crack/run/dict/*
%attr(00640, root, crack) /var/lib/crack/run/dict/.dictmade

* Tue Feb 14 2006 Christian Iseli <> 5.0a-3
- rebuild for FE 5

* Fri Dec 23 2005 Christian Iseli <> 5.0a-2
- rebuild with gcc-4.1

* Tue Sep 06 2005 Tom "spot" Callaway <> 5.0a-1
- use words to make a richer dict 1

* Tue Sep 06 2005 Christian Iseli <> 5.0a-0
- Created spec file.