It's telling you that you need to install libcrypt.so.
You can check with ldd $(type -p chef)
which lists the shared libraries needed by chef. Since chef makes use of functions in libcrypt.so, and you don't have it installed, Chef can't work.
On Ubuntu, one would find the package to install (to obtain libcrypt.so) with:
dpkg -S libcrypt.so
but you didn't let us know which distribution you're using.
If using Linux/AWS/Redhat, try this instead:
sudo yum update
sudo yum install glibc
Now search for library
find / -name "libcrypt.so.1" 2>/dev/null
If the find command shows nothing, this means "libcrypt.so.1" is still missing. Download and install it manually by,
yum provides "*/libcrypt.so.1"
yum install "*/libcrypt.so.1"
Reference:
https://unix.stackexchange.com/questions/746042/error-while-generating-cookbook-missing-shared-library-libcrypt-so-1