Skip to content

Commit

Permalink
Merge master jdk8u392-b08 into openj9-staging
Browse files Browse the repository at this point in the history
Conflicts:
	jdk/src/share/classes/sun/security/ec/ECPrivateKeyImpl.java
	jdk/src/share/classes/sun/security/ec/ECPublicKeyImpl.java
	jdk/src/share/classes/sun/security/rsa/RSAPublicKeyImpl.java

Signed-off-by: Jason Feng <fengj@ca.ibm.com>
  • Loading branch information
JasonFengJ9 committed Oct 18, 2023
2 parents a341bc4 + e4b8974 commit bd94a08
Show file tree
Hide file tree
Showing 75 changed files with 1,959 additions and 595 deletions.
69 changes: 61 additions & 8 deletions THIRD_PARTY_README
Original file line number Diff line number Diff line change
Expand Up @@ -1472,7 +1472,7 @@ included with JDK 8 and OpenJDK 8 source distributions.

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

%% This notice is provided with respect to libpng 1.6.37, which may be
%% This notice is provided with respect to libpng 1.6.39, which may be
included with JRE 8, JDK 8, and OpenJDK 8.

--- begin of LICENSE ---
Expand All @@ -1483,11 +1483,11 @@ COPYRIGHT NOTICE, DISCLAIMER, and LICENSE
PNG Reference Library License version 2
---------------------------------------

* Copyright (c) 1995-2019 The PNG Reference Library Authors.
* Copyright (c) 2018-2019 Cosmin Truta.
* Copyright (c) 2000-2002, 2004, 2006-2018 Glenn Randers-Pehrson.
* Copyright (c) 1996-1997 Andreas Dilger.
* Copyright (c) 1995-1996 Guy Eric Schalnat, Group 42, Inc.
Copyright (c) 1995-2022 The PNG Reference Library Authors.
Copyright (c) 2018-2022 Cosmin Truta
Copyright (c) 1998-2018 Glenn Randers-Pehrson
Copyright (c) 1996-1997 Andreas Dilger
Copyright (c) 1995-1996 Guy Eric Schalnat, Group 42, Inc.

The software is supplied "as is", without warranty of any kind,
express or implied, including, without limitation, the warranties
Expand Down Expand Up @@ -1614,10 +1614,10 @@ be appreciated.

TRADEMARK:

The name "libpng" has not been registered by the Copyright owner
The name "libpng" has not been registered by the Copyright owners
as a trademark in any jurisdiction. However, because libpng has
been distributed and maintained world-wide, continually since 1995,
the Copyright owner claims "common-law trademark protection" in any
the Copyright owners claim "common-law trademark protection" in any
jurisdiction where common-law trademark is recognized.

OSI CERTIFICATION:
Expand All @@ -1639,6 +1639,59 @@ Glenn Randers-Pehrson
glennrp at users.sourceforge.net
July 15, 2018

AUTHORS File Information:

PNG REFERENCE LIBRARY AUTHORS
=============================

This is the list of PNG Reference Library ("libpng") Contributing
Authors, for copyright and licensing purposes.

* Andreas Dilger
* Cosmin Truta
* Dave Martindale
* Eric S. Raymond
* Gilles Vollant
* Glenn Randers-Pehrson
* Greg Roelofs
* Guy Eric Schalnat
* James Yu
* John Bowler
* Kevin Bracey
* Magnus Holmgren
* Mandar Sahastrabuddhe
* Mans Rullgard
* Matt Sarett
* Mike Klein
* Pascal Massimino
* Paul Schmidt
* Qiang Zhou
* Sam Bushell
* Samuel Williams
* Simon-Pierre Cadieux
* Tim Wegner
* Tom Lane
* Tom Tanner
* Vadim Barkov
* Willem van Schaik
* Zhijie Liang
* Arm Holdings
- Richard Townsend
* Google Inc.
- Dan Field
- Leon Scroggins III
- Matt Sarett
- Mike Klein
- Sami Boukortt

The build projects, the build scripts, the test scripts, and other
files in the "ci", "projects", "scripts" and "tests" directories, have
other copyright owners, but are released under the libpng license.

Some files in the "contrib" directory, and some tools-generated files
that are distributed with libpng, have other copyright owners, and are
released under other open source licenses.

--- end of LICENSE ---

-------------------------------------------------------------------------------
Expand Down
69 changes: 61 additions & 8 deletions corba/THIRD_PARTY_README
Original file line number Diff line number Diff line change
Expand Up @@ -1472,7 +1472,7 @@ included with JDK 8 and OpenJDK 8 source distributions.

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

%% This notice is provided with respect to libpng 1.6.37, which may be
%% This notice is provided with respect to libpng 1.6.39, which may be
included with JRE 8, JDK 8, and OpenJDK 8.

--- begin of LICENSE ---
Expand All @@ -1483,11 +1483,11 @@ COPYRIGHT NOTICE, DISCLAIMER, and LICENSE
PNG Reference Library License version 2
---------------------------------------

* Copyright (c) 1995-2019 The PNG Reference Library Authors.
* Copyright (c) 2018-2019 Cosmin Truta.
* Copyright (c) 2000-2002, 2004, 2006-2018 Glenn Randers-Pehrson.
* Copyright (c) 1996-1997 Andreas Dilger.
* Copyright (c) 1995-1996 Guy Eric Schalnat, Group 42, Inc.
Copyright (c) 1995-2022 The PNG Reference Library Authors.
Copyright (c) 2018-2022 Cosmin Truta
Copyright (c) 1998-2018 Glenn Randers-Pehrson
Copyright (c) 1996-1997 Andreas Dilger
Copyright (c) 1995-1996 Guy Eric Schalnat, Group 42, Inc.

The software is supplied "as is", without warranty of any kind,
express or implied, including, without limitation, the warranties
Expand Down Expand Up @@ -1614,10 +1614,10 @@ be appreciated.

TRADEMARK:

The name "libpng" has not been registered by the Copyright owner
The name "libpng" has not been registered by the Copyright owners
as a trademark in any jurisdiction. However, because libpng has
been distributed and maintained world-wide, continually since 1995,
the Copyright owner claims "common-law trademark protection" in any
the Copyright owners claim "common-law trademark protection" in any
jurisdiction where common-law trademark is recognized.

OSI CERTIFICATION:
Expand All @@ -1639,6 +1639,59 @@ Glenn Randers-Pehrson
glennrp at users.sourceforge.net
July 15, 2018

AUTHORS File Information:

PNG REFERENCE LIBRARY AUTHORS
=============================

This is the list of PNG Reference Library ("libpng") Contributing
Authors, for copyright and licensing purposes.

* Andreas Dilger
* Cosmin Truta
* Dave Martindale
* Eric S. Raymond
* Gilles Vollant
* Glenn Randers-Pehrson
* Greg Roelofs
* Guy Eric Schalnat
* James Yu
* John Bowler
* Kevin Bracey
* Magnus Holmgren
* Mandar Sahastrabuddhe
* Mans Rullgard
* Matt Sarett
* Mike Klein
* Pascal Massimino
* Paul Schmidt
* Qiang Zhou
* Sam Bushell
* Samuel Williams
* Simon-Pierre Cadieux
* Tim Wegner
* Tom Lane
* Tom Tanner
* Vadim Barkov
* Willem van Schaik
* Zhijie Liang
* Arm Holdings
- Richard Townsend
* Google Inc.
- Dan Field
- Leon Scroggins III
- Matt Sarett
- Mike Klein
- Sami Boukortt

The build projects, the build scripts, the test scripts, and other
files in the "ci", "projects", "scripts" and "tests" directories, have
other copyright owners, but are released under the libpng license.

Some files in the "contrib" directory, and some tools-generated files
that are distributed with libpng, have other copyright owners, and are
released under other open source licenses.

--- end of LICENSE ---

-------------------------------------------------------------------------------
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,109 @@
/*
* Copyright (c) 2023, Azul Systems, Inc. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free Software Foundation. Oracle designates this
* particular file as subject to the "Classpath" exception as provided
* by Oracle in the LICENSE file that accompanied this code.
*
* This code is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
* version 2 for more details (a copy is included in the LICENSE file that
* accompanied this code).
*
* You should have received a copy of the GNU General Public License version
* 2 along with this work; if not, write to the Free Software Foundation,
* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
*
* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
* or visit www.oracle.com if you need additional information or have any
* questions.
*/
package com.sun.corba.se.impl.orbutil;

import java.io.InvalidObjectException;
import java.security.AccessController;
import java.util.*;

import sun.security.action.GetPropertyAction;

public final class IORCheckImpl {

private static final Set<String> stubsToCheck;

static {
boolean checkLocalStubs =
!getBooleanProperty(ORBConstants.DISABLE_IOR_CHECK_FOR_LOCAL_STUBS,
getBooleanProperty(ORBConstants.ALLOW_DESERIALIZE_OBJECT, false));

boolean checkRemoteStubs =
getBooleanProperty(ORBConstants.ENABLE_IOR_CHECK_FOR_REMOTE_STUBS, false);

stubsToCheck = getStubsToCheck(checkLocalStubs, checkRemoteStubs);
}

private static Set<String> getStubsToCheck(boolean checkLocalStubs, boolean checkRemoteStubs) {
if (!checkLocalStubs && !checkRemoteStubs) {
return Collections.emptySet();
}
List<String> stubs = new ArrayList<>();
if (checkLocalStubs) {
stubs.addAll(getLocalStubs());
}
if (checkRemoteStubs) {
stubs.addAll(getRemoteStubs());
}
return Collections.unmodifiableSet(new HashSet<>(stubs));
}

private static List<String> getLocalStubs() {
String[] localStubs = {
"org.omg.DynamicAny._DynAnyFactoryStub",
"org.omg.DynamicAny._DynAnyStub",
"org.omg.DynamicAny._DynArrayStub",
"org.omg.DynamicAny._DynEnumStub",
"org.omg.DynamicAny._DynFixedStub",
"org.omg.DynamicAny._DynSequenceStub",
"org.omg.DynamicAny._DynStructStub",
"org.omg.DynamicAny._DynUnionStub",
"org.omg.DynamicAny._DynValueStub"
};
return Arrays.asList(localStubs);
}

private static List<String> getRemoteStubs() {
String[] remoteStubs = {
"com.sun.corba.se.spi.activation._ActivatorStub",
"com.sun.corba.se.spi.activation._InitialNameServiceStub",
"com.sun.corba.se.spi.activation._LocatorStub",
"com.sun.corba.se.spi.activation._RepositoryStub",
"com.sun.corba.se.spi.activation._ServerManagerStub",
"com.sun.corba.se.spi.activation._ServerStub",
"org.omg.CosNaming._BindingIteratorStub",
"org.omg.CosNaming._NamingContextExtStub",
"org.omg.CosNaming._NamingContextStub",
"org.omg.PortableServer._ServantActivatorStub",
"org.omg.PortableServer._ServantLocatorStub"
};
return Arrays.asList(remoteStubs);
}

/*
* The str parameter is expected to start with "IOR:".
* Otherwise, the method throws the InvalidObjectException exception.
*/
public static void check(String str, String stubClassName) throws InvalidObjectException {
if (stubsToCheck.contains(stubClassName) && !str.startsWith(ORBConstants.STRINGIFY_PREFIX)) {
throw new InvalidObjectException("IOR: expected");
}
}

private static boolean getBooleanProperty(String property, boolean defaultValue) {
String value = AccessController.doPrivileged(
new GetPropertyAction(property, String.valueOf(defaultValue)));
return "true".equalsIgnoreCase(value);
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -317,8 +317,14 @@ public static int makePersistent( int scid )
public static final String DYNAMIC_STUB_FACTORY_FACTORY_CLASS =
SUN_PREFIX + "ORBDynamicStubFactoryFactoryClass" ;

// This property is provided for backward compatibility reasons
public static final String ALLOW_DESERIALIZE_OBJECT = SUN_PREFIX + "ORBAllowDeserializeObject" ;

// Disables the IOR check for the ORB constrained stubs
public static final String DISABLE_IOR_CHECK_FOR_LOCAL_STUBS = ORG_OMG_PREFIX + "DynamicAny.disableIORCheck" ;
// Enables the IOR check for the Remote CORBA services stubs
public static final String ENABLE_IOR_CHECK_FOR_REMOTE_STUBS = ORG_OMG_CORBA_PREFIX + "IDL.Stubs.enableIORCheck";

// Constants for NameService properties ************************************

public static final int DEFAULT_INITIAL_PORT = 900;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,7 @@ protected void openStream ()
Util.mkdir (pkg);
name = pkg + '/' + name;
}
stubClassName = name.replace('/', '.');
stream = Util.getStream (name.replace ('/', File.separatorChar) + ".java", i);
} // openStream

Expand Down Expand Up @@ -342,11 +343,7 @@ protected void writeSerializationMethods ()
stream.println (" private void readObject (java.io.ObjectInputStream s) throws java.io.IOException");
stream.println (" {");
stream.println (" String str = s.readUTF ();");
if ("DynAnyFactory".equals (i.name ())) {
stream.println (" if (!str.startsWith(com.sun.corba.se.impl.orbutil.ORBConstants.STRINGIFY_PREFIX) &&");
stream.println (" !Boolean.getBoolean(com.sun.corba.se.impl.orbutil.ORBConstants.ALLOW_DESERIALIZE_OBJECT))");
stream.println (" throw new java.io.InvalidObjectException(\"IOR: expected\");");
}
stream.println (" com.sun.corba.se.impl.orbutil.IORCheckImpl.check(str, \"" + stubClassName + "\");");
stream.println (" String[] args = null;");
stream.println (" java.util.Properties props = null;");
stream.println (" org.omg.CORBA.ORB orb = org.omg.CORBA.ORB.init (args, props);");
Expand Down Expand Up @@ -382,4 +379,5 @@ protected void writeSerializationMethods ()
protected String classSuffix = "";
protected boolean localStub = false;
private boolean isAbstract = false;
private String stubClassName = null;
} // class Stub
Loading

0 comments on commit bd94a08

Please sign in to comment.