RFR: 8329251: Print custom truststore/ keystore name [v13]

Prasadrao Koppula pkoppula at openjdk.org
Fri Dec 6 12:20:38 UTC 2024


On Fri, 6 Dec 2024 11:14:53 GMT, Alan Bateman <alanb at openjdk.org> wrote:

> > > Would it possible to list down the API entry points where you want map the InputStream back to its source? I assume methods such as KeyStore.getInstance(File file, ..) are not a concern, is it the load(InputStream,password) method?
> > 
> > 
> > We currently do not have any mechanism to map the InputStream back to its source. Instead, the InputStream is stored, and the caller methods access it indirectly via the KeyStore object.
> 
> Sure, but the question I was asking is which APIs are providing the InputStream that you want to re-map back to its source. Would it be possible to enumerate?

This PR is focused solely on the load(InputStream, password) method. APIs like KeyStore.getInstance(File file, ..) are not currently handled. Would you like me to update the PR to include handling for those APIs as well?
  
> > In this PR, we are specifically focusing on FileInputStream and handling the inner object from FilterInputStream. This approach is based on its common usage pattern. Additionally, I have not encountered any use cases where the keystore path is provided via other types of InputStreams.
> 
> I think the question that we have to ponder is whether FIS/FOS/RAF/FC should have APIs to get file path, there are several discussion points there.
 
Got it. However, I have not encountered any use cases where FileOutputStream (FOS), RandomAccessFile (RAF), or FileChannel (FC) are used with KeyStore. Shall we focus exclusively on FileInputStream (FIS) in this PR?

-------------

PR Comment: https://git.openjdk.org/jdk/pull/20414#issuecomment-2523095600


More information about the core-libs-dev mailing list