Skip to content

How to deal with .crt and .key files? #42

Answered by Hakky54
brasta78 asked this question in Q&A
Discussion options

You must be logged in to vote

Hi Brasta78,

Thank you for stopping by and asking questions. The PemUtils.loadIdentityMaterial() method expects either a single file containing the private key and the certificate chain. Or two separate files needs to be supplied. It looks like with your setup you should use a different method.

Can you retry with the following method:

X509ExtendedKeyManager keyManager = PemUtils.loadIdentityMaterial("cert/public.pem", "cert/private.pem");

Replies: 1 comment 4 replies

Comment options

You must be logged in to vote
4 replies
@brasta78
Comment options

@Hakky54
Comment options

@brasta78
Comment options

@Hakky54
Comment options

Answer selected by Hakky54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants