I am reading some package files of Ubuntu and find that libc depends on libcrypt1. libcrypt1 contains these files (https://packages.ubuntu.com/focal/amd64/libcrypt1/filelist):
/lib/x86_64-linux-gnu/libcrypt.so.1 /lib/x86_64-linux-gnu/libcrypt.so.1.1.0 /usr/share/doc/libcrypt1/changelog.Debian.gz /usr/share/doc/libcrypt1/copyright
while libcrypto.so (https://packages.ubuntu.com/focal/amd64/libssl1.1/filelist) is installed by libssl, which I think belongs to openssl (correct me if I am wrong)?
So what's the difference between libcrypt.so and libcrypto.so?
I am more familiar with libcrypto.so for which I know it provides some TLS layer functionalites.
What functionality does libcrypt.so provide?
Google doesn't give any reuslts while indicating that libcrypt.so is kinda useless and deprecated?
they're unrelated
libcrypt:
Description-en: libcrypt shared library libxcrypt is a modern library for one-way hashing of passwords. It supports DES, MD5, NTHASH, SUNMD5, SHA-2-256, SHA-2-512, and bcrypt-based password hashes It provides the traditional Unix 'crypt' and 'crypt_r' interfaces, as well as a set of extended interfaces like 'crypt_gensalt'.
symbols provided by libcrypt (at least on my host):
$ nm -D /usr/lib/x86_64-linux-gnu/libcrypt.so | grep ' T ' | awk '{print $3}' | sort -u | xargs
crypt crypt_checksalt crypt_gensalt crypt_gensalt_r crypt_gensalt_ra crypt_gensalt_rn crypt_preferred_method crypt_r crypt_ra crypt_rn encrypt encrypt_r fcrypt setkey setkey_r xcrypt xcrypt_gensalt xcrypt_gensalt_r xcrypt_r
libcrypto is the openssl cryptography routines
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With