5 kx # copyright:
5 kx # Copyright (C) 1998, 1999 Jean Pierre LeJacq <jplejacq@quoininc.com>
5 kx # Modified 2003 by Martin Pitt <martin@piware.de>
5 kx #
5 kx # Distributed under the GNU GENERAL PUBLIC LICENSE.
5 kx #
5 kx # description:
5 kx # Host configuration of cracklib.
5 kx #
5 kx # Defines location of database used by cracklib as well as files
5 kx # used to create this database. The database location,
5 kx # cracklib_dictpath, is compiled into the utility programs that are
5 kx # part of the cracklib-runtime package and should not be modified.
5 kx # But you should definitely add additional entries to
5 kx # cracklib_dictpath_src. The entries are separated by spaces and
5 kx # should be the fully qualified path to a file of words that
5 kx # passwords should not match. The files may optionally be compressed
5 kx # with gzip.
5 kx #
5 kx # The current configuration supports both the fsstnd 1.2 and fhs 2.0
5 kx # standard location for dictionaries.
5 kx #
5 kx # format:
5 kx # posix shell syntax.
5 kx #
5 kx # reference:
5 kx # 1. http://www.pathname.com/fhs/2.0/fhs-toc.html
5 kx # 2. http://www.pathname.com/fhs/1.2/fsstnd-toc.html
5 kx
5 kx
5 kx # database (do not modify):
5 kx readonly cracklib_dictpath="/var/cache/cracklib/pq_dict"
5 kx
5 kx
5 kx # database sources:
5 kx cracklib_dictpath_src=""
5 kx
5 kx if [ -r "/usr/share/dict/cracklib" ] ; then
5 kx cracklib_dictpath_src="${cracklib_dictpath_src} /usr/share/dict/cracklib"
5 kx fi
5 kx
5 kx if [ -r "/usr/local/share/dict/cracklib" ] ; then
5 kx cracklib_dictpath_src="${cracklib_dictpath_src} /usr/local/share/dict/cracklib"
5 kx fi
5 kx
5 kx for i in /usr/share/dict /usr/dict /usr/local/share/dict /usr/local/dict ; do
5 kx if [ -d $i ] ; then
5 kx for file in $(find $i -type f -print) ; do
5 kx if $(file -z -b ${file} | grep -q "text") ; then
5 kx cracklib_dictpath_src="${cracklib_dictpath_src} ${file}"
5 kx fi
5 kx done
5 kx fi
5 kx done