|
|
53c576 |
# HG changeset patch
|
|
|
53c576 |
# User andrew
|
|
|
53c576 |
# Date 1608219816 0
|
|
|
53c576 |
# Thu Dec 17 15:43:36 2020 +0000
|
|
|
53c576 |
# Node ID db5d1b28bfce04352b3a48960bf836f6eb20804b
|
|
|
53c576 |
# Parent a2cfa397150e99b813354226d536eb8509b5850b
|
|
|
53c576 |
RH1906862: Always initialise JavaSecuritySystemConfiguratorAccess
|
|
|
53c576 |
|
|
|
53c576 |
diff --git openjdk.orig/jdk/src/share/classes/java/security/Security.java openjdk/jdk/src/share/classes/java/security/Security.java
|
|
|
53c576 |
--- openjdk.orig/jdk/src/share/classes/java/security/Security.java
|
|
|
53c576 |
+++ openjdk/jdk/src/share/classes/java/security/Security.java
|
|
|
53c576 |
@@ -30,6 +30,8 @@
|
|
|
53c576 |
import java.util.concurrent.ConcurrentHashMap;
|
|
|
53c576 |
import java.io.*;
|
|
|
53c576 |
import java.net.URL;
|
|
|
53c576 |
+import sun.misc.SharedSecrets;
|
|
|
53c576 |
+import sun.misc.JavaSecuritySystemConfiguratorAccess;
|
|
|
53c576 |
import sun.security.util.Debug;
|
|
|
53c576 |
import sun.security.util.PropertyExpander;
|
|
|
53c576 |
|
|
|
53c576 |
@@ -69,6 +71,15 @@
|
|
|
53c576 |
}
|
|
|
53c576 |
|
|
|
53c576 |
static {
|
|
|
53c576 |
+ // Initialise here as used by code with system properties disabled
|
|
|
53c576 |
+ SharedSecrets.setJavaSecuritySystemConfiguratorAccess(
|
|
|
53c576 |
+ new JavaSecuritySystemConfiguratorAccess() {
|
|
|
53c576 |
+ @Override
|
|
|
53c576 |
+ public boolean isSystemFipsEnabled() {
|
|
|
53c576 |
+ return SystemConfigurator.isSystemFipsEnabled();
|
|
|
53c576 |
+ }
|
|
|
53c576 |
+ });
|
|
|
53c576 |
+
|
|
|
53c576 |
// doPrivileged here because there are multiple
|
|
|
53c576 |
// things in initialize that might require privs.
|
|
|
53c576 |
// (the FileInputStream call and the File.exists call,
|
|
|
53c576 |
diff --git openjdk.orig/jdk/src/share/classes/java/security/SystemConfigurator.java openjdk/jdk/src/share/classes/java/security/SystemConfigurator.java
|
|
|
53c576 |
--- openjdk.orig/jdk/src/share/classes/java/security/SystemConfigurator.java
|
|
|
53c576 |
+++ openjdk/jdk/src/share/classes/java/security/SystemConfigurator.java
|
|
|
53c576 |
@@ -39,8 +39,6 @@
|
|
|
53c576 |
import java.util.Properties;
|
|
|
53c576 |
import java.util.regex.Pattern;
|
|
|
53c576 |
|
|
|
53c576 |
-import sun.misc.SharedSecrets;
|
|
|
53c576 |
-import sun.misc.JavaSecuritySystemConfiguratorAccess;
|
|
|
53c576 |
import sun.security.util.Debug;
|
|
|
53c576 |
|
|
|
53c576 |
/**
|
|
|
53c576 |
@@ -66,16 +64,6 @@
|
|
|
53c576 |
|
|
|
53c576 |
private static boolean systemFipsEnabled = false;
|
|
|
53c576 |
|
|
|
53c576 |
- static {
|
|
|
53c576 |
- SharedSecrets.setJavaSecuritySystemConfiguratorAccess(
|
|
|
53c576 |
- new JavaSecuritySystemConfiguratorAccess() {
|
|
|
53c576 |
- @Override
|
|
|
53c576 |
- public boolean isSystemFipsEnabled() {
|
|
|
53c576 |
- return SystemConfigurator.isSystemFipsEnabled();
|
|
|
53c576 |
- }
|
|
|
53c576 |
- });
|
|
|
53c576 |
- }
|
|
|
53c576 |
-
|
|
|
53c576 |
/*
|
|
|
53c576 |
* Invoked when java.security.Security class is initialized, if
|
|
|
53c576 |
* java.security.disableSystemPropertiesFile property is not set and
|