RFR: 8155246: Throw error if default java.security file is missing [v2]
Sean Coffey
coffeys at openjdk.org
Wed Aug 10 14:26:42 UTC 2022
On Wed, 10 Aug 2022 14:03:59 GMT, Alan Bateman <alanb at openjdk.org> wrote:
>> Sean Coffey has updated the pull request incrementally with one additional commit since the last revision:
>>
>> CSR review comments
>
> src/java.base/share/classes/java/security/Security.java line 52:
>
>> 50: * @implNote If the master security properties file is missing, the JDK
>> 51: * implementation will throw an {@code InternalError} when initializing the
>> 52: * {@code Security} class.
>
> Is "master security properties file" the right term here? The only use of "master" in this class seems to be a deprecated method.
>
> I'm also not sure about the word "missing" as there can be many reasons why opening a file may fail, e.g. something changes the permissions or file owner so that it can't be opened for example.
>
> The implNote need not be specific on the exception that is thrown, it could say "will throw an unspecified exception ..."
The opening line of the java.security file denotes it as the "master security properties file". I think it works well but open to suggestions. Maybe we can re-use the terminology from previous paragraph.
Fair point about the "missing" and error clause -- perhaps:
```
@implNote If the file containing the default values of security properties fails to load,
* the JDK implementation will throw an unspecified error when initializing the
* {@code Security} class.
-------------
PR: https://git.openjdk.org/jdk/pull/9747
More information about the security-dev
mailing list