What is the equivalent of the unix c_rehash / script command in Linux?
I am following the instructions on how to import the certificate with the entire chain into the keystore . The problem I'm running into is that I don't have c_rehash on my system:
user@hostanme$ c_rehash ./certs
-bash: c_rehash: command not found
I found - subject_hash variant of openssl x509 , but I'm not sure how to use it to replicate any c_rehash.
How can I hash the certificates directory without the c_rehash / script command?
+3
source to share
2 answers
user @hostanme $ c_rehash. / certs
- bash: c_rehash: command not found
You either need to install OpenSSL (developer version maybe), or you need to put its directory bin/
in the path:
$ find /usr -iname c_rehash
/usr/bin/c_rehash
/usr/local/ssl/darwin/bin/c_rehash
/usr/local/ssl/macosx-x64/bin/c_rehash
/usr/local/ssl/macosx-x86/bin/c_rehash
And make sure you are using the correct one. If I remember correctly, OpenSSL 0.9.8 uses MD5 and OpenSSL 1.0.0 and above uses SHA1.
+1
source to share