RFR: 8179503: Java should support GET OCSP calls [v2]

Jamil Nimeh jnimeh at openjdk.java.net
Thu Dec 31 05:28:05 UTC 2020


On Thu, 31 Dec 2020 05:06:02 GMT, Xue-Lei Andrew Fan <xuelei at openjdk.org> wrote:

>> Jamil Nimeh has updated the pull request with a new target base due to a merge or a rebase. The incremental webrev excludes the unrelated changes brought in by the merge/rebase. The pull request contains four additional commits since the last revision:
>> 
>>  - Merge
>>  - Change IO to use readExactlyNBytes method
>>  - Merge
>>  - 8179503: Java should support GET OCSP calls
>
> src/java.base/share/classes/sun/security/provider/certpath/OCSP.java line 275:
> 
>> 273:             contentLength = Integer.MAX_VALUE;
>> 274:         }
>> 275: 
> 
> Is there a leak if the URL connection is not closed?

>From looking at the javadoc for URLConnection, I think the close has to happen on the Input/OutputStreams.  I have the OutputStream inside a try-with-resources block.  But I think I need to do the same with the InputStream so both are closed at the end of the transaction.

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

PR: https://git.openjdk.java.net/jdk/pull/1760



More information about the security-dev mailing list