I am Trying to configure SSL and got the .pfx file from server team. The Certificate chain length: 2
When i am trying to export the certificate chain using keytool, only
You could do (exemple with java cacert):
for cert in `keytool -list -keystore cacerts -storepass changeit | grep trustedCertEntry | grep -Eo "^[^,]*"`;do `keytool -exportcert -keystore cacerts -alias $cert -file ${cert}.crt <<< $'changeit'` done
That will export all cert in a separated .crt file