How To Install cracklib on Rocky Linux 8

In this tutorial we learn how to install cracklib on Rocky Linux 8. cracklib is A password-checking library

Introduction

In this tutorial we learn how to install cracklib on Rocky Linux 8.

What is cracklib

CrackLib tests passwords to determine whether they match certain security-oriented characteristics, with the purpose of stopping users from choosing passwords that are easy to guess. CrackLib performs several tests on passwords and gecos entry and checks those words against the password; it checks for simplistic patterns in passwords; and it checks for the password in a dictionary. CrackLib is actually a library containing a particular C function which is used to check the password, as well as other C functions. CrackLib is not a replacement for a passwd program; it must be used in conjunction with an existing passwd program. Install the cracklib package if you need a program to check users’ passwords to see if they are at least minimally secure. If you install CrackLib, you will also want to install the cracklib-dicts package.

We can use yum or dnf to install cracklib on Rocky Linux 8. In this tutorial we discuss both methods but you only need to choose one of method to install cracklib.

Install cracklib on Rocky Linux 8 Using dnf

Update yum database with dnf using the following command.

sudo dnf makecache --refresh

After updating yum database, We can install cracklib using dnf by running the following command:

sudo dnf -y install cracklib

Install cracklib on Rocky Linux 8 Using yum

Update yum database with yum using the following command.

sudo yum makecache --refresh

After updating yum database, We can install cracklib using yum by running the following command:

sudo yum -y install cracklib

How To Uninstall cracklib on Rocky Linux 8

To uninstall only the cracklib package we can use the following command:

sudo dnf remove cracklib

cracklib Package Contents on Rocky Linux 8

/usr/lib/.build-id
/usr/lib/.build-id/00
/usr/lib/.build-id/00/ca69a68092caf69acedee234f368009a5fdec9
/usr/lib/.build-id/5d
/usr/lib/.build-id/5d/b7d3d47b79e29ad5a3b03f7d471f6dfa68096e
/usr/lib/.build-id/6b
/usr/lib/.build-id/6b/eba1eb5678b0f2352bb84a72f023ae4369f402
/usr/lib/.build-id/85
/usr/lib/.build-id/85/31fafc17920356f47caa181e7d4d2389357a8d
/usr/lib64/libcrack.so.2
/usr/lib64/libcrack.so.2.9.0
/usr/sbin/cracklib-check
/usr/sbin/cracklib-format
/usr/sbin/cracklib-packer
/usr/sbin/cracklib-unpacker
/usr/sbin/create-cracklib-dict
/usr/share/cracklib
/usr/share/cracklib/cracklib.magic
/usr/share/doc/cracklib
/usr/share/doc/cracklib/AUTHORS
/usr/share/doc/cracklib/NEWS
/usr/share/doc/cracklib/README
/usr/share/doc/cracklib/README-LICENSE
/usr/share/doc/cracklib/README-WORDS
/usr/share/licenses/cracklib
/usr/share/licenses/cracklib/COPYING.LIB
/usr/share/locale/as/LC_MESSAGES/cracklib.mo
/usr/share/locale/be/LC_MESSAGES/cracklib.mo
/usr/share/locale/bn_IN/LC_MESSAGES/cracklib.mo
/usr/share/locale/ca/LC_MESSAGES/cracklib.mo
/usr/share/locale/cs/LC_MESSAGES/cracklib.mo
/usr/share/locale/da/LC_MESSAGES/cracklib.mo
/usr/share/locale/de/LC_MESSAGES/cracklib.mo
/usr/share/locale/el/LC_MESSAGES/cracklib.mo
/usr/share/locale/es/LC_MESSAGES/cracklib.mo
/usr/share/locale/eu/LC_MESSAGES/cracklib.mo
/usr/share/locale/fi/LC_MESSAGES/cracklib.mo
/usr/share/locale/fr/LC_MESSAGES/cracklib.mo
/usr/share/locale/gu/LC_MESSAGES/cracklib.mo
/usr/share/locale/he/LC_MESSAGES/cracklib.mo
/usr/share/locale/hi/LC_MESSAGES/cracklib.mo
/usr/share/locale/hu/LC_MESSAGES/cracklib.mo
/usr/share/locale/id/LC_MESSAGES/cracklib.mo
/usr/share/locale/it/LC_MESSAGES/cracklib.mo
/usr/share/locale/ja/LC_MESSAGES/cracklib.mo
/usr/share/locale/kk/LC_MESSAGES/cracklib.mo
/usr/share/locale/kn/LC_MESSAGES/cracklib.mo
/usr/share/locale/ko/LC_MESSAGES/cracklib.mo
/usr/share/locale/lt/LC_MESSAGES/cracklib.mo
/usr/share/locale/ml/LC_MESSAGES/cracklib.mo
/usr/share/locale/mr/LC_MESSAGES/cracklib.mo
/usr/share/locale/nb/LC_MESSAGES/cracklib.mo
/usr/share/locale/nl/LC_MESSAGES/cracklib.mo
/usr/share/locale/or/LC_MESSAGES/cracklib.mo
/usr/share/locale/pa/LC_MESSAGES/cracklib.mo
/usr/share/locale/pl/LC_MESSAGES/cracklib.mo
/usr/share/locale/pt/LC_MESSAGES/cracklib.mo
/usr/share/locale/pt_BR/LC_MESSAGES/cracklib.mo
/usr/share/locale/ru/LC_MESSAGES/cracklib.mo
/usr/share/locale/sk/LC_MESSAGES/cracklib.mo
/usr/share/locale/sl_SI/LC_MESSAGES/cracklib.mo
/usr/share/locale/sq/LC_MESSAGES/cracklib.mo
/usr/share/locale/sv/LC_MESSAGES/cracklib.mo
/usr/share/locale/ta/LC_MESSAGES/cracklib.mo
/usr/share/locale/te/LC_MESSAGES/cracklib.mo
/usr/share/locale/tr/LC_MESSAGES/cracklib.mo
/usr/share/locale/uk/LC_MESSAGES/cracklib.mo
/usr/share/locale/zh_CN/LC_MESSAGES/cracklib.mo
/usr/share/locale/zh_TW/LC_MESSAGES/cracklib.mo
/usr/share/man/man8/cracklib-check.8.gz
/usr/share/man/man8/cracklib-format.8.gz
/usr/share/man/man8/cracklib-packer.8.gz
/usr/share/man/man8/cracklib-unpacker.8.gz
/usr/share/man/man8/create-cracklib-dict.8.gz
/usr/share/man/man8/update-cracklib.8.gz
/usr/lib/.build-id
/usr/lib/.build-id/37
/usr/lib/.build-id/37/f2be19bbd71a2a73ab3354ef0ae51210b7157c
/usr/lib/.build-id/43
/usr/lib/.build-id/43/99317647b48aa6320e7de815eb1c52496f3a65
/usr/lib/.build-id/ab
/usr/lib/.build-id/ab/025ebd9b0ef9ce354e9e92e863a2c5bc9edfbd
/usr/lib/.build-id/b8
/usr/lib/.build-id/b8/eabac5d79ebb4a76a746a0a8a72970e94a50ee
/usr/lib/libcrack.so.2
/usr/lib/libcrack.so.2.9.0
/usr/sbin/cracklib-check
/usr/sbin/cracklib-format
/usr/sbin/cracklib-packer
/usr/sbin/cracklib-unpacker
/usr/sbin/create-cracklib-dict
/usr/share/cracklib
/usr/share/cracklib/cracklib.magic
/usr/share/doc/cracklib
/usr/share/doc/cracklib/AUTHORS
/usr/share/doc/cracklib/NEWS
/usr/share/doc/cracklib/README
/usr/share/doc/cracklib/README-LICENSE
/usr/share/doc/cracklib/README-WORDS
/usr/share/licenses/cracklib
/usr/share/licenses/cracklib/COPYING.LIB
/usr/share/locale/as/LC_MESSAGES/cracklib.mo
/usr/share/locale/be/LC_MESSAGES/cracklib.mo
/usr/share/locale/bn_IN/LC_MESSAGES/cracklib.mo
/usr/share/locale/ca/LC_MESSAGES/cracklib.mo
/usr/share/locale/cs/LC_MESSAGES/cracklib.mo
/usr/share/locale/da/LC_MESSAGES/cracklib.mo
/usr/share/locale/de/LC_MESSAGES/cracklib.mo
/usr/share/locale/el/LC_MESSAGES/cracklib.mo
/usr/share/locale/es/LC_MESSAGES/cracklib.mo
/usr/share/locale/eu/LC_MESSAGES/cracklib.mo
/usr/share/locale/fi/LC_MESSAGES/cracklib.mo
/usr/share/locale/fr/LC_MESSAGES/cracklib.mo
/usr/share/locale/gu/LC_MESSAGES/cracklib.mo
/usr/share/locale/he/LC_MESSAGES/cracklib.mo
/usr/share/locale/hi/LC_MESSAGES/cracklib.mo
/usr/share/locale/hu/LC_MESSAGES/cracklib.mo
/usr/share/locale/id/LC_MESSAGES/cracklib.mo
/usr/share/locale/it/LC_MESSAGES/cracklib.mo
/usr/share/locale/ja/LC_MESSAGES/cracklib.mo
/usr/share/locale/kk/LC_MESSAGES/cracklib.mo
/usr/share/locale/kn/LC_MESSAGES/cracklib.mo
/usr/share/locale/ko/LC_MESSAGES/cracklib.mo
/usr/share/locale/lt/LC_MESSAGES/cracklib.mo
/usr/share/locale/ml/LC_MESSAGES/cracklib.mo
/usr/share/locale/mr/LC_MESSAGES/cracklib.mo
/usr/share/locale/nb/LC_MESSAGES/cracklib.mo
/usr/share/locale/nl/LC_MESSAGES/cracklib.mo
/usr/share/locale/or/LC_MESSAGES/cracklib.mo
/usr/share/locale/pa/LC_MESSAGES/cracklib.mo
/usr/share/locale/pl/LC_MESSAGES/cracklib.mo
/usr/share/locale/pt/LC_MESSAGES/cracklib.mo
/usr/share/locale/pt_BR/LC_MESSAGES/cracklib.mo
/usr/share/locale/ru/LC_MESSAGES/cracklib.mo
/usr/share/locale/sk/LC_MESSAGES/cracklib.mo
/usr/share/locale/sl_SI/LC_MESSAGES/cracklib.mo
/usr/share/locale/sq/LC_MESSAGES/cracklib.mo
/usr/share/locale/sv/LC_MESSAGES/cracklib.mo
/usr/share/locale/ta/LC_MESSAGES/cracklib.mo
/usr/share/locale/te/LC_MESSAGES/cracklib.mo
/usr/share/locale/tr/LC_MESSAGES/cracklib.mo
/usr/share/locale/uk/LC_MESSAGES/cracklib.mo
/usr/share/locale/zh_CN/LC_MESSAGES/cracklib.mo
/usr/share/locale/zh_TW/LC_MESSAGES/cracklib.mo
/usr/share/man/man8/cracklib-check.8.gz
/usr/share/man/man8/cracklib-format.8.gz
/usr/share/man/man8/cracklib-packer.8.gz
/usr/share/man/man8/cracklib-unpacker.8.gz
/usr/share/man/man8/create-cracklib-dict.8.gz
/usr/share/man/man8/update-cracklib.8.gz

References

Summary

In this tutorial we learn how to install cracklib on Rocky Linux 8 using yum and dnf.