[b4b71892] | 1 | <?xml version="1.0" encoding="ISO-8859-1"?>
|
---|
[6732c094] | 2 | <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
|
---|
| 3 | "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
|
---|
[b4b71892] | 4 | <!ENTITY % general-entities SYSTEM "../../general.ent">
|
---|
| 5 | %general-entities;
|
---|
| 6 |
|
---|
[1b6c879] | 7 | <!ENTITY cracklib-url "https://github.com/cracklib/cracklib/releases/download">
|
---|
[9912ce81] | 8 |
|
---|
[1b6c879] | 9 | <!ENTITY cracklib-download-http "&cracklib-url;/v&cracklib-version;/cracklib-&cracklib-version;.tar.bz2">
|
---|
[306fb0e] | 10 | <!ENTITY cracklib-download-ftp " ">
|
---|
[056b5965] | 11 | <!ENTITY cracklib-md5sum "a242301bad13421476db8eecbbc9536a">
|
---|
| 12 | <!ENTITY cracklib-size "600 KB">
|
---|
| 13 | <!ENTITY cracklib-buildsize "6.7 MB">
|
---|
| 14 | <!ENTITY cracklib-time "0.1 SBU">
|
---|
[1f4d911] | 15 |
|
---|
[a754697b] | 16 | <!ENTITY crackdict-download "&cracklib-url;/v&cracklib-version;/cracklib-words-&cracklib-version;.bz2">
|
---|
[5cd7055] | 17 | <!ENTITY crackdict-size "6.7 MB">
|
---|
| 18 | <!ENTITY crackdict-md5sum "94e9963e4786294f7fb0f2efd7618551">
|
---|
[b4b71892] | 19 | ]>
|
---|
| 20 |
|
---|
[8b1b2dc7] | 21 | <sect1 id="cracklib" xreflabel="CrackLib-&cracklib-version;">
|
---|
[9623b6e8] | 22 | <?dbhtml filename="cracklib.html"?>
|
---|
| 23 |
|
---|
| 24 | <sect1info>
|
---|
| 25 | <date>$Date$</date>
|
---|
| 26 | </sect1info>
|
---|
| 27 |
|
---|
[8b1b2dc7] | 28 | <title>CrackLib-&cracklib-version;</title>
|
---|
[9623b6e8] | 29 |
|
---|
| 30 | <indexterm zone="cracklib">
|
---|
[8b1b2dc7] | 31 | <primary sortas="a-CrackLib">CrackLib</primary>
|
---|
[9623b6e8] | 32 | </indexterm>
|
---|
| 33 |
|
---|
| 34 | <sect2 role="package">
|
---|
[8b1b2dc7] | 35 | <title>Introduction to CrackLib</title>
|
---|
[9623b6e8] | 36 |
|
---|
[47274444] | 37 | <para>
|
---|
| 38 | The <application>CrackLib</application> package contains a
|
---|
| 39 | library used to enforce strong passwords by comparing user selected
|
---|
| 40 | passwords to words in chosen word lists.
|
---|
| 41 | </para>
|
---|
[9623b6e8] | 42 |
|
---|
[0ddf4e7] | 43 | &lfs112_checked;
|
---|
[5f4181d] | 44 |
|
---|
[9623b6e8] | 45 | <bridgehead renderas="sect3">Package Information</bridgehead>
|
---|
| 46 | <itemizedlist spacing="compact">
|
---|
| 47 | <listitem>
|
---|
[47274444] | 48 | <para>
|
---|
| 49 | Download (HTTP): <ulink url="&cracklib-download-http;"/>
|
---|
| 50 | </para>
|
---|
[9623b6e8] | 51 | </listitem>
|
---|
| 52 | <listitem>
|
---|
[47274444] | 53 | <para>
|
---|
| 54 | Download (FTP): <ulink url="&cracklib-download-ftp;"/>
|
---|
| 55 | </para>
|
---|
[9623b6e8] | 56 | </listitem>
|
---|
| 57 | <listitem>
|
---|
[47274444] | 58 | <para>
|
---|
| 59 | Download MD5 sum: &cracklib-md5sum;
|
---|
| 60 | </para>
|
---|
[9623b6e8] | 61 | </listitem>
|
---|
| 62 | <listitem>
|
---|
[47274444] | 63 | <para>
|
---|
| 64 | Download size: &cracklib-size;
|
---|
| 65 | </para>
|
---|
[9623b6e8] | 66 | </listitem>
|
---|
| 67 | <listitem>
|
---|
[47274444] | 68 | <para>
|
---|
| 69 | Estimated disk space required: &cracklib-buildsize;
|
---|
| 70 | </para>
|
---|
[9623b6e8] | 71 | </listitem>
|
---|
| 72 | <listitem>
|
---|
[47274444] | 73 | <para>
|
---|
| 74 | Estimated build time: &cracklib-time;
|
---|
| 75 | </para>
|
---|
[9623b6e8] | 76 | </listitem>
|
---|
| 77 | </itemizedlist>
|
---|
| 78 |
|
---|
| 79 | <bridgehead renderas="sect3">Additional Downloads</bridgehead>
|
---|
[8f1699f2] | 80 | <itemizedlist spacing="compact">
|
---|
[9623b6e8] | 81 | <listitem>
|
---|
[47274444] | 82 | <para>
|
---|
| 83 | Recommended word list for English-speaking countries (size:
|
---|
| 84 | &crackdict-size;; md5sum: &crackdict-md5sum;):
|
---|
| 85 | <ulink url="&crackdict-download;"/>
|
---|
| 86 | </para>
|
---|
[22861b3] | 87 | </listitem>
|
---|
[9623b6e8] | 88 | </itemizedlist>
|
---|
| 89 |
|
---|
[47274444] | 90 | <para>
|
---|
| 91 | There are additional word lists available for download, e.g., from
|
---|
[cd29bc9] | 92 | <ulink url="https://wiki.skullsecurity.org/index.php/Passwords"/>.
|
---|
[47274444] | 93 | <application>CrackLib</application> can utilize as many, or as few word
|
---|
| 94 | lists you choose to install.
|
---|
| 95 | </para>
|
---|
[62494cc] | 96 |
|
---|
[22861b3] | 97 | <important>
|
---|
[47274444] | 98 | <para>
|
---|
| 99 | Users tend to base their passwords on regular words of the spoken
|
---|
| 100 | language, and crackers know that. <application>CrackLib</application>
|
---|
| 101 | is intended to filter out such bad passwords at the source using a
|
---|
| 102 | dictionary created from word lists. To accomplish this, the word
|
---|
| 103 | list(s) for use with <application>CrackLib</application> must be an
|
---|
| 104 | exhaustive list of words and word-based keystroke combinations likely
|
---|
| 105 | to be chosen by users of the system as (guessable) passwords.
|
---|
| 106 | </para>
|
---|
| 107 |
|
---|
| 108 | <para>
|
---|
| 109 | The default word list recommended above for downloading mostly
|
---|
| 110 | satisfies this role in English-speaking countries. In other situations,
|
---|
| 111 | it may be necessary to download (or even create) additional word lists.
|
---|
| 112 | </para>
|
---|
| 113 |
|
---|
| 114 | <para>
|
---|
| 115 | Note that word lists suitable for spell-checking are not usable
|
---|
| 116 | as <application>CrackLib</application> word lists in countries with
|
---|
| 117 | non-Latin based alphabets, because of <quote>word-based keystroke
|
---|
| 118 | combinations</quote> that make bad passwords.
|
---|
| 119 | </para>
|
---|
[22861b3] | 120 | </important>
|
---|
[5156197] | 121 |
|
---|
[3597eb6] | 122 | <para condition="html" role="usernotes">User Notes:
|
---|
[8f1699f2] | 123 | <ulink url="&blfs-wiki;/cracklib"/>
|
---|
| 124 | </para>
|
---|
[9623b6e8] | 125 | </sect2>
|
---|
| 126 |
|
---|
| 127 | <sect2 role="installation">
|
---|
[8b1b2dc7] | 128 | <title>Installation of CrackLib</title>
|
---|
[4f65b2f] | 129 |
|
---|
[47274444] | 130 | <para>
|
---|
| 131 | Install <application>CrackLib</application> by running the following
|
---|
| 132 | commands:
|
---|
| 133 | </para>
|
---|
[b4b71892] | 134 |
|
---|
[4b3110c8] | 135 | <screen><userinput>autoreconf -fiv &&
|
---|
[806e763] | 136 |
|
---|
[fb3a93b3] | 137 | PYTHON=python3 \
|
---|
[806e763] | 138 | ./configure --prefix=/usr \
|
---|
| 139 | --disable-static \
|
---|
[2eb2948] | 140 | --with-default-dict=/usr/lib/cracklib/pw_dict &&
|
---|
[8b1b2dc7] | 141 | make</userinput></screen>
|
---|
[b4b71892] | 142 |
|
---|
[47274444] | 143 | <para>
|
---|
| 144 | Now, as the <systemitem class="username">root</systemitem> user:
|
---|
| 145 | </para>
|
---|
[9623b6e8] | 146 |
|
---|
[2eb2948] | 147 | <screen role="root"><userinput>make install</userinput></screen>
|
---|
[22861b3] | 148 |
|
---|
[47274444] | 149 | <para>
|
---|
| 150 | Issue the following commands as the
|
---|
| 151 | <systemitem class="username">root</systemitem> user to install the
|
---|
| 152 | recommended word list and create the <application>CrackLib</application>
|
---|
| 153 | dictionary. Other word lists (text based, one word per line) can also be
|
---|
| 154 | used by simply installing them into
|
---|
| 155 | <filename class="directory">/usr/share/dict</filename> and adding them
|
---|
| 156 | to the <command>create-cracklib-dict</command> command.
|
---|
| 157 | </para>
|
---|
[22861b3] | 158 |
|
---|
[5cd7055] | 159 | <screen role="root"><userinput>install -v -m644 -D ../cracklib-words-&cracklib-version;.bz2 \
|
---|
| 160 | /usr/share/dict/cracklib-words.bz2 &&
|
---|
[806e763] | 161 |
|
---|
[5cd7055] | 162 | bunzip2 -v /usr/share/dict/cracklib-words.bz2 &&
|
---|
[efd93087] | 163 | ln -v -sf cracklib-words /usr/share/dict/words &&
|
---|
| 164 | echo $(hostname) >> /usr/share/dict/cracklib-extra-words &&
|
---|
[2eb2948] | 165 | install -v -m755 -d /usr/lib/cracklib &&
|
---|
[806e763] | 166 |
|
---|
| 167 | create-cracklib-dict /usr/share/dict/cracklib-words \
|
---|
[efd93087] | 168 | /usr/share/dict/cracklib-extra-words</userinput></screen>
|
---|
[8b1b2dc7] | 169 |
|
---|
[47274444] | 170 | <para>
|
---|
| 171 | If desired, check the proper operation of the library as an
|
---|
| 172 | unprivileged user by issuing the following command:
|
---|
| 173 | </para>
|
---|
[a4440544] | 174 |
|
---|
[e7d4e823] | 175 | <screen remap="test"><userinput>make test</userinput></screen>
|
---|
[9623b6e8] | 176 |
|
---|
[c6bdcb0] | 177 | <important>
|
---|
[47274444] | 178 | <para>
|
---|
| 179 | If you are installing <application>CrackLib</application> after
|
---|
| 180 | your LFS system has been completed and you have the
|
---|
| 181 | <application>Shadow</application> package installed, you must
|
---|
| 182 | reinstall <xref linkend="shadow"/> if you wish to provide strong
|
---|
| 183 | password support on your system. If you are now going to install the
|
---|
| 184 | <xref linkend="linux-pam"/> package, you may disregard this note as
|
---|
| 185 | <application>Shadow</application> will be reinstalled after the
|
---|
| 186 | <application>Linux-PAM</application> installation.
|
---|
| 187 | </para>
|
---|
[c6bdcb0] | 188 | </important>
|
---|
| 189 |
|
---|
[9623b6e8] | 190 | </sect2>
|
---|
| 191 |
|
---|
| 192 | <sect2 role="commands">
|
---|
| 193 | <title>Command Explanations</title>
|
---|
| 194 |
|
---|
[47274444] | 195 | <para>
|
---|
| 196 | <command>sed -i '/skipping/d' util/packer.c</command>:
|
---|
| 197 | Remove a meaningless warning.
|
---|
| 198 | </para>
|
---|
[806e763] | 199 |
|
---|
[fb3a93b3] | 200 | <para>
|
---|
| 201 | <command>autoreconf -fiv</command>: The configure script shipped with
|
---|
| 202 | the package is too old to get the right version string of Python
|
---|
| 203 | 3.10 or later. This command regenerates it with a more recent version
|
---|
| 204 | of autotools, which fixes the issue.
|
---|
| 205 | </para>
|
---|
| 206 |
|
---|
[0f0dc82] | 207 | <para>
|
---|
| 208 | <envar>PYTHON=python3</envar>: This forces the installation of
|
---|
| 209 | python bindings for Python 3, even if Python 2 is installed.
|
---|
| 210 | </para>
|
---|
[fb3a93b3] | 211 | <!-- fixed by autoreconf
|
---|
[0f0dc82] | 212 | <para>
|
---|
| 213 | <envar>CPPFLAGS=-I/usr/include/python&python3-majorver;</envar>:
|
---|
| 214 | This works around an issue caused by incorrect usage of Python 3
|
---|
| 215 | headers.
|
---|
| 216 | </para>
|
---|
[fb3a93b3] | 217 | -->
|
---|
[47274444] | 218 | <para>
|
---|
| 219 | <parameter>--with-default-dict=/lib/cracklib/pw_dict</parameter>:
|
---|
| 220 | This parameter forces the installation of the
|
---|
| 221 | <application>CrackLib</application> dictionary to the
|
---|
| 222 | <filename class="directory">/lib</filename> hierarchy.
|
---|
| 223 | </para>
|
---|
[8f1699f2] | 224 |
|
---|
| 225 | <xi:include xmlns:xi="http://www.w3.org/2001/XInclude"
|
---|
| 226 | href="../../xincludes/static-libraries.xml"/>
|
---|
[8b1b2dc7] | 227 |
|
---|
[47274444] | 228 | <para>
|
---|
| 229 | <command>install -v -m644 -D ...</command>: This command creates the
|
---|
| 230 | <filename class="directory">/usr/share/dict</filename> directory (if it
|
---|
| 231 | doesn't already exist) and installs the compressed word list there.
|
---|
| 232 | </para>
|
---|
| 233 |
|
---|
| 234 | <para>
|
---|
| 235 | <command>ln -v -s cracklib-words /usr/share/dict/words</command>: The
|
---|
| 236 | word list is linked to <filename>/usr/share/dict/words</filename> as
|
---|
| 237 | historically, <filename>words</filename> is the primary word list in the
|
---|
| 238 | <filename class="directory">/usr/share/dict</filename> directory. Omit
|
---|
| 239 | this command if you already have a
|
---|
| 240 | <filename>/usr/share/dict/words</filename> file installed on your system.
|
---|
| 241 | </para>
|
---|
| 242 |
|
---|
| 243 | <para>
|
---|
| 244 | <command>echo $(hostname) >>...</command>: The value of
|
---|
| 245 | <command>hostname</command> is echoed to a file called
|
---|
| 246 | <filename>cracklib-extra-words</filename>. This extra file is intended
|
---|
| 247 | to be a site specific list which includes easy to guess passwords such
|
---|
| 248 | as company or department names, user names, product names, computer
|
---|
| 249 | names, domain names, etc.
|
---|
| 250 | </para>
|
---|
| 251 |
|
---|
| 252 | <para>
|
---|
| 253 | <command>create-cracklib-dict ...</command>: This command creates the
|
---|
| 254 | <application>CrackLib</application> dictionary from the word lists.
|
---|
| 255 | Modify the command to add any additional word lists you have installed.
|
---|
| 256 | </para>
|
---|
[9623b6e8] | 257 |
|
---|
| 258 | </sect2>
|
---|
| 259 |
|
---|
| 260 | <sect2 role="content">
|
---|
| 261 | <title>Contents</title>
|
---|
| 262 |
|
---|
| 263 | <segmentedlist>
|
---|
| 264 | <segtitle>Installed Programs</segtitle>
|
---|
| 265 | <segtitle>Installed Libraries</segtitle>
|
---|
[d80152af] | 266 | <segtitle>Installed Directories</segtitle>
|
---|
[9623b6e8] | 267 |
|
---|
| 268 | <seglistitem>
|
---|
[8b1b2dc7] | 269 | <seg>cracklib-check, cracklib-format, cracklib-packer,
|
---|
| 270 | cracklib-unpacker and create-cracklib-dict</seg>
|
---|
[d456f78c] | 271 |
|
---|
[0f0dc82] | 272 | <seg>libcrack.so and the _cracklib.so
|
---|
| 273 | (<application>Python</application> module)</seg>
|
---|
[0d7900a] | 274 |
|
---|
[1976445] | 275 | <seg>/lib/cracklib, /usr/share/dict and /usr/share/cracklib</seg>
|
---|
[9623b6e8] | 276 | </seglistitem>
|
---|
| 277 | </segmentedlist>
|
---|
| 278 |
|
---|
| 279 | <variablelist>
|
---|
| 280 | <bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
| 281 | <?dbfo list-presentation="list"?>
|
---|
| 282 | <?dbhtml list-presentation="table"?>
|
---|
| 283 |
|
---|
[efd93087] | 284 | <varlistentry id="cracklib-check">
|
---|
| 285 | <term><command>cracklib-check</command></term>
|
---|
| 286 | <listitem>
|
---|
[47274444] | 287 | <para>
|
---|
[4c24eb0a] | 288 | is used to determine if a password is strong
|
---|
[47274444] | 289 | </para>
|
---|
[efd93087] | 290 | <indexterm zone="cracklib cracklib-check">
|
---|
| 291 | <primary sortas="b-cracklib-check">cracklib-check</primary>
|
---|
| 292 | </indexterm>
|
---|
| 293 | </listitem>
|
---|
| 294 | </varlistentry>
|
---|
| 295 |
|
---|
[c2de366] | 296 | <varlistentry id="cracklib-format">
|
---|
| 297 | <term><command>cracklib-format</command></term>
|
---|
| 298 | <listitem>
|
---|
[47274444] | 299 | <para>
|
---|
| 300 | is used to format text files (lowercases all words,
|
---|
[4c24eb0a] | 301 | removes control characters and sorts the lists)
|
---|
[47274444] | 302 | </para>
|
---|
[c2de366] | 303 | <indexterm zone="cracklib cracklib-format">
|
---|
| 304 | <primary sortas="b-cracklib-format">cracklib-format</primary>
|
---|
| 305 | </indexterm>
|
---|
| 306 | </listitem>
|
---|
| 307 | </varlistentry>
|
---|
| 308 |
|
---|
| 309 | <varlistentry id="cracklib-packer">
|
---|
| 310 | <term><command>cracklib-packer</command></term>
|
---|
| 311 | <listitem>
|
---|
[47274444] | 312 | <para>
|
---|
[4c24eb0a] | 313 | creates a database with words read from standard input
|
---|
[47274444] | 314 | </para>
|
---|
[c2de366] | 315 | <indexterm zone="cracklib cracklib-packer">
|
---|
| 316 | <primary sortas="b-cracklib-packer">cracklib-packer</primary>
|
---|
| 317 | </indexterm>
|
---|
| 318 | </listitem>
|
---|
| 319 | </varlistentry>
|
---|
| 320 |
|
---|
| 321 | <varlistentry id="cracklib-unpacker">
|
---|
| 322 | <term><command>cracklib-unpacker</command></term>
|
---|
| 323 | <listitem>
|
---|
[47274444] | 324 | <para>
|
---|
[4c24eb0a] | 325 | displays on standard output the database specified
|
---|
[47274444] | 326 | </para>
|
---|
[c2de366] | 327 | <indexterm zone="cracklib cracklib-packer">
|
---|
| 328 | <primary sortas="b-cracklib-packer">cracklib-packer</primary>
|
---|
| 329 | </indexterm>
|
---|
| 330 | </listitem>
|
---|
| 331 | </varlistentry>
|
---|
| 332 |
|
---|
[8b1b2dc7] | 333 | <varlistentry id="create-cracklib-dict">
|
---|
[0170790e] | 334 | <term><command>create-cracklib-dict</command></term>
|
---|
[8b1b2dc7] | 335 | <listitem>
|
---|
[47274444] | 336 | <para>
|
---|
| 337 | is used to create the <application>CrackLib</application>
|
---|
[4c24eb0a] | 338 | dictionary from the given word list(s)
|
---|
[47274444] | 339 | </para>
|
---|
[8b1b2dc7] | 340 | <indexterm zone="cracklib create-cracklib-dict">
|
---|
| 341 | <primary sortas="b-create-cracklib-dict">create-cracklib-dict</primary>
|
---|
| 342 | </indexterm>
|
---|
| 343 | </listitem>
|
---|
| 344 | </varlistentry>
|
---|
| 345 |
|
---|
[9623b6e8] | 346 | <varlistentry id="libcrack">
|
---|
[8f1699f2] | 347 | <term><filename class="libraryfile">libcrack.so</filename></term>
|
---|
[9623b6e8] | 348 | <listitem>
|
---|
[47274444] | 349 | <para>
|
---|
| 350 | provides a fast dictionary lookup method for strong
|
---|
[4c24eb0a] | 351 | password enforcement
|
---|
[47274444] | 352 | </para>
|
---|
[9623b6e8] | 353 | <indexterm zone="cracklib libcrack">
|
---|
[d456f78c] | 354 | <primary sortas="c-libcrack">libcrack.so</primary>
|
---|
[9623b6e8] | 355 | </indexterm>
|
---|
| 356 | </listitem>
|
---|
| 357 | </varlistentry>
|
---|
| 358 |
|
---|
| 359 | </variablelist>
|
---|
| 360 |
|
---|
| 361 | </sect2>
|
---|
[fa48bf3] | 362 |
|
---|
| 363 | </sect1>
|
---|