RFR: 8344299: SM cleanup in javax.naming modules

Alan Bateman alanb at openjdk.org
Thu Nov 28 07:54:37 UTC 2024


On Thu, 28 Nov 2024 00:17:43 GMT, Aleksei Efimov <aefimov at openjdk.org> wrote:

> The proposed change cleans-up `SecurityManager`, `doPriviledged`, and `AccessController` usages from `java.naming`, `jdk.naming.rmi` and `jdk.naming.dns` modules.
> 
> One noteworthy change: The `java.naming.rmi.security.manager` JNDI environment property can be used to setup the `SecurityManager`: if the property is added to an environment map the `RegistryContext` attempts to setup the `SecurityManager`. The environment property and related method are removed in this PR. 
> 
> `tier1` - `tier3`, and other non-tiered JNDI tests showed no failures related to this change.

Good cleanup. Maybe for a follow on PR but I assume VersionHelper can be removed. There's been several post JEP 486 removals that mean that createThread and loadClass shouldn't be needed now. Also isSerialDataAllowed could move to Obj, which I think is the only place where we need to know if javaXXX attributes can be deserialised.

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

PR Comment: https://git.openjdk.org/jdk/pull/22421#issuecomment-2505462317


More information about the core-libs-dev mailing list