-1

I have implemented a function in Java that generates a self signed certeficate. the output is of type X509Certificate. How can I print my certeficate or how to save it as a readable file ..

Marzo
  • 43
  • 1
  • 2
  • 9

1 Answers1

0

Look into using BouncyCastle API. Here is the link for PEMWriter class javadocs : https://www.bouncycastle.org/docs/pkixdocs1.5on/org/bouncycastle/openssl/PEMWriter.html

Also, found a stackoverflow question dealing with a similar issue: Write x509 certificate into PEM formatted string in java?

Community
  • 1
  • 1
Sanjeev
  • 1,517
  • 1
  • 18
  • 30