vivekratnavel commented on a change in pull request #2878:
URL: https://github.com/apache/ozone/pull/2878#discussion_r760451414
##########
File path:
hadoop-hdds/framework/src/main/java/org/apache/hadoop/hdds/security/x509/keys/KeyCodec.java
##########
@@ -406,4 +431,37 @@ private void checkPreconditions(Path basePath) throws
IOException {
}
}
+ /**
+ * Returns the custom private key for custom Root CA setup.
+ * @return PrivateKey.
+ * @throws NoSuchAlgorithmException - On Error.
+ * @throws IOException - On Error.
+ */
+ public PrivateKey readCustomPrivateKey() throws NoSuchAlgorithmException,
+ IOException, UnrecoverableKeyException, CertificateException,
+ KeyStoreException {
+ if (customPrivateKey == null) {
+ loadCustomKeys();
+ }
+
+ return customPrivateKey;
+ }
+
+ /**
+ * Reads a Key from the PEM Encoded Store.
+ *
+ * @param path - Path, Location where the Key file is stored.
+ * @return PrivateKey Object.
+ * @throws IOException - on Error.
+ */
+ protected PKCS8EncodedKeySpec readKey(File path)
Review comment:
Sure
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]