-
Notifications
You must be signed in to change notification settings - Fork 6.2k
8344039: Remove security manager dependency in java.time #22042
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
8344039: Remove security manager dependency in java.time #22042
Conversation
Co-authored-by: Sean Mullan <[email protected]> Co-authored-by: Alan Bateman <[email protected]> Co-authored-by: Weijun Wang <[email protected]> Co-authored-by: Aleksei Efimov <[email protected]> Co-authored-by: Brian Burkhalter <[email protected]> Co-authored-by: Daniel Fuchs <[email protected]> Co-authored-by: Harshitha Onkar <[email protected]> Co-authored-by: Joe Wang <[email protected]> Co-authored-by: Jorn Vernee <[email protected]> Co-authored-by: Justin Lu <[email protected]> Co-authored-by: Kevin Walls <[email protected]>> Co-authored-by: Lance Andersen <[email protected]> Co-authored-by: Naoto Sato <[email protected]> Co-authored-by: Roger Riggs <[email protected]> Co-authored-by: Brent Christian <[email protected]>
…java, not useful without SM
setInitialContextFactoryBuilder and setObjectFactoryBuilder methods in javax.naming.spi.NamingManager.
permission cannot be used anymore to control access.
…sion checks of the Class.getNestHost and getNestMembers methods, which no longer apply.
…ested by other tests
…ava, useless without SM
ModuleDescriptor.location().
…attacker to create new instances
…Class<?> clazz, int which)
|
The parent pull request that this pull request depends on has now been integrated and the target branch of this pull request has been updated. This means that changes from the dependent pull request can start to show up as belonging to this pull request, which may be confusing for reviewers. To remedy this situation, simply merge the latest changes from the new target branch into this pull request by running commands similar to these in the local repository for your personal fork: git checkout 8344039-sm-cleanup-java-time
git fetch https://git.openjdk.org/jdk.git master
git merge FETCH_HEAD
# if there are conflicts, follow the instructions given by git merge
git commit -m "Merge master"
git push |
|
@RogerRiggs this pull request can not be integrated into git checkout 8344039-sm-cleanup-java-time
git fetch https://git.openjdk.org/jdk.git master
git merge FETCH_HEAD
# resolve conflicts and follow the instructions given by git merge
git commit -m "Merge master"
git push |
|
|
Webrevs
|
| static { | ||
| // if the property java.time.zone.DefaultZoneRulesProvider is | ||
| // set then its value is the class name of the default provider | ||
| @SuppressWarnings("removal") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should this SuppressWarnings be removed?
ServiceLoader configuration exceptions (in a static initialization) are rethrown as Error. Remove dependency on SecurityException thrown by ServiceLoader (as obsolete)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lines 171-172:
if (ex.getCause() instanceof SecurityException) {
continue; // ignore the security exception, try the next provider
}
You may be able to remove this code, but may be better to leave it as-is for now until the SL code has been checked for cleanup.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The SL changes are in JDK-8344011.
|
The PR description above seems to be copied from the serialization PR. |
LanceAndersen
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me Roger
naotoj
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
|
/integrate |
|
Going to push as commit 5ac330b.
Your commit was automatically rebased without conflicts. |
|
@RogerRiggs Pushed as commit 5ac330b. 💡 You may see a message that your pull request was closed with unmerged commits. This can be safely ignored. |
After JDK-8338411, java.time implementation dependencies on doPriviledged and AccessController are removed.
Some refactoring to cleanup the remaining code is expected.
Progress
Issue
Reviewers
Reviewing
Using
gitCheckout this PR locally:
$ git fetch https://git.openjdk.org/jdk.git pull/22042/head:pull/22042$ git checkout pull/22042Update a local copy of the PR:
$ git checkout pull/22042$ git pull https://git.openjdk.org/jdk.git pull/22042/headUsing Skara CLI tools
Checkout this PR locally:
$ git pr checkout 22042View PR using the GUI difftool:
$ git pr show -t 22042Using diff file
Download this PR as a diff file:
https://git.openjdk.org/jdk/pull/22042.diff
Using Webrev
Link to Webrev Comment