Package org.apache.polaris.service.auth
Class PemUtils
java.lang.Object
org.apache.polaris.service.auth.PemUtils
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic KeyPairstatic voidgenerateKeyPairFiles(Path privateFileLocation, Path publicFileLocation) static PrivateKeyreadPrivateKeyFromFile(Path filepath, String algorithm) static PublicKeyreadPublicKeyFromFile(Path filepath, String algorithm) static voidwriteKeyPairFiles(KeyPair keyPair, Path privateFileLocation, Path publicFileLocation)
-
Constructor Details
-
PemUtils
public PemUtils()
-
-
Method Details
-
readPublicKeyFromFile
- Throws:
IOException
-
readPrivateKeyFromFile
- Throws:
IOException
-
generateKeyPair
- Throws:
NoSuchAlgorithmException
-
generateKeyPairFiles
public static void generateKeyPairFiles(Path privateFileLocation, Path publicFileLocation) throws NoSuchAlgorithmException, IOException - Throws:
NoSuchAlgorithmExceptionIOException
-
writeKeyPairFiles
public static void writeKeyPairFiles(KeyPair keyPair, Path privateFileLocation, Path publicFileLocation) throws IOException - Throws:
IOException
-