1.1 --- a/make/common/shared/Sanity.gmk Wed Mar 21 13:37:24 2012 -0700
1.2 +++ b/make/common/shared/Sanity.gmk Wed Mar 21 13:38:55 2012 -0700
1.3 @@ -348,7 +348,13 @@
1.4 " Try setting LANG to 'C'. \n" \
1.5 "" >> $(WARNING_FILE) ; \
1.6 fi
1.7 +ifeq ($(PLATFORM), macosx)
1.8 + @if [ "$(LANG)" = "" ]; then \
1.9 + $(ECHO) "ERROR: LANG must be set on Mac OS X. Recommended value is \"C\"" >> $(ERROR_FILE) ; \
1.10 + fi
1.11 endif
1.12 +endif
1.13 +
1.14
1.15 ######################################################
1.16 # Check the Windows cygwin version
2.1 --- a/make/docs/CORE_PKGS.gmk Wed Mar 21 13:37:24 2012 -0700
2.2 +++ b/make/docs/CORE_PKGS.gmk Wed Mar 21 13:38:55 2012 -0700
2.3 @@ -64,7 +64,7 @@
2.4 javax.management.* \
2.5 javax.script \
2.6 javax.sql.* \
2.7 - javax.tools \
2.8 + javax.tools.* \
2.9 javax.xml.* \
2.10 org.w3c.* \
2.11 org.xml.sax
2.12 @@ -218,6 +218,7 @@
2.13 javax.swing.plaf.nimbus \
2.14 javax.swing.plaf.synth \
2.15 javax.tools \
2.16 + javax.tools.annotation \
2.17 javax.transaction \
2.18 javax.transaction.xa \
2.19 javax.xml.parsers \
3.1 --- a/make/sun/security/ec/Makefile Wed Mar 21 13:37:24 2012 -0700
3.2 +++ b/make/sun/security/ec/Makefile Wed Mar 21 13:38:55 2012 -0700
3.3 @@ -159,7 +159,9 @@
3.4 $(PKGDIR)/ECDSASignature.java \
3.5 $(PKGDIR)/ECKeyPairGenerator.java
3.6
3.7 - JAVAHFLAGS += -Xbootclasspath/p:$(CLASSDESTDIR)
3.8 + JAVAHFLAGS = -bootclasspath \
3.9 + "$(CLASSDESTDIR)$(CLASSPATH_SEPARATOR)$(CLASSBINDIR)"
3.10 +
3.11
3.12 #
3.13 # C and C++ files
4.1 --- a/make/sun/security/mscapi/Makefile Wed Mar 21 13:37:24 2012 -0700
4.2 +++ b/make/sun/security/mscapi/Makefile Wed Mar 21 13:38:55 2012 -0700
4.3 @@ -1,5 +1,5 @@
4.4 #
4.5 -# Copyright (c) 2005, 2011, Oracle and/or its affiliates. All rights reserved.
4.6 +# Copyright (c) 2005, 2012, Oracle and/or its affiliates. All rights reserved.
4.7 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4.8 #
4.9 # This code is free software; you can redistribute it and/or modify it
4.10 @@ -149,7 +149,8 @@
4.11 # Rules
4.12 #
4.13 CLASSDESTDIR = $(TEMPDIR)/classes
4.14 -JAVAHFLAGS += -Xbootclasspath/p:$(CLASSDESTDIR)
4.15 +JAVAHFLAGS = -bootclasspath \
4.16 + "$(CLASSDESTDIR)$(CLASSPATH_SEPARATOR)$(CLASSBINDIR)"
4.17
4.18 include $(BUILDDIR)/common/Mapfile-vers.gmk
4.19
5.1 --- a/make/sun/security/pkcs11/Makefile Wed Mar 21 13:37:24 2012 -0700
5.2 +++ b/make/sun/security/pkcs11/Makefile Wed Mar 21 13:38:55 2012 -0700
5.3 @@ -150,7 +150,8 @@
5.4 # Rules
5.5 #
5.6 CLASSDESTDIR = $(TEMPDIR)/classes
5.7 -JAVAHFLAGS = -bootclasspath "$(CLASSDESTDIR)$(CLASSPATH_SEPARATOR)$(CLASSBINDIR)"
5.8 +JAVAHFLAGS = -bootclasspath \
5.9 + "$(CLASSDESTDIR)$(CLASSPATH_SEPARATOR)$(CLASSBINDIR)"
5.10
5.11 include $(BUILDDIR)/common/Mapfile-vers.gmk
5.12
6.1 --- a/src/share/classes/com/sun/crypto/provider/DHKeyAgreement.java Wed Mar 21 13:37:24 2012 -0700
6.2 +++ b/src/share/classes/com/sun/crypto/provider/DHKeyAgreement.java Wed Mar 21 13:38:55 2012 -0700
6.3 @@ -1,5 +1,5 @@
6.4 /*
6.5 - * Copyright (c) 1997, 2009, Oracle and/or its affiliates. All rights reserved.
6.6 + * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved.
6.7 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
6.8 *
6.9 * This code is free software; you can redistribute it and/or modify it
6.10 @@ -33,6 +33,7 @@
6.11 import java.security.Key;
6.12 import java.security.NoSuchAlgorithmException;
6.13 import java.security.SecureRandom;
6.14 +import java.security.ProviderException;
6.15 import java.security.spec.AlgorithmParameterSpec;
6.16 import java.security.spec.InvalidKeySpecException;
6.17 import javax.crypto.KeyAgreementSpi;
6.18 @@ -234,31 +235,14 @@
6.19 protected byte[] engineGenerateSecret()
6.20 throws IllegalStateException
6.21 {
6.22 - if (generateSecret == false) {
6.23 - throw new IllegalStateException
6.24 - ("Key agreement has not been completed yet");
6.25 + int expectedLen = (init_p.bitLength() + 7) >>> 3;
6.26 + byte[] result = new byte[expectedLen];
6.27 + try {
6.28 + engineGenerateSecret(result, 0);
6.29 + } catch (ShortBufferException sbe) {
6.30 + // should never happen since length are identical
6.31 }
6.32 -
6.33 - // Reset the key agreement here (in case anything goes wrong)
6.34 - generateSecret = false;
6.35 -
6.36 - // get the modulus
6.37 - BigInteger modulus = init_p;
6.38 -
6.39 - BigInteger tmpResult = y.modPow(x, modulus);
6.40 - byte[] secret = tmpResult.toByteArray();
6.41 -
6.42 - /*
6.43 - * BigInteger.toByteArray will sometimes put a sign byte up front, but
6.44 - * we NEVER want one.
6.45 - */
6.46 - if ((tmpResult.bitLength() % 8) == 0) {
6.47 - byte retval[] = new byte[secret.length - 1];
6.48 - System.arraycopy(secret, 1, retval, 0, retval.length);
6.49 - return retval;
6.50 - } else {
6.51 - return secret;
6.52 - }
6.53 + return result;
6.54 }
6.55
6.56 /**
6.57 @@ -301,39 +285,51 @@
6.58 }
6.59
6.60 BigInteger modulus = init_p;
6.61 + int expectedLen = (modulus.bitLength() + 7) >>> 3;
6.62 + if ((sharedSecret.length - offset) < expectedLen) {
6.63 + throw new ShortBufferException
6.64 + ("Buffer too short for shared secret");
6.65 + }
6.66 +
6.67 + // Reset the key agreement after checking for ShortBufferException
6.68 + // above, so user can recover w/o losing internal state
6.69 + generateSecret = false;
6.70 +
6.71 + /*
6.72 + * NOTE: BigInteger.toByteArray() returns a byte array containing
6.73 + * the two's-complement representation of this BigInteger with
6.74 + * the most significant byte is in the zeroth element. This
6.75 + * contains the minimum number of bytes required to represent
6.76 + * this BigInteger, including at least one sign bit whose value
6.77 + * is always 0.
6.78 + *
6.79 + * Keys are always positive, and the above sign bit isn't
6.80 + * actually used when representing keys. (i.e. key = new
6.81 + * BigInteger(1, byteArray)) To obtain an array containing
6.82 + * exactly expectedLen bytes of magnitude, we strip any extra
6.83 + * leading 0's, or pad with 0's in case of a "short" secret.
6.84 + */
6.85 byte[] secret = this.y.modPow(this.x, modulus).toByteArray();
6.86 -
6.87 - // BigInteger.toByteArray will sometimes put a sign byte up front,
6.88 - // but we NEVER want one.
6.89 - if ((secret.length << 3) != modulus.bitLength()) {
6.90 - if ((sharedSecret.length - offset) < (secret.length - 1)) {
6.91 - throw new ShortBufferException
6.92 - ("Buffer too short for shared secret");
6.93 + if (secret.length == expectedLen) {
6.94 + System.arraycopy(secret, 0, sharedSecret, offset,
6.95 + secret.length);
6.96 + } else {
6.97 + // Array too short, pad it w/ leading 0s
6.98 + if (secret.length < expectedLen) {
6.99 + System.arraycopy(secret, 0, sharedSecret,
6.100 + offset + (expectedLen - secret.length),
6.101 + secret.length);
6.102 + } else {
6.103 + // Array too long, check and trim off the excess
6.104 + if ((secret.length == (expectedLen+1)) && secret[0] == 0) {
6.105 + // ignore the leading sign byte
6.106 + System.arraycopy(secret, 1, sharedSecret, offset, expectedLen);
6.107 + } else {
6.108 + throw new ProviderException("Generated secret is out-of-range");
6.109 + }
6.110 }
6.111 - System.arraycopy(secret, 1, sharedSecret, offset,
6.112 - secret.length - 1);
6.113 -
6.114 - // Reset the key agreement here (not earlier!), so that people
6.115 - // can recover from ShortBufferException above without losing
6.116 - // internal state
6.117 - generateSecret = false;
6.118 -
6.119 - return secret.length - 1;
6.120 -
6.121 - } else {
6.122 - if ((sharedSecret.length - offset) < secret.length) {
6.123 - throw new ShortBufferException
6.124 - ("Buffer too short to hold shared secret");
6.125 - }
6.126 - System.arraycopy(secret, 0, sharedSecret, offset, secret.length);
6.127 -
6.128 - // Reset the key agreement here (not earlier!), so that people
6.129 - // can recover from ShortBufferException above without losing
6.130 - // internal state
6.131 - generateSecret = false;
6.132 -
6.133 - return secret.length;
6.134 }
6.135 + return expectedLen;
6.136 }
6.137
6.138 /**
7.1 --- a/src/share/classes/java/lang/management/ManagementFactory.java Wed Mar 21 13:37:24 2012 -0700
7.2 +++ b/src/share/classes/java/lang/management/ManagementFactory.java Wed Mar 21 13:38:55 2012 -0700
7.3 @@ -1,5 +1,5 @@
7.4 /*
7.5 - * Copyright (c) 2003, 2010, Oracle and/or its affiliates. All rights reserved.
7.6 + * Copyright (c) 2003, 2012, Oracle and/or its affiliates. All rights reserved.
7.7 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
7.8 *
7.9 * This code is free software; you can redistribute it and/or modify it
7.10 @@ -42,7 +42,7 @@
7.11 import java.util.Collections;
7.12 import java.util.List;
7.13 import java.util.Set;
7.14 -import java.util.TreeSet;
7.15 +import java.util.HashSet;
7.16 import java.security.AccessController;
7.17 import java.security.Permission;
7.18 import java.security.PrivilegedAction;
7.19 @@ -787,7 +787,7 @@
7.20 getPlatformManagementInterfaces()
7.21 {
7.22 Set<Class<? extends PlatformManagedObject>> result =
7.23 - new TreeSet<>();
7.24 + new HashSet<>();
7.25 for (PlatformComponent component: PlatformComponent.values()) {
7.26 result.add(component.getMXBeanInterface());
7.27 }
8.1 --- a/src/share/classes/java/net/InMemoryCookieStore.java Wed Mar 21 13:37:24 2012 -0700
8.2 +++ b/src/share/classes/java/net/InMemoryCookieStore.java Wed Mar 21 13:38:55 2012 -0700
8.3 @@ -207,6 +207,9 @@
8.4 public boolean removeAll() {
8.5 lock.lock();
8.6 try {
8.7 + if (cookieJar.isEmpty()) {
8.8 + return false;
8.9 + }
8.10 cookieJar.clear();
8.11 domainIndex.clear();
8.12 uriIndex.clear();
9.1 --- a/src/share/classes/java/util/Currency.java Wed Mar 21 13:37:24 2012 -0700
9.2 +++ b/src/share/classes/java/util/Currency.java Wed Mar 21 13:38:55 2012 -0700
9.3 @@ -34,6 +34,8 @@
9.4 import java.io.Serializable;
9.5 import java.security.AccessController;
9.6 import java.security.PrivilegedAction;
9.7 +import java.util.concurrent.ConcurrentHashMap;
9.8 +import java.util.concurrent.ConcurrentMap;
9.9 import java.util.logging.Level;
9.10 import java.util.regex.Pattern;
9.11 import java.util.regex.Matcher;
9.12 @@ -99,7 +101,7 @@
9.13
9.14 // class data: instance map
9.15
9.16 - private static HashMap<String, Currency> instances = new HashMap<String, Currency>(7);
9.17 + private static ConcurrentMap<String, Currency> instances = new ConcurrentHashMap<>(7);
9.18 private static HashSet<Currency> available;
9.19
9.20
9.21 @@ -284,7 +286,6 @@
9.22
9.23 private static Currency getInstance(String currencyCode, int defaultFractionDigits,
9.24 int numericCode) {
9.25 - synchronized (instances) {
9.26 // Try to look up the currency code in the instances table.
9.27 // This does the null pointer check as a side effect.
9.28 // Also, if there already is an entry, the currencyCode must be valid.
9.29 @@ -322,10 +323,9 @@
9.30 }
9.31 }
9.32
9.33 - instance = new Currency(currencyCode, defaultFractionDigits, numericCode);
9.34 - instances.put(currencyCode, instance);
9.35 - return instance;
9.36 - }
9.37 + instance = instances.putIfAbsent(currencyCode,
9.38 + new Currency(currencyCode, defaultFractionDigits, numericCode));
9.39 + return (instance != null ? instance : instances.get(currencyCode));
9.40 }
9.41
9.42 /**
10.1 --- a/src/share/classes/java/util/jar/Manifest.java Wed Mar 21 13:37:24 2012 -0700
10.2 +++ b/src/share/classes/java/util/jar/Manifest.java Wed Mar 21 13:38:55 2012 -0700
10.3 @@ -400,6 +400,8 @@
10.4 public byte peek() throws IOException {
10.5 if (pos == count)
10.6 fill();
10.7 + if (pos == count)
10.8 + return -1; // nothing left in buffer
10.9 return buf[pos];
10.10 }
10.11
11.1 --- a/src/share/classes/sun/rmi/rmic/BatchEnvironment.java Wed Mar 21 13:37:24 2012 -0700
11.2 +++ b/src/share/classes/sun/rmi/rmic/BatchEnvironment.java Wed Mar 21 13:38:55 2012 -0700
11.3 @@ -160,7 +160,7 @@
11.4 }
11.5
11.6 /** list of generated source files created in this environment */
11.7 - private Vector generatedFiles = new Vector();
11.8 + private Vector<File> generatedFiles = new Vector<>();
11.9
11.10 /**
11.11 * Remember a generated source file generated so that it
11.12 @@ -177,9 +177,9 @@
11.13 */
11.14 public void deleteGeneratedFiles() {
11.15 synchronized(generatedFiles) {
11.16 - Enumeration enumeration = generatedFiles.elements();
11.17 + Enumeration<File> enumeration = generatedFiles.elements();
11.18 while (enumeration.hasMoreElements()) {
11.19 - File file = (File) enumeration.nextElement();
11.20 + File file = enumeration.nextElement();
11.21 file.delete();
11.22 }
11.23 generatedFiles.removeAllElements();
12.1 --- a/src/share/classes/sun/rmi/rmic/Main.java Wed Mar 21 13:37:24 2012 -0700
12.2 +++ b/src/share/classes/sun/rmi/rmic/Main.java Wed Mar 21 13:38:55 2012 -0700
12.3 @@ -73,14 +73,15 @@
12.4 File destDir;
12.5 int flags;
12.6 long tm;
12.7 - Vector classes;
12.8 + Vector<String> classes;
12.9 boolean nowrite;
12.10 boolean nocompile;
12.11 boolean keepGenerated;
12.12 boolean status;
12.13 String[] generatorArgs;
12.14 - Vector generators;
12.15 - Class environmentClass = BatchEnvironment.class;
12.16 + Vector<Generator> generators;
12.17 + Class<? extends BatchEnvironment> environmentClass =
12.18 + BatchEnvironment.class;
12.19 boolean iiopGeneration = false;
12.20
12.21 /**
12.22 @@ -183,7 +184,7 @@
12.23 destDir = null;
12.24 flags = F_WARNINGS;
12.25 tm = System.currentTimeMillis();
12.26 - classes = new Vector();
12.27 + classes = new Vector<>();
12.28 nowrite = false;
12.29 nocompile = false;
12.30 keepGenerated = false;
12.31 @@ -191,7 +192,7 @@
12.32 if (generatorArgs == null) {
12.33 return false;
12.34 }
12.35 - generators = new Vector();
12.36 + generators = new Vector<>();
12.37
12.38 // Pre-process command line for @file arguments
12.39 try {
12.40 @@ -411,7 +412,7 @@
12.41
12.42 // Get the environment required by this generator...
12.43
12.44 - Class envClass = BatchEnvironment.class;
12.45 + Class<?> envClass = BatchEnvironment.class;
12.46 String env = getString("generator.env." + arg);
12.47 if (env != null) {
12.48 try {
12.49 @@ -423,7 +424,7 @@
12.50
12.51 // Yes, so switch to the new one...
12.52
12.53 - environmentClass = envClass;
12.54 + environmentClass = envClass.asSubclass(BatchEnvironment.class);
12.55
12.56 } else {
12.57
12.58 @@ -495,8 +496,9 @@
12.59 try {
12.60 Class[] ctorArgTypes = {OutputStream.class,ClassPath.class,Main.class};
12.61 Object[] ctorArgs = {out,classPath,this};
12.62 - Constructor constructor = environmentClass.getConstructor(ctorArgTypes);
12.63 - result = (BatchEnvironment) constructor.newInstance(ctorArgs);
12.64 + Constructor<? extends BatchEnvironment> constructor =
12.65 + environmentClass.getConstructor(ctorArgTypes);
12.66 + result = constructor.newInstance(ctorArgs);
12.67 result.reset();
12.68 }
12.69 catch (Exception e) {
12.70 @@ -530,7 +532,7 @@
12.71 */
12.72 for (int i = classes.size()-1; i >= 0; i-- ) {
12.73 Identifier implClassName =
12.74 - Identifier.lookup((String)classes.elementAt(i));
12.75 + Identifier.lookup(classes.elementAt(i));
12.76
12.77 /*
12.78 * Fix bugid 4049354: support using '.' as an inner class
12.79 @@ -558,7 +560,7 @@
12.80 try {
12.81 ClassDefinition def = decl.getClassDefinition(env);
12.82 for (int j = 0; j < generators.size(); j++) {
12.83 - Generator gen = (Generator)generators.elementAt(j);
12.84 + Generator gen = generators.elementAt(j);
12.85 gen.generate(env, def, destDir);
12.86 }
12.87 } catch (ClassNotFound ex) {
12.88 @@ -673,7 +675,7 @@
12.89
12.90 do {
12.91 done = true;
12.92 - for (Enumeration e = env.getClasses() ; e.hasMoreElements() ; ) {
12.93 + for (Enumeration<?> e = env.getClasses() ; e.hasMoreElements() ; ) {
12.94 ClassDeclaration c = (ClassDeclaration)e.nextElement();
12.95 done = compileClass(c,buf,env);
12.96 }
12.97 @@ -682,7 +684,9 @@
12.98
12.99 /*
12.100 * Compile a single class.
12.101 + * Fallthrough is intentional
12.102 */
12.103 + @SuppressWarnings("fallthrough")
12.104 public boolean compileClass (ClassDeclaration c,
12.105 ByteArrayOutputStream buf,
12.106 BatchEnvironment env)
12.107 @@ -879,6 +883,6 @@
12.108 args[1] = (arg1 != null ? arg1.toString() : "null");
12.109 args[2] = (arg2 != null ? arg2.toString() : "null");
12.110
12.111 - return java.text.MessageFormat.format(format, args);
12.112 + return java.text.MessageFormat.format(format, (Object[]) args);
12.113 }
12.114 }
13.1 --- a/src/share/classes/sun/rmi/rmic/RMIGenerator.java Wed Mar 21 13:37:24 2012 -0700
13.2 +++ b/src/share/classes/sun/rmi/rmic/RMIGenerator.java Wed Mar 21 13:38:55 2012 -0700
13.3 @@ -61,7 +61,7 @@
13.4 */
13.5 public class RMIGenerator implements RMIConstants, Generator {
13.6
13.7 - private static final Hashtable versionOptions = new Hashtable();
13.8 + private static final Hashtable<String, Integer> versionOptions = new Hashtable<>();
13.9 static {
13.10 versionOptions.put("-v1.1", new Integer(STUB_VERSION_1_1));
13.11 versionOptions.put("-vcompat", new Integer(STUB_VERSION_FAT));
13.12 @@ -96,7 +96,7 @@
13.13 return false;
13.14 }
13.15 explicitVersion = arg;
13.16 - version = ((Integer) versionOptions.get(arg)).intValue();
13.17 + version = versionOptions.get(arg);
13.18 argv[i] = null;
13.19 }
13.20 }
13.21 @@ -519,7 +519,7 @@
13.22 * follows a previous catch of it or of one of its superclasses.
13.23 * The following method invocation takes care of these details.
13.24 */
13.25 - Vector catchList = computeUniqueCatchList(exceptions);
13.26 + Vector<ClassDefinition> catchList = computeUniqueCatchList(exceptions);
13.27
13.28 /*
13.29 * If we need to catch any particular exceptions (i.e. this method
13.30 @@ -615,10 +615,10 @@
13.31 * UnexpectedException, and end the try block.
13.32 */
13.33 if (catchList.size() > 0) {
13.34 - for (Enumeration enumeration = catchList.elements();
13.35 + for (Enumeration<ClassDefinition> enumeration = catchList.elements();
13.36 enumeration.hasMoreElements();)
13.37 {
13.38 - ClassDefinition def = (ClassDefinition) enumeration.nextElement();
13.39 + ClassDefinition def = enumeration.nextElement();
13.40 p.pOlnI("} catch (" + def.getName() + " e) {");
13.41 p.pln("throw e;");
13.42 }
13.43 @@ -650,8 +650,8 @@
13.44 * of its superclasses is in the throws clause of the method, indicating
13.45 * that no exceptions need to be caught.
13.46 */
13.47 - private Vector computeUniqueCatchList(ClassDeclaration[] exceptions) {
13.48 - Vector uniqueList = new Vector(); // unique exceptions to catch
13.49 + private Vector<ClassDefinition> computeUniqueCatchList(ClassDeclaration[] exceptions) {
13.50 + Vector<ClassDefinition> uniqueList = new Vector<>(); // unique exceptions to catch
13.51
13.52 uniqueList.addElement(defRuntimeException);
13.53 uniqueList.addElement(defRemoteException);
13.54 @@ -682,8 +682,7 @@
13.55 * exceptions that need to be caught:
13.56 */
13.57 for (int j = 0; j < uniqueList.size();) {
13.58 - ClassDefinition def =
13.59 - (ClassDefinition) uniqueList.elementAt(j);
13.60 + ClassDefinition def = uniqueList.elementAt(j);
13.61 if (def.superClassOf(env, decl)) {
13.62 /*
13.63 * If a superclass of this exception is already on
14.1 --- a/src/share/classes/sun/rmi/rmic/newrmic/Main.java Wed Mar 21 13:37:24 2012 -0700
14.2 +++ b/src/share/classes/sun/rmi/rmic/newrmic/Main.java Wed Mar 21 13:38:55 2012 -0700
14.3 @@ -455,7 +455,7 @@
14.4 BatchEnvironment env;
14.5 try {
14.6 Constructor<? extends BatchEnvironment> cons =
14.7 - batch.envClass.getConstructor(new Class[] { RootDoc.class });
14.8 + batch.envClass.getConstructor(new Class<?>[] { RootDoc.class });
14.9 env = cons.newInstance(rootDoc);
14.10 } catch (NoSuchMethodException e) {
14.11 throw new AssertionError(e);
15.1 --- a/src/share/classes/sun/rmi/rmic/newrmic/Resources.java Wed Mar 21 13:37:24 2012 -0700
15.2 +++ b/src/share/classes/sun/rmi/rmic/newrmic/Resources.java Wed Mar 21 13:38:55 2012 -0700
15.3 @@ -69,7 +69,7 @@
15.4 format = "missing resource key: key = \"" + key + "\", " +
15.5 "arguments = \"{0}\", \"{1}\", \"{2}\"";
15.6 }
15.7 - return MessageFormat.format(format, args);
15.8 + return MessageFormat.format(format, (Object[]) args);
15.9 }
15.10
15.11 /**
16.1 --- a/src/share/classes/sun/security/pkcs11/P11KeyAgreement.java Wed Mar 21 13:37:24 2012 -0700
16.2 +++ b/src/share/classes/sun/security/pkcs11/P11KeyAgreement.java Wed Mar 21 13:38:55 2012 -0700
16.3 @@ -1,5 +1,5 @@
16.4 /*
16.5 - * Copyright (c) 2003, 2011, Oracle and/or its affiliates. All rights reserved.
16.6 + * Copyright (c) 2003, 2012, Oracle and/or its affiliates. All rights reserved.
16.7 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
16.8 *
16.9 * This code is free software; you can redistribute it and/or modify it
16.10 @@ -198,8 +198,22 @@
16.11 token.p11.C_GetAttributeValue(session.id(), keyID, attributes);
16.12 byte[] secret = attributes[0].getByteArray();
16.13 token.p11.C_DestroyObject(session.id(), keyID);
16.14 - // trim leading 0x00 bytes per JCE convention
16.15 - return P11Util.trimZeroes(secret);
16.16 + // Some vendors, e.g. NSS, trim off the leading 0x00 byte(s) from
16.17 + // the generated secret. Thus, we need to check the secret length
16.18 + // and trim/pad it so the returned value has the same length as
16.19 + // the modulus size
16.20 + if (secret.length == secretLen) {
16.21 + return secret;
16.22 + } else {
16.23 + if (secret.length > secretLen) {
16.24 + // Shouldn't happen; but check just in case
16.25 + throw new ProviderException("generated secret is out-of-range");
16.26 + }
16.27 + byte[] newSecret = new byte[secretLen];
16.28 + System.arraycopy(secret, 0, newSecret, secretLen - secret.length,
16.29 + secret.length);
16.30 + return newSecret;
16.31 + }
16.32 } catch (PKCS11Exception e) {
16.33 throw new ProviderException("Could not derive key", e);
16.34 } finally {
17.1 --- a/src/solaris/native/java/util/TimeZone_md.c Wed Mar 21 13:37:24 2012 -0700
17.2 +++ b/src/solaris/native/java/util/TimeZone_md.c Wed Mar 21 13:38:55 2012 -0700
17.3 @@ -1,5 +1,5 @@
17.4 /*
17.5 - * Copyright (c) 1999, 2011, Oracle and/or its affiliates. All rights reserved.
17.6 + * Copyright (c) 1999, 2012, Oracle and/or its affiliates. All rights reserved.
17.7 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
17.8 *
17.9 * This code is free software; you can redistribute it and/or modify it
17.10 @@ -96,9 +96,9 @@
17.11 /*
17.12 * Scans the specified directory and its subdirectories to find a
17.13 * zoneinfo file which has the same content as /etc/localtime on Linux
17.14 - * or /usr/share/lib/zoneinfo/localtime (most likely a symbolic link)
17.15 - * on Solaris given in 'buf'. Returns a zone ID if found, otherwise,
17.16 - * NULL is returned.
17.17 + * or /usr/share/lib/zoneinfo/localtime on Solaris given in 'buf'.
17.18 + * If file is symbolic link, then the contents it points to are in buf.
17.19 + * Returns a zone ID if found, otherwise, NULL is returned.
17.20 */
17.21 static char *
17.22 findZoneinfoFile(char *buf, size_t size, const char *dir)
17.23 @@ -280,21 +280,27 @@
17.24 tz = getZoneName(linkbuf);
17.25 if (tz != NULL) {
17.26 tz = strdup(tz);
17.27 + return tz;
17.28 }
17.29 - return tz;
17.30 }
17.31
17.32 /*
17.33 * If it's a regular file, we need to find out the same zoneinfo file
17.34 * that has been copied as /etc/localtime.
17.35 + * If initial symbolic link resolution failed, we should treat target
17.36 + * file as a regular file.
17.37 */
17.38 + if ((fd = open(DEFAULT_ZONEINFO_FILE, O_RDONLY)) == -1) {
17.39 + return NULL;
17.40 + }
17.41 + if (fstat(fd, &statbuf) == -1) {
17.42 + (void) close(fd);
17.43 + return NULL;
17.44 + }
17.45 size = (size_t) statbuf.st_size;
17.46 buf = (char *) malloc(size);
17.47 if (buf == NULL) {
17.48 - return NULL;
17.49 - }
17.50 - if ((fd = open(DEFAULT_ZONEINFO_FILE, O_RDONLY)) == -1) {
17.51 - free((void *) buf);
17.52 + (void) close(fd);
17.53 return NULL;
17.54 }
17.55
18.1 --- a/src/solaris/native/sun/nio/ch/DatagramDispatcher.c Wed Mar 21 13:37:24 2012 -0700
18.2 +++ b/src/solaris/native/sun/nio/ch/DatagramDispatcher.c Wed Mar 21 13:38:55 2012 -0700
18.3 @@ -36,6 +36,7 @@
18.4 #include <sys/socket.h>
18.5
18.6 #include "nio_util.h"
18.7 +#include <limits.h>
18.8
18.9 JNIEXPORT jint JNICALL
18.10 Java_sun_nio_ch_DatagramDispatcher_read0(JNIEnv *env, jclass clazz,
18.11 @@ -60,23 +61,14 @@
18.12 ssize_t result = 0;
18.13 struct iovec *iov = (struct iovec *)jlong_to_ptr(address);
18.14 struct msghdr m;
18.15 - if (len > 16) {
18.16 - len = 16;
18.17 + if (len > IOV_MAX) {
18.18 + len = IOV_MAX;
18.19 }
18.20
18.21 - m.msg_name = NULL;
18.22 - m.msg_namelen = 0;
18.23 + // initialize the message
18.24 + memset(&m, 0, sizeof(m));
18.25 m.msg_iov = iov;
18.26 m.msg_iovlen = len;
18.27 -#ifdef __solaris__
18.28 - m.msg_accrights = NULL;
18.29 - m.msg_accrightslen = 0;
18.30 -#endif
18.31 -
18.32 -#if defined(__linux__) || defined(_ALLBSD_SOURCE)
18.33 - m.msg_control = NULL;
18.34 - m.msg_controllen = 0;
18.35 -#endif
18.36
18.37 result = recvmsg(fd, &m, 0);
18.38 if (result < 0 && errno == ECONNREFUSED) {
18.39 @@ -108,23 +100,14 @@
18.40 struct iovec *iov = (struct iovec *)jlong_to_ptr(address);
18.41 struct msghdr m;
18.42 ssize_t result = 0;
18.43 - if (len > 16) {
18.44 - len = 16;
18.45 + if (len > IOV_MAX) {
18.46 + len = IOV_MAX;
18.47 }
18.48
18.49 - m.msg_name = NULL;
18.50 - m.msg_namelen = 0;
18.51 + // initialize the message
18.52 + memset(&m, 0, sizeof(m));
18.53 m.msg_iov = iov;
18.54 m.msg_iovlen = len;
18.55 -#ifdef __solaris__
18.56 - m.msg_accrights = NULL;
18.57 - m.msg_accrightslen = 0;
18.58 -#endif
18.59 -
18.60 -#if defined(__linux__) || defined(_ALLBSD_SOURCE)
18.61 - m.msg_control = NULL;
18.62 - m.msg_controllen = 0;
18.63 -#endif
18.64
18.65 result = sendmsg(fd, &m, 0);
18.66 if (result < 0 && errno == ECONNREFUSED) {
19.1 --- a/src/solaris/native/sun/nio/fs/GnomeFileTypeDetector.c Wed Mar 21 13:37:24 2012 -0700
19.2 +++ b/src/solaris/native/sun/nio/fs/GnomeFileTypeDetector.c Wed Mar 21 13:38:55 2012 -0700
19.3 @@ -30,9 +30,6 @@
19.4
19.5 #include <stdlib.h>
19.6 #include <dlfcn.h>
19.7 -#ifndef __APPLE__
19.8 -#include <link.h>
19.9 -#endif
19.10
19.11 #ifdef __solaris__
19.12 #include <strings.h>
20.1 --- a/src/solaris/native/sun/security/jgss/wrapper/NativeFunc.c Wed Mar 21 13:37:24 2012 -0700
20.2 +++ b/src/solaris/native/sun/security/jgss/wrapper/NativeFunc.c Wed Mar 21 13:38:55 2012 -0700
20.3 @@ -26,9 +26,6 @@
20.4 #include <stdio.h>
20.5 #include <stdlib.h>
20.6 #include <dlfcn.h>
20.7 -#ifndef __APPLE__
20.8 -#include <link.h>
20.9 -#endif
20.10 #include "NativeFunc.h"
20.11
20.12 /* standard GSS method names (ordering is from mapfile) */
21.1 --- a/src/solaris/native/sun/security/pkcs11/j2secmod_md.c Wed Mar 21 13:37:24 2012 -0700
21.2 +++ b/src/solaris/native/sun/security/pkcs11/j2secmod_md.c Wed Mar 21 13:38:55 2012 -0700
21.3 @@ -28,9 +28,6 @@
21.4 #include <string.h>
21.5
21.6 #include <dlfcn.h>
21.7 -#ifndef __APPLE__
21.8 -#include <link.h>
21.9 -#endif
21.10
21.11 #include <jni_util.h>
21.12
22.1 --- a/src/solaris/native/sun/security/pkcs11/wrapper/p11_md.c Wed Mar 21 13:37:24 2012 -0700
22.2 +++ b/src/solaris/native/sun/security/pkcs11/wrapper/p11_md.c Wed Mar 21 13:38:55 2012 -0700
22.3 @@ -64,9 +64,6 @@
22.4 #include <assert.h>
22.5
22.6 #include <dlfcn.h>
22.7 -#ifndef __APPLE__
22.8 -#include <link.h>
22.9 -#endif
22.10
22.11 #include <jni.h>
22.12
23.1 --- a/src/solaris/native/sun/security/smartcardio/pcsc_md.c Wed Mar 21 13:37:24 2012 -0700
23.2 +++ b/src/solaris/native/sun/security/smartcardio/pcsc_md.c Wed Mar 21 13:38:55 2012 -0700
23.3 @@ -29,9 +29,6 @@
23.4 #include <assert.h>
23.5
23.6 #include <dlfcn.h>
23.7 -#ifndef __APPLE__
23.8 -#include <link.h>
23.9 -#endif
23.10
23.11 #include <winscard.h>
23.12
24.1 --- a/src/solaris/npt/npt_md.h Wed Mar 21 13:37:24 2012 -0700
24.2 +++ b/src/solaris/npt/npt_md.h Wed Mar 21 13:38:55 2012 -0700
24.3 @@ -32,9 +32,6 @@
24.4 #include <string.h>
24.5 #include <errno.h>
24.6 #include <dlfcn.h>
24.7 -#ifndef __APPLE__
24.8 -#include <link.h>
24.9 -#endif
24.10 #include <jvm_md.h>
24.11
24.12 #define NPT_LIBNAME "npt"
25.1 --- a/test/ProblemList.txt Wed Mar 21 13:37:24 2012 -0700
25.2 +++ b/test/ProblemList.txt Wed Mar 21 13:38:55 2012 -0700
25.3 @@ -212,7 +212,7 @@
25.4 # 7076644
25.5 java/io/File/Basic.java windows-all
25.6
25.7 -# Test needs AWT window server, does not work headless
25.8 +# 7145435 - Test needs AWT window server, does not work headless
25.9 java/io/Serializable/resolveClass/deserializeButton/run.sh macosx-all
25.10
25.11 ############################################################################
25.12 @@ -225,9 +225,6 @@
25.13 # 7052549
25.14 java/nio/channels/FileChannel/ReleaseOnCloseDeadlock.java windows-all
25.15
25.16 -# 6963118
25.17 -java/nio/channels/Selector/Wakeup.java windows-all
25.18 -
25.19 # 7133499, 7133497
25.20 java/nio/channels/AsyncCloseAndInterrupt.java macosx-all
25.21 java/nio/channels/AsynchronousFileChannel/Lock.java macosx-all
25.22 @@ -259,9 +256,6 @@
25.23
25.24 # jdk_security
25.25
25.26 -# 7145024
25.27 -sun/security/ssl/com/sun/net/ssl/internal/ssl/GenSSLConfigs/main.java solaris-all
25.28 -
25.29 # 7147060
25.30 com/sun/org/apache/xml/internal/security/transforms/ClassLoaderTest.java generic-all
25.31
25.32 @@ -305,9 +299,6 @@
25.33 # 7079203 sun/security/tools/keytool/printssl.sh fails on solaris with timeout
25.34 sun/security/tools/keytool/printssl.sh solaris-all
25.35
25.36 -# 7081817
25.37 -sun/security/provider/certpath/X509CertPath/IllegalCertiticates.java generic-all
25.38 -
25.39 # 7041639, Solaris DSA keypair generation bug (Note: jdk_util also affected)
25.40 java/security/KeyPairGenerator/SolarisShortDSA.java solaris-all
25.41 sun/security/tools/jarsigner/onlymanifest.sh solaris-all
26.1 --- a/test/com/sun/crypto/provider/KeyAgreement/DHKeyAgreement2.java Wed Mar 21 13:37:24 2012 -0700
26.2 +++ b/test/com/sun/crypto/provider/KeyAgreement/DHKeyAgreement2.java Wed Mar 21 13:38:55 2012 -0700
26.3 @@ -1,5 +1,5 @@
26.4 /*
26.5 - * Copyright (c) 1997, 2007, Oracle and/or its affiliates. All rights reserved.
26.6 + * Copyright (c) 1997, 2012, Oracle and/or its affiliates. All rights reserved.
26.7 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
26.8 *
26.9 * This code is free software; you can redistribute it and/or modify it
26.10 @@ -23,7 +23,7 @@
26.11
26.12 /*
26.13 * @test
26.14 - * @bug 0000000
26.15 + * @bug 7146728
26.16 * @summary DHKeyAgreement2
26.17 * @author Jan Luehe
26.18 */
26.19 @@ -52,15 +52,12 @@
26.20
26.21 public class DHKeyAgreement2 {
26.22
26.23 + private static final String SUNJCE = "SunJCE";
26.24 private DHKeyAgreement2() {}
26.25
26.26 public static void main(String argv[]) throws Exception {
26.27 String mode = "USE_SKIP_DH_PARAMS";
26.28
26.29 - // Add JCE to the list of providers
26.30 - SunJCE jce = new SunJCE();
26.31 - Security.addProvider(jce);
26.32 -
26.33 DHKeyAgreement2 keyAgree = new DHKeyAgreement2();
26.34
26.35 if (argv.length > 1) {
26.36 @@ -86,7 +83,7 @@
26.37 // Some central authority creates new DH parameters
26.38 System.err.println("Creating Diffie-Hellman parameters ...");
26.39 AlgorithmParameterGenerator paramGen
26.40 - = AlgorithmParameterGenerator.getInstance("DH");
26.41 + = AlgorithmParameterGenerator.getInstance("DH", SUNJCE);
26.42 paramGen.init(512);
26.43 AlgorithmParameters params = paramGen.generateParameters();
26.44 dhSkipParamSpec = (DHParameterSpec)params.getParameterSpec
26.45 @@ -103,7 +100,7 @@
26.46 * above
26.47 */
26.48 System.err.println("ALICE: Generate DH keypair ...");
26.49 - KeyPairGenerator aliceKpairGen = KeyPairGenerator.getInstance("DH");
26.50 + KeyPairGenerator aliceKpairGen = KeyPairGenerator.getInstance("DH", SUNJCE);
26.51 aliceKpairGen.initialize(dhSkipParamSpec);
26.52 KeyPair aliceKpair = aliceKpairGen.generateKeyPair();
26.53 System.out.println("Alice DH public key:\n" +
26.54 @@ -112,14 +109,14 @@
26.55 aliceKpair.getPrivate().toString());
26.56 DHParameterSpec dhParamSpec =
26.57 ((DHPublicKey)aliceKpair.getPublic()).getParams();
26.58 - AlgorithmParameters algParams = AlgorithmParameters.getInstance("DH");
26.59 + AlgorithmParameters algParams = AlgorithmParameters.getInstance("DH", SUNJCE);
26.60 algParams.init(dhParamSpec);
26.61 System.out.println("Alice DH parameters:\n"
26.62 + algParams.toString());
26.63
26.64 // Alice executes Phase1 of her version of the DH protocol
26.65 System.err.println("ALICE: Execute PHASE1 ...");
26.66 - KeyAgreement aliceKeyAgree = KeyAgreement.getInstance("DH");
26.67 + KeyAgreement aliceKeyAgree = KeyAgreement.getInstance("DH", SUNJCE);
26.68 aliceKeyAgree.init(aliceKpair.getPrivate());
26.69
26.70 // Alice encodes her public key, and sends it over to Bob.
26.71 @@ -130,7 +127,7 @@
26.72 * in encoded format.
26.73 * He instantiates a DH public key from the encoded key material.
26.74 */
26.75 - KeyFactory bobKeyFac = KeyFactory.getInstance("DH");
26.76 + KeyFactory bobKeyFac = KeyFactory.getInstance("DH", SUNJCE);
26.77 X509EncodedKeySpec x509KeySpec = new X509EncodedKeySpec
26.78 (alicePubKeyEnc);
26.79 PublicKey alicePubKey = bobKeyFac.generatePublic(x509KeySpec);
26.80 @@ -144,7 +141,7 @@
26.81
26.82 // Bob creates his own DH key pair
26.83 System.err.println("BOB: Generate DH keypair ...");
26.84 - KeyPairGenerator bobKpairGen = KeyPairGenerator.getInstance("DH");
26.85 + KeyPairGenerator bobKpairGen = KeyPairGenerator.getInstance("DH", SUNJCE);
26.86 bobKpairGen.initialize(dhParamSpec);
26.87 KeyPair bobKpair = bobKpairGen.generateKeyPair();
26.88 System.out.println("Bob DH public key:\n" +
26.89 @@ -154,7 +151,7 @@
26.90
26.91 // Bob executes Phase1 of his version of the DH protocol
26.92 System.err.println("BOB: Execute PHASE1 ...");
26.93 - KeyAgreement bobKeyAgree = KeyAgreement.getInstance("DH");
26.94 + KeyAgreement bobKeyAgree = KeyAgreement.getInstance("DH", SUNJCE);
26.95 bobKeyAgree.init(bobKpair.getPrivate());
26.96
26.97 // Bob encodes his public key, and sends it over to Alice.
26.98 @@ -166,7 +163,7 @@
26.99 * Before she can do so, she has to instanticate a DH public key
26.100 * from Bob's encoded key material.
26.101 */
26.102 - KeyFactory aliceKeyFac = KeyFactory.getInstance("DH");
26.103 + KeyFactory aliceKeyFac = KeyFactory.getInstance("DH", SUNJCE);
26.104 x509KeySpec = new X509EncodedKeySpec(bobPubKeyEnc);
26.105 PublicKey bobPubKey = aliceKeyFac.generatePublic(x509KeySpec);
26.106 System.err.println("ALICE: Execute PHASE2 ...");
26.107 @@ -187,49 +184,32 @@
26.108 byte[] aliceSharedSecret = aliceKeyAgree.generateSecret();
26.109 int aliceLen = aliceSharedSecret.length;
26.110
26.111 + // check if alice's key agreement has been reset afterwards
26.112 + try {
26.113 + aliceKeyAgree.generateSecret();
26.114 + throw new Exception("Error: alice's KeyAgreement not reset");
26.115 + } catch (IllegalStateException e) {
26.116 + System.out.println("EXPECTED: " + e.getMessage());
26.117 + }
26.118 +
26.119 byte[] bobSharedSecret = new byte[aliceLen];
26.120 int bobLen;
26.121 try {
26.122 // provide output buffer that is too short
26.123 bobLen = bobKeyAgree.generateSecret(bobSharedSecret, 1);
26.124 -
26.125 - /*
26.126 - * Gatekeeper's note:
26.127 - * We should not be getting here, but every so often, we
26.128 - * get a failure, either a "ShortBufferException" or
26.129 - * "Key agreement has not been completed yet" in the
26.130 - * generateSecret(bobSharedSecret, 0) below.
26.131 - *
26.132 - * This will help to figure out why we're dropping through
26.133 - * and not failing.
26.134 - */
26.135 - System.out.println("NIGHTLY: Should *NOT* be here!!!\n" +
26.136 - "aliceLen = " + aliceLen + "\n" +
26.137 - "Alice's shared secret");
26.138 -
26.139 - try {
26.140 - HexDumpEncoder hd = new HexDumpEncoder();
26.141 -
26.142 - hd.encodeBuffer(
26.143 - new ByteArrayInputStream(aliceSharedSecret), System.out);
26.144 - } catch (IOException e) { }
26.145 -
26.146 - System.out.println("bobLen = " + bobLen);
26.147 -
26.148 - try {
26.149 - HexDumpEncoder hd = new HexDumpEncoder();
26.150 -
26.151 - hd.encodeBuffer(
26.152 - new ByteArrayInputStream(bobSharedSecret), System.out);
26.153 - } catch (IOException e) { }
26.154 -
26.155 - throw new Exception("Shouldn't be succeeding.");
26.156 } catch (ShortBufferException e) {
26.157 System.out.println("EXPECTED: " + e.getMessage());
26.158 }
26.159 + // retry w/ output buffer of required size
26.160 + bobLen = bobKeyAgree.generateSecret(bobSharedSecret, 0);
26.161
26.162 - // provide output buffer of required size
26.163 - bobLen = bobKeyAgree.generateSecret(bobSharedSecret, 0);
26.164 + // check if bob's key agreement has been reset afterwards
26.165 + try {
26.166 + bobKeyAgree.generateSecret(bobSharedSecret, 0);
26.167 + throw new Exception("Error: bob's KeyAgreement not reset");
26.168 + } catch (IllegalStateException e) {
26.169 + System.out.println("EXPECTED: " + e.getMessage());
26.170 + }
26.171
26.172 System.out.println("Alice secret: " + toHexString(aliceSharedSecret));
26.173 System.out.println("Bob secret: " + toHexString(bobSharedSecret));
27.1 --- a/test/com/sun/jdi/EarlyReturnTest.java Wed Mar 21 13:37:24 2012 -0700
27.2 +++ b/test/com/sun/jdi/EarlyReturnTest.java Wed Mar 21 13:38:55 2012 -0700
27.3 @@ -292,7 +292,9 @@
27.4 private String[] excludes = {
27.5 "javax.*",
27.6 "sun.*",
27.7 - "com.sun.*"};
27.8 + "com.sun.*",
27.9 + "com.oracle.*",
27.10 + "oracle.*"};
27.11
27.12 static VirtualMachineManager vmm ;
27.13 ClassType targetClass;
28.1 --- a/test/com/sun/jdi/MethodEntryExitEvents.java Wed Mar 21 13:37:24 2012 -0700
28.2 +++ b/test/com/sun/jdi/MethodEntryExitEvents.java Wed Mar 21 13:38:55 2012 -0700
28.3 @@ -114,7 +114,8 @@
28.4 * http://java.sun.com/javase/technologies/core/toolsapis/jpda/
28.5 */
28.6 private String[] excludes = {"java.*", "javax.*", "sun.*",
28.7 - "com.sun.*"};
28.8 + "com.sun.*", "com.oracle.*",
28.9 + "oracle.*"};
28.10
28.11 MethodEntryExitEvents (String args[]) {
28.12 super(args);
29.1 --- a/test/com/sun/jdi/MethodExitReturnValuesTest.java Wed Mar 21 13:37:24 2012 -0700
29.2 +++ b/test/com/sun/jdi/MethodExitReturnValuesTest.java Wed Mar 21 13:38:55 2012 -0700
29.3 @@ -218,7 +218,9 @@
29.4 private String[] excludes = {
29.5 "javax.*",
29.6 "sun.*",
29.7 - "com.sun.*"};
29.8 + "com.sun.*",
29.9 + "com.oracle.*",
29.10 + "oracle.*"};
29.11
29.12 static VirtualMachineManager vmm ;
29.13 ClassType targetClass;
30.1 --- a/test/java/io/File/isDirectory/Applet.html Wed Mar 21 13:37:24 2012 -0700
30.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
30.3 @@ -1,2 +0,0 @@
30.4 -<!---->
30.5 -<applet code=Applet.class width=100 height=100></applet>
31.1 --- a/test/java/io/Serializable/badSubstByReplace/BadSubstByReplace.java Wed Mar 21 13:37:24 2012 -0700
31.2 +++ b/test/java/io/Serializable/badSubstByReplace/BadSubstByReplace.java Wed Mar 21 13:38:55 2012 -0700
31.3 @@ -22,7 +22,6 @@
31.4 */
31.5
31.6 /* @test
31.7 - * @clean A B Container ReplacerObjectOutputStream
31.8 * @summary Verify that ClassCastException is thrown when deserializing
31.9 * an object and one of its object fields is incompatibly replaced
31.10 * by either replaceObject/resolveObject.
32.1 --- a/test/java/io/Serializable/replaceStringArray/ReplaceStringArray.java Wed Mar 21 13:37:24 2012 -0700
32.2 +++ b/test/java/io/Serializable/replaceStringArray/ReplaceStringArray.java Wed Mar 21 13:38:55 2012 -0700
32.3 @@ -22,7 +22,6 @@
32.4 */
32.5
32.6 /* @test
32.7 - * @clean A SubstituteObjectOutputStream SubstituteObjectInputStream
32.8 * @bug 4099013
32.9 * @summary Enable substitution of String and Array by ObjectStreams.
32.10 */
33.1 --- a/test/java/io/Serializable/replaceWithNull/ReplaceWithNull.java Wed Mar 21 13:37:24 2012 -0700
33.2 +++ b/test/java/io/Serializable/replaceWithNull/ReplaceWithNull.java Wed Mar 21 13:38:55 2012 -0700
33.3 @@ -23,7 +23,6 @@
33.4
33.5 /* @test
33.6 * @bug 4065313
33.7 - * @clean A ReplaceWithNull MyObjectOutputStream
33.8 * @summary Ensure that it is okay to replace an object with null.
33.9 */
33.10 import java.io.*;
34.1 --- a/test/java/io/Serializable/verifyDynamicObjHandleTable/VerifyDynamicObjHandleTable.java Wed Mar 21 13:37:24 2012 -0700
34.2 +++ b/test/java/io/Serializable/verifyDynamicObjHandleTable/VerifyDynamicObjHandleTable.java Wed Mar 21 13:38:55 2012 -0700
34.3 @@ -22,7 +22,6 @@
34.4 */
34.5
34.6 /* @test
34.7 - * @clean A
34.8 * @bug 4146453
34.9 * @summary Test that regrow of object/handle table of ObjectOutputStream works.
34.10 */
35.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
35.2 +++ b/test/java/lang/management/ManagementFactory/GetPlatformManagementInterfaces.java Wed Mar 21 13:38:55 2012 -0700
35.3 @@ -0,0 +1,76 @@
35.4 +/*
35.5 + * Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved.
35.6 + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
35.7 + *
35.8 + * This code is free software; you can redistribute it and/or modify it
35.9 + * under the terms of the GNU General Public License version 2 only, as
35.10 + * published by the Free Software Foundation.
35.11 + *
35.12 + * This code is distributed in the hope that it will be useful, but WITHOUT
35.13 + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
35.14 + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
35.15 + * version 2 for more details (a copy is included in the LICENSE file that
35.16 + * accompanied this code).
35.17 + *
35.18 + * You should have received a copy of the GNU General Public License version
35.19 + * 2 along with this work; if not, write to the Free Software Foundation,
35.20 + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
35.21 + *
35.22 + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
35.23 + * or visit www.oracle.com if you need additional information or have any
35.24 + * questions.
35.25 + */
35.26 +
35.27 +/*
35.28 + * @test
35.29 + * @bug 7074616
35.30 + * @summary Basic unit test of the
35.31 + * ManagementFactory.getPlatformManagementInterfaces() method
35.32 + * @author Frederic Parain
35.33 + *
35.34 + * @run main GetPlatformManagementInterfaces
35.35 + */
35.36 +
35.37 +import java.lang.management.*;
35.38 +import java.io.IOException;
35.39 +import java.util.*;
35.40 +import javax.management.*;
35.41 +
35.42 +import static java.lang.management.ManagementFactory.*;
35.43 +
35.44 +public class GetPlatformManagementInterfaces {
35.45 +
35.46 + private static enum ManagementInterfaces {
35.47 + CLASS_LOADING_MXBEAN(ClassLoadingMXBean.class),
35.48 + COMPILATION_MXBEAN(CompilationMXBean.class),
35.49 + MEMORY_MXBEAN(MemoryMXBean.class),
35.50 + OPERATING_SYSTEM_MXBEAN(OperatingSystemMXBean.class),
35.51 + RUNTIME_MXBEAN(RuntimeMXBean.class),
35.52 + THREAD_MXBEAN(ThreadMXBean.class),
35.53 + GARBAGE_COLLECTOR_MXBEAN(GarbageCollectorMXBean.class),
35.54 + MEMORY_MANAGER_MXBEAN(MemoryManagerMXBean.class),
35.55 + MEMORY_POOL_MXBEAN(MemoryPoolMXBean.class);
35.56 +
35.57 + private final Class<? extends PlatformManagedObject> managementInterface;
35.58 + private ManagementInterfaces(Class<? extends PlatformManagedObject> minterface) {
35.59 + managementInterface = minterface;
35.60 + }
35.61 + public Class<? extends PlatformManagedObject> getManagementInterface() {
35.62 + return managementInterface;
35.63 + }
35.64 + };
35.65 +
35.66 + public static void main(String[] args) {
35.67 + Set<Class<? extends PlatformManagedObject>> interfaces =
35.68 + ManagementFactory.getPlatformManagementInterfaces();
35.69 + for(Class<? extends PlatformManagedObject> pom : interfaces) {
35.70 + List<? extends PlatformManagedObject> list =
35.71 + ManagementFactory.getPlatformMXBeans(pom);
35.72 + }
35.73 + for(ManagementInterfaces mi : ManagementInterfaces.values()) {
35.74 + if(!interfaces.contains(mi.getManagementInterface())) {
35.75 + throw new RuntimeException(mi.getManagementInterface() + " not in ManagementInterfaces set");
35.76 + }
35.77 + }
35.78 + }
35.79 +}
36.1 --- a/test/java/net/CookieHandler/NullUriCookieTest.java Wed Mar 21 13:37:24 2012 -0700
36.2 +++ b/test/java/net/CookieHandler/NullUriCookieTest.java Wed Mar 21 13:38:55 2012 -0700
36.3 @@ -23,8 +23,9 @@
36.4
36.5 /*
36.6 * @test
36.7 - * @bug 6953455
36.8 + * @bug 6953455 7045655
36.9 * @summary CookieStore.add() cannot handle null URI parameter
36.10 + * and An empty InMemoryCookieStore should not return true for removeAll
36.11 */
36.12
36.13 import java.net.CookieManager;
36.14 @@ -44,6 +45,11 @@
36.15 static void checkCookieNullUri() throws Exception {
36.16 //get a cookie store implementation and add a cookie to the store with null URI
36.17 CookieStore cookieStore = (new CookieManager()).getCookieStore();
36.18 + //Check if removeAll() retrurns false on an empty CookieStore
36.19 + if (cookieStore.removeAll()) {
36.20 + fail = true;
36.21 + }
36.22 + checkFail("removeAll on empty store should return false");
36.23 HttpCookie cookie = new HttpCookie("MY_COOKIE", "MY_COOKIE_VALUE");
36.24 cookie.setDomain("foo.com");
36.25 cookieStore.add(null, cookie);
37.1 --- a/test/java/net/Socks/SocksServer.java Wed Mar 21 13:37:24 2012 -0700
37.2 +++ b/test/java/net/Socks/SocksServer.java Wed Mar 21 13:38:55 2012 -0700
37.3 @@ -22,13 +22,14 @@
37.4 */
37.5 import java.net.*;
37.6 import java.io.*;
37.7 +import java.util.HashMap;
37.8
37.9 public class SocksServer extends Thread {
37.10 // Some useful SOCKS constant
37.11
37.12 - static final int PROTO_VERS4 = 4;
37.13 + static final int PROTO_VERS4 = 4;
37.14 static final int PROTO_VERS = 5;
37.15 - static final int DEFAULT_PORT = 1080;
37.16 + static final int DEFAULT_PORT = 1080;
37.17
37.18 static final int NO_AUTH = 0;
37.19 static final int GSSAPI = 1;
37.20 @@ -36,28 +37,28 @@
37.21 static final int NO_METHODS = -1;
37.22
37.23 static final int CONNECT = 1;
37.24 - static final int BIND = 2;
37.25 + static final int BIND = 2;
37.26 static final int UDP_ASSOC = 3;
37.27
37.28 - static final int IPV4 = 1;
37.29 - static final int DOMAIN_NAME = 3;
37.30 - static final int IPV6 = 4;
37.31 + static final int IPV4 = 1;
37.32 + static final int DOMAIN_NAME = 3;
37.33 + static final int IPV6 = 4;
37.34
37.35 static final int REQUEST_OK = 0;
37.36 static final int GENERAL_FAILURE = 1;
37.37 - static final int NOT_ALLOWED = 2;
37.38 + static final int NOT_ALLOWED = 2;
37.39 static final int NET_UNREACHABLE = 3;
37.40 static final int HOST_UNREACHABLE = 4;
37.41 - static final int CONN_REFUSED = 5;
37.42 - static final int TTL_EXPIRED = 6;
37.43 + static final int CONN_REFUSED = 5;
37.44 + static final int TTL_EXPIRED = 6;
37.45 static final int CMD_NOT_SUPPORTED = 7;
37.46 static final int ADDR_TYPE_NOT_SUP = 8;
37.47
37.48 private int port;
37.49 private ServerSocket server;
37.50 private boolean useV4 = false;
37.51 - private java.util.Hashtable users = new java.util.Hashtable();
37.52 - private boolean done = false;
37.53 + private HashMap<String,String> users = new HashMap<>();
37.54 + private volatile boolean done = false;
37.55 // Inner class to handle protocol with client
37.56 // This is the bulk of the work (protocol handler)
37.57 class ClientHandler extends Thread {
37.58 @@ -136,7 +137,7 @@
37.59 System.err.println("User: '" + uname);
37.60 System.err.println("PSWD: '" + password);
37.61 if (users.containsKey(uname)) {
37.62 - String p1 = (String) users.get(uname);
37.63 + String p1 = users.get(uname);
37.64 System.err.println("p1 = " + p1);
37.65 if (p1.equals(password)) {
37.66 out.write(PROTO_VERS);
37.67 @@ -492,7 +493,12 @@
37.68 public SocksServer(int port) throws IOException {
37.69 this.port = port;
37.70 server = new ServerSocket();
37.71 - server.bind(new InetSocketAddress(port));
37.72 + if (port == 0) {
37.73 + server.bind(null);
37.74 + this.port = server.getLocalPort();
37.75 + } else {
37.76 + server.bind(new InetSocketAddress(port));
37.77 + }
37.78 }
37.79
37.80 public SocksServer() throws IOException {
37.81 @@ -503,8 +509,13 @@
37.82 users.put(user, passwd);
37.83 }
37.84
37.85 - public synchronized void terminate() {
37.86 + public int getPort() {
37.87 + return port;
37.88 + }
37.89 +
37.90 + public void terminate() {
37.91 done = true;
37.92 + try { server.close(); } catch (IOException unused) {}
37.93 }
37.94
37.95 public void run() {
38.1 --- a/test/java/net/Socks/SocksV4Test.java Wed Mar 21 13:37:24 2012 -0700
38.2 +++ b/test/java/net/Socks/SocksV4Test.java Wed Mar 21 13:38:55 2012 -0700
38.3 @@ -26,23 +26,22 @@
38.4 * @bug 4727547
38.5 * @summary SocksSocketImpl throws NullPointerException
38.6 * @build SocksServer
38.7 + * @run main SocksV4Test
38.8 */
38.9
38.10 import java.net.*;
38.11 -import java.io.*;
38.12
38.13 public class SocksV4Test {
38.14 - public static void main(String[] args) throws IOException {
38.15 - // Create a SOCKS V4 proxy on port 8888
38.16 - SocksServer srvr = new SocksServer(8888, true);
38.17 + public static void main(String[] args) throws Exception {
38.18 + // Create a SOCKS V4 proxy
38.19 + SocksServer srvr = new SocksServer(0, true);
38.20 srvr.start();
38.21 - System.setProperty("socksProxyHost", "localhost");
38.22 - System.setProperty("socksProxyPort", "8888");
38.23 + Proxy sp = new Proxy(Proxy.Type.SOCKS,
38.24 + new InetSocketAddress("localhost", srvr.getPort()));
38.25 // Let's create an unresolved address
38.26 InetSocketAddress ad = new InetSocketAddress("doesnt.exist.name", 1234);
38.27 - Socket s = new Socket();
38.28 - try {
38.29 - s.connect(ad,10000);
38.30 + try (Socket s = new Socket(sp)) {
38.31 + s.connect(ad, 10000);
38.32 } catch (UnknownHostException ex) {
38.33 // OK, that's what we expected
38.34 } catch (NullPointerException npe) {
38.35 @@ -50,7 +49,6 @@
38.36 throw new RuntimeException("Got a NUllPointerException");
38.37 } finally {
38.38 srvr.terminate();
38.39 - srvr.interrupt();
38.40 }
38.41 }
38.42 }
39.1 --- a/test/java/nio/file/Files/CustomOptions.java Wed Mar 21 13:37:24 2012 -0700
39.2 +++ b/test/java/nio/file/Files/CustomOptions.java Wed Mar 21 13:38:55 2012 -0700
39.3 @@ -28,6 +28,7 @@
39.4 * @author Brandon Passanisi
39.5 * @library ..
39.6 * @build CustomOptions PassThroughFileSystem
39.7 + * @run main CustomOptions
39.8 */
39.9
39.10 import java.io.IOException;
40.1 --- a/test/java/text/Bidi/Bug6850113.java Wed Mar 21 13:37:24 2012 -0700
40.2 +++ b/test/java/text/Bidi/Bug6850113.java Wed Mar 21 13:38:55 2012 -0700
40.3 @@ -25,6 +25,7 @@
40.4 * @bug 6850113
40.5 * @summary Verify the return value of digit() for some digits.
40.6 * @compile -XDignore.symbol.file=true Bug6850113.java
40.7 + * @run main Bug6850113
40.8 */
40.9
40.10 import sun.text.normalizer.UCharacter;
41.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
41.2 +++ b/test/java/util/jar/Manifest/CreateManifest.java Wed Mar 21 13:38:55 2012 -0700
41.3 @@ -0,0 +1,301 @@
41.4 +/*
41.5 + * Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved.
41.6 + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
41.7 + *
41.8 + * This code is free software; you can redistribute it and/or modify it
41.9 + * under the terms of the GNU General Public License version 2 only, as
41.10 + * published by the Free Software Foundation.
41.11 + *
41.12 + * This code is distributed in the hope that it will be useful, but WITHOUT
41.13 + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
41.14 + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
41.15 + * version 2 for more details (a copy is included in the LICENSE file that
41.16 + * accompanied this code).
41.17 + *
41.18 + * You should have received a copy of the GNU General Public License version
41.19 + * 2 along with this work; if not, write to the Free Software Foundation,
41.20 + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
41.21 + *
41.22 + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
41.23 + * or visit www.oracle.com if you need additional information or have any
41.24 + * questions.
41.25 + */
41.26 +
41.27 +/*
41.28 + * @test
41.29 + * @bug 7148584
41.30 + * @summary Jar tools fails to generate manifest correctly when boundary condition hit
41.31 + * @compile -XDignore.symbol.file=true CreateManifest.java
41.32 + * @run main CreateManifest
41.33 + */
41.34 +
41.35 +import java.nio.file.Files;
41.36 +import java.nio.file.Paths;
41.37 +import java.util.jar.*;
41.38 +
41.39 +public class CreateManifest {
41.40 +
41.41 +public static void main(String arg[]) throws Exception {
41.42 +
41.43 + String jarFileName = "test.jar";
41.44 + String ManifestName = "MANIFEST.MF";
41.45 +
41.46 + // create the MANIFEST.MF file
41.47 + Files.write(Paths.get(ManifestName), FILE_CONTENTS.getBytes());
41.48 +
41.49 + String [] args = new String [] { "cvfm", jarFileName, ManifestName};
41.50 + sun.tools.jar.Main jartool =
41.51 + new sun.tools.jar.Main(System.out, System.err, "jar");
41.52 + jartool.run(args);
41.53 +
41.54 + try (JarFile jf = new JarFile(jarFileName)) {
41.55 + Manifest m = jf.getManifest();
41.56 + String result = m.getMainAttributes().getValue("Class-path");
41.57 + if (result == null)
41.58 + throw new RuntimeException("Failed to add Class-path attribute to manifest");
41.59 + } finally {
41.60 + Files.deleteIfExists(Paths.get(jarFileName));
41.61 + Files.deleteIfExists(Paths.get(ManifestName));
41.62 + }
41.63 +
41.64 +}
41.65 +
41.66 +private static final String FILE_CONTENTS =
41.67 + "Class-path: \n" +
41.68 + " /ade/dtsao_re/oracle/emcore//lib/em-core-testconsole-uimodel.jar \n" +
41.69 + " /ade/dtsao_re/oracle/emcore//lib/em-core-testconsole-ui.jar \n" +
41.70 + " /ade/dtsao_re/oracle/emcore//lib/em-core-bmp-model.jar \n" +
41.71 + " /ade/dtsao_re/oracle/emcore//lib/em-core-bmp-ui.jar \n" +
41.72 + " /ade/dtsao_re/oracle/emcore//lib/em-core-host-uimodel.jar \n" +
41.73 + " /ade/dtsao_re/oracle/emcore//lib/em-core-host-ui.jar \n" +
41.74 + " /ade/dtsao_re/oracle/emcore//lib/em-core-agent-patching-uimodel.jar \n" +
41.75 + " /ade/dtsao_re/oracle/emcore//lib/em-core-agent-patching-ui.jar \n" +
41.76 + " /ade/dtsao_re/oracle/emcore//lib/em-core-connector-uimodel.jar \n" +
41.77 + " /ade/dtsao_re/oracle/emcore//lib/em-core-connector-ui.jar \n" +
41.78 + " /ade/dtsao_re/oracle/emcore//lib/em-core-discovery-model.jar \n" +
41.79 + " /ade/dtsao_re/oracle/emcore//lib/em-core-gccompliance-model.jar \n" +
41.80 + " /ade/dtsao_re/oracle/emcore//lib/em-core-mos-uimodel.jar \n" +
41.81 + " /ade/dtsao_re/oracle/emcore//lib/em-core-mos-ui.jar \n" +
41.82 + " /ade/dtsao_re/oracle/emcore//lib/em-core-security-uimodel.jar \n" +
41.83 + " /ade/dtsao_re/oracle/emcore//lib/em-core-security-ui.jar \n" +
41.84 + " /ade/dtsao_re/oracle/emcore//lib/em-core-topology-uimodel.jar \n" +
41.85 + " /ade/dtsao_re/oracle/emcore//lib/em-core-topology-ui.jar \n" +
41.86 + " /ade/dtsao_re/oracle/emcore//lib/em-core-event-pojo.jar \n" +
41.87 + " /ade/dtsao_re/oracle/emcore//lib/em-core-event-uimodel.jar \n" +
41.88 + " /ade/dtsao_re/oracle/emcore//lib/em-core-event-ui.jar \n" +
41.89 + " /ade/dtsao_re/oracle/emcore//lib/em-core-mext-uimodel.jar \n" +
41.90 + " /ade/dtsao_re/oracle/emcore//lib/em-core-mext-ui.jar \n" +
41.91 + " /ade/dtsao_re/oracle/emcore//lib/em-core-discovery-uimodel.jar \n" +
41.92 + " /ade/dtsao_re/oracle/emcore//lib/em-core-discovery-ui.jar \n" +
41.93 + " /ade/dtsao_re/oracle/emcore//lib/em-core-ecm-uimodel.jar \n" +
41.94 + " /ade/dtsao_re/oracle/emcore//lib/em-core-ecm-ui.jar \n" +
41.95 + " /ade/dtsao_re/oracle/emcore//lib/em-core-ecm-test.jar \n" +
41.96 + " /ade/dtsao_re/oracle/emcore//lib/em-core-event-console-uimodel.jar \n" +
41.97 + " /ade/dtsao_re/oracle/emcore//lib/em-core-event-console-ui.jar \n" +
41.98 + " /ade/dtsao_re/oracle/emcore//lib/em-core-event-rules-uimodel.jar \n" +
41.99 + " /ade/dtsao_re/oracle/emcore//lib/em-core-event-rules-ui.jar \n" +
41.100 + " /ade/dtsao_re/oracle/emcore//lib/em-core-gccompliance-ui.jar \n" +
41.101 + " /ade/dtsao_re/oracle/emcore//lib/em-core-ip-uimodel.jar \n" +
41.102 + " /ade/dtsao_re/oracle/emcore//lib/em-core-ip-ui.jar \n" +
41.103 + " /ade/dtsao_re/oracle/emcore//lib/em-core-probanalysis-uimodel.jar \n" +
41.104 + " /ade/dtsao_re/oracle/emcore//lib/em-core-probanalysis-ui.jar \n" +
41.105 + " /ade/dtsao_re/oracle/emcore//lib/em-core-swlib-ui.jar \n" +
41.106 + " /ade/dtsao_re/oracle/emcore//lib/em-core-installmediacomponent-ui.jar \n" +
41.107 + " /ade/dtsao_re/oracle/emcore//lib/em-core-uifwk-uimodel.jar \n" +
41.108 + " /ade/dtsao_re/oracle/emcore//lib/em-core-uifwk-ui.jar \n" +
41.109 + " /ade/dtsao_re/oracle/emcore//lib/em-core-discovery-model.jar \n" +
41.110 + " /ade/dtsao_re/oracle/emcore//lib/em-core-gccompliance-model.jar \n" +
41.111 + " /ade/dtsao_re/oracle/emcore//lib/em-core-bmp-test.jar \n" +
41.112 + " /ade/dtsao_re/oracle/emcore//lib/em-core-host-test.jar \n" +
41.113 + " /ade/dtsao_re/oracle/emcore//lib/em-core-agent-patching-test.jar \n" +
41.114 + " /ade/dtsao_re/oracle/emcore//lib/em-core-connector-test.jar \n" +
41.115 + " /ade/dtsao_re/oracle/emcore//lib/em-core-mos-test.jar \n" +
41.116 + " /ade/dtsao_re/oracle/emcore//lib/em-core-event-test.jar \n" +
41.117 + " /ade/dtsao_re/oracle/emcore//lib/em-core-discovery-test.jar \n" +
41.118 + " /ade/dtsao_re/oracle/emcore//lib/em-core-gccompliance-test.jar \n" +
41.119 + " /ade/dtsao_re/oracle/emcore//lib/em-core-ip-test.jar \n" +
41.120 + " /ade/dtsao_re/oracle/emcore//lib/em-core-probanalysis-test.jar \n" +
41.121 + " /ade/dtsao_re/oracle/emcore//lib/em-core-testconsole-test.jar \n" +
41.122 + " /ade/dtsao_re/oracle/emcore//lib/em-core-uifwk-test.jar \n" +
41.123 + " /ade/dtsao_re/oracle/emcore//lib/em-core-mext-test.jar \n" +
41.124 + " /ade/dtsao_re/oracle/emcore//lib/em-core-security-test.jar \n" +
41.125 + " /ade/dtsao_re/oracle/emcore//lib/em-core-agentpush-ui.jar \n" +
41.126 + " /ade/dtsao_re/oracle/emcore//lib/em-core-agentpush-uimodel.jar \n" +
41.127 + " /ade/dtsao_re/oracle/emcore//lib/em-core-agentpush-test.jar \n" +
41.128 + " /ade/dtsao_re/oracle/emcore//lib/em-core-selfupdate-uimodel.jar \n" +
41.129 + " /ade/dtsao_re/oracle/emcore//lib/em-core-selfupdate-ui.jar \n" +
41.130 + " /ade/dtsao_re/oracle/emcore//lib/em-core-selfupdate-test.jar \n" +
41.131 + " /ade/dtsao_re/oracle/emcore//lib/em-core-agentpush-model.jar \n" +
41.132 + " /ade/dtsao_re/oracle/emcore//lib/em-core-groups-uimodel.jar \n" +
41.133 + " /ade/dtsao_re/oracle/emcore//lib/em-core-groups-ui.jar \n" +
41.134 + " /ade/dtsao_re/oracle/emcore//lib/em-core-groups-test.jar \n" +
41.135 + " /ade/dtsao_re/oracle/emcore//lib/em-core-topology-test.jar \n" +
41.136 + " /ade/dtsao_re/oracle/emcore//lib/em-core-jobs-ui.jar \n" +
41.137 + " /ade/dtsao_re/oracle/emcore//lib/em-core-jobs-uimodel.jar \n" +
41.138 + " /ade/dtsao_re/oracle/emcore//lib/em-core-jobs-test.jar \n" +
41.139 + " /ade/dtsao_re/oracle/emcore//lib/em-core-templ-uimodel.jar \n" +
41.140 + " /ade/dtsao_re/oracle/emcore//lib/em-core-templ-ui.jar \n" +
41.141 + " /ade/dtsao_re/oracle/emcore//lib/em-core-templ-test.jar \n" +
41.142 + " /ade/dtsao_re/oracle/emcore//lib/em-core-metricalertserrors-uimodel.jar \n" +
41.143 + " /ade/dtsao_re/oracle/emcore//lib/em-core-metricalertserrors-ui.jar \n" +
41.144 + " /ade/dtsao_re/oracle/emcore//lib/em-core-metricalertserrors-test.jar \n" +
41.145 + " /ade/dtsao_re/oracle/emcore//lib/em-core-metrics-ui.jar \n" +
41.146 + " /ade/dtsao_re/oracle/emcore//lib/em-core-metrics-uimodel.jar \n" +
41.147 + " /ade/dtsao_re/oracle/emcore//lib/em-core-metrics-test.jar \n" +
41.148 + " /ade/dtsao_re/oracle/emcore//lib/em-core-tc-ui.jar \n" +
41.149 + " /ade/dtsao_re/oracle/emcore//lib/em-core-tc-uimodel.jar \n" +
41.150 + " /ade/dtsao_re/oracle/emcore//lib/em-core-tc-test.jar \n" +
41.151 + " /ade/dtsao_re/oracle/emcore//lib/em-core-agentmgmt-ui.jar \n" +
41.152 + " /ade/dtsao_re/oracle/emcore//lib/em-core-agentmgmt-uimodel.jar \n" +
41.153 + " /ade/dtsao_re/oracle/emcore//lib/em-core-agentmgmt-test.jar \n" +
41.154 + " /ade/dtsao_re/oracle/emcore//lib/em-core-gcharvester-uimodel.jar \n" +
41.155 + " /ade/dtsao_re/oracle/emcore//lib/em-core-gcharvester-ui.jar \n" +
41.156 + " /ade/dtsao_re/oracle/emcore//lib/em-core-gcharvester-test.jar \n" +
41.157 + " /ade/dtsao_re/oracle/emcore//lib/em-core-patching-uimodel.jar \n" +
41.158 + " /ade/dtsao_re/oracle/emcore//lib/em-core-patching-ui.jar \n" +
41.159 + " /ade/dtsao_re/oracle/emcore//lib/em-core-patching-test.jar \n" +
41.160 + " /ade/dtsao_re/oracle/emcore//lib/em-core-ohinv-uimodel.jar \n" +
41.161 + " /ade/dtsao_re/oracle/emcore//lib/em-core-ohinv-ui.jar \n" +
41.162 + " /ade/dtsao_re/oracle/emcore//lib/em-core-ohinv-test.jar \n" +
41.163 + " /ade/dtsao_re/oracle/emcore//lib/em-core-ohagent-pojo.jar \n" +
41.164 + " /ade/dtsao_re/oracle/emcore//lib/em-core-ohcoherence-pojo.jar \n" +
41.165 + " /ade/dtsao_re/oracle/emcore//lib/em-core-ohjrockit-pojo.jar \n" +
41.166 + " /ade/dtsao_re/oracle/emcore//lib/em-core-extensibility-ui.jar \n" +
41.167 + " /ade/dtsao_re/oracle/emcore//lib/em-core-mpcustom-ui.jar \n" +
41.168 + " /ade/dtsao_re/oracle/emcore//lib/em-core-selfmonitor-ui.jar \n" +
41.169 + " /ade/dtsao_re/oracle/emcore//lib/em-core-ocheck-uimodel.jar \n" +
41.170 + " /ade/dtsao_re/oracle/emcore//lib/em-core-udmmig-uimodel.jar \n" +
41.171 + " /ade/dtsao_re/oracle/emcore//lib/em-core-multioms-ui.jar \n" +
41.172 + " /ade/dtsao_re/oracle/emcore//lib/em-core-postupgrade-ui.jar \n" +
41.173 + " /ade/dtsao_re/oracle/emcore//lib/em-core-postupgrade-uimodel.jar \n" +
41.174 + " /ade/dtsao_re/oracle/emcore//lib/em-core-postupgrade-test.jar \n" +
41.175 + " /ade/dtsao_re/oracle/emcore//lib/em-core-ppc-pojo.jar \n" +
41.176 + " /ade/dtsao_re/oracle/emcore//lib/em-core-ppc-model.jar \n" +
41.177 + " /ade/dtsao_re/oracle/emcore//lib/em-core-ppc-uimodel.jar \n" +
41.178 + " /ade/dtsao_re/oracle/emcore//lib/em-core-ppc-ui.jar \n" +
41.179 + " /ade/dtsao_re/oracle/emcore//lib/em-core-ppc-test.jar \n" +
41.180 + " /ade/dtsao_re/oracle/emcore//lib/em-core-mextjmx-uimodel.jar \n" +
41.181 + " /ade/dtsao_re/oracle/emcore//lib/em-core-mextjmx-ui.jar \n" +
41.182 + " /ade/dtsao_re/oracle/emcore//lib/em-core-mextjmx-test.jar \n" +
41.183 + " /ade/dtsao_re/oracle/emcore//lib/em-core-ocheck-ui.jar \n" +
41.184 + " /ade/dtsao_re/oracle/emcore//lib/em-core-services-uimodel.jar \n" +
41.185 + " /ade/dtsao_re/oracle/emcore//lib/em-core-services-ui.jar \n" +
41.186 + " /ade/dtsao_re/oracle/emcore//lib/em-core-services-test.jar \n" +
41.187 + " /ade/dtsao_re/oracle/emcore//lib/em-core-eventmobile-ui.jar \n" +
41.188 + " /ade/dtsao_re/oracle/emcore//lib/em-core-uifwkmobile-ui.jar \n" +
41.189 + " /ade/dtsao_re/oracle/emcore//lib/em-core-logmgmt-uimodel.jar \n" +
41.190 + " /ade/dtsao_re/oracle/emcore//lib/em-core-omsproperties-ui.jar \n" +
41.191 + " /ade/dtsao_re/oracle/emcore//lib/em-core-ohel-pojo.jar \n" +
41.192 + " /ade/dtsao_re/oracle/emcore//lib/em-core-agentupgrade-ui.jar \n" +
41.193 + " /ade/dtsao_re/oracle/emcore//lib/em-core-lm-test.jar \n" +
41.194 + " /ade/dtsao_re/oracle/emcore//lib/em-core-lm-ui.jar \n" +
41.195 + " /ade/dtsao_re/oracle/emcore//lib/em-core-lm-model.jar \n" +
41.196 + " /ade/dtsao_re/oracle/emcore//lib/em-samples-regiontest-ui.jar \n" +
41.197 + " /ade/dtsao_re/oracle/emcore//lib/em-samples-uipatterns-test.jar \n" +
41.198 + " /ade/dtsao_re/oracle/emcore//lib/em-samples-uipatterns-uimodel.jar \n" +
41.199 + " /ade/dtsao_re/oracle/emcore//lib/em-samples-uipatterns-ui.jar \n" +
41.200 + " /ade/dtsao_re/oracle/emcore//lib/em-samples-uielements-uimodel.jar \n" +
41.201 + " /ade/dtsao_re/oracle/emcore//lib/em-samples-uielements-ui.jar \n" +
41.202 + " /ade/dtsao_re/oracle/emcore//lib/em-samples-sandbox-uimodel.jar \n" +
41.203 + " /ade/dtsao_re/oracle/emcore//lib/em-samples-sandbox-ui.jar \n" +
41.204 + " /ade/dtsao_re/oracle/emcore//lib/em-samples-sdkcore-model.jar \n" +
41.205 + " /ade/dtsao_re/oracle/emcore//lib/em-samples-sdkcore-uimodel.jar \n" +
41.206 + " /ade/dtsao_re/oracle/emcore//lib/em-samples-sdkcore-ui.jar \n" +
41.207 + " /ade/dtsao_re/oracle/emcore//lib/em-samples-core-model.jar \n" +
41.208 + " /ade/dtsao_re/oracle/emcore//lib/em-samples-core-uimodel.jar \n" +
41.209 + " /ade/dtsao_re/oracle/emcore//lib/em-samples-core-ui.jar \n" +
41.210 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-adfext-bc-public-model.jar \n" +
41.211 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-aslm-services-public-pojo.jar \n" +
41.212 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-avail-public-model.jar \n" +
41.213 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-charge-public-model.jar \n" +
41.214 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-config-public-model.jar \n" +
41.215 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-connect-public-model.jar \n" +
41.216 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-db-public-model.jar \n" +
41.217 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-discovery-public-entity.jar \n" +
41.218 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-discovery-public-model.jar \n" +
41.219 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-event-console-public-model.jar \n" +
41.220 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-event-public-model.jar \n" +
41.221 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-event-rules-public-model.jar \n" +
41.222 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-extens-public-model.jar \n" +
41.223 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-filebrowser-public-model.jar \n" +
41.224 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-filebrowser-public-ui.jar \n" +
41.225 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-gccompliance-public-model.jar \n" +
41.226 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-gccompliance-uimodel.jar \n" +
41.227 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-gccompliance-public-ui.jar \n" +
41.228 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-ip-public-model.jar \n" +
41.229 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-job-public-model.jar \n" +
41.230 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-me-public-model.jar \n" +
41.231 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-metric-public-model.jar \n" +
41.232 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-ecm-public-pojo.jar \n" +
41.233 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-ecm-public-model.jar \n" +
41.234 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-ecm-public-ui.jar \n" +
41.235 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-ecm-test.jar \n" +
41.236 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-paf-public-model.jar \n" +
41.237 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-security-public-model.jar \n" +
41.238 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-swlib-public-pojo.jar \n" +
41.239 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-swlib-public-ui.jar \n" +
41.240 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-templ-public-model.jar \n" +
41.241 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-uifwk-public-model.jar \n" +
41.242 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-uifwk-public-pojo.jar \n" +
41.243 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-uifwk-public-ui.jar \n" +
41.244 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-bmp-public-model.jar \n" +
41.245 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-bmp-public-ui.jar \n" +
41.246 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-bmp-public-entity.jar \n" +
41.247 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-agent-patching-public-model.jar \n" +
41.248 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-agent-patching-public-pojo.jar \n" +
41.249 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-mext-public-model.jar \n" +
41.250 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-mext-public-ui.jar \n" +
41.251 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-mext-test.jar \n" +
41.252 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-testconsole-public-model.jar \n" +
41.253 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-testconsole-public-ui.jar \n" +
41.254 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-testconsole-test.jar \n" +
41.255 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-mos-public-model.jar \n" +
41.256 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-mos-public-ui.jar \n" +
41.257 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-mos-test.jar \n" +
41.258 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-topology-public-model.jar \n" +
41.259 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-topology-public-ui.jar \n" +
41.260 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-regions-uimodel.jar \n" +
41.261 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-regions-public-ui.jar \n" +
41.262 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-event-test.jar \n" +
41.263 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-uifwk-test.jar \n" +
41.264 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-adfext-test.jar \n" +
41.265 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-agentpatching-test.jar \n" +
41.266 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-avail-test.jar \n" +
41.267 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-bmp-test.jar \n" +
41.268 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-charge-test.jar \n" +
41.269 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-config-test.jar \n" +
41.270 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-connect-test.jar \n" +
41.271 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-db-test.jar \n" +
41.272 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-discovery-test.jar \n" +
41.273 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-ecm-test.jar \n" +
41.274 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-extens-test.jar \n" +
41.275 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-gccompliance-test.jar \n" +
41.276 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-ip-test.jar \n" +
41.277 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-job-test.jar \n" +
41.278 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-me-test.jar \n" +
41.279 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-metric-test.jar \n" +
41.280 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-paf-test.jar \n" +
41.281 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-regions-test.jar \n" +
41.282 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-security-test.jar \n" +
41.283 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-swlib-test.jar \n" +
41.284 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-templ-test.jar \n" +
41.285 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-groups-public-pojo.jar \n" +
41.286 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-groups-test.jar \n" +
41.287 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-topology-test.jar \n" +
41.288 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-resources-public-pojo.jar \n" +
41.289 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-clonecomponents-public-pojo.jar \n" +
41.290 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-clonecomponents-public-model.jar \n" +
41.291 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-clonecomponents-public-ui.jar \n" +
41.292 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-clonecomponents-test.jar \n" +
41.293 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-patching-public-model.jar \n" +
41.294 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-patching-test.jar \n" +
41.295 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-ohinv-public-model.jar \n" +
41.296 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-ohinv-test.jar \n" +
41.297 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-ppc-public-pojo.jar \n" +
41.298 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-ppc-public-ui.jar \n" +
41.299 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-agentpush-public-model.jar \n" +
41.300 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-uifwkmobile-public-ui.jar \n" +
41.301 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-lm-public-model.jar \n" +
41.302 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-lm-public-ui.jar \n" +
41.303 + " /ade/dtsao_re/oracle/emcore//lib/em-sdkcore-lm-test.jar \n";
41.304 +}
42.1 --- a/test/javax/naming/spi/DirectoryManager/GetContDirCtx.java Wed Mar 21 13:37:24 2012 -0700
42.2 +++ b/test/javax/naming/spi/DirectoryManager/GetContDirCtx.java Wed Mar 21 13:38:55 2012 -0700
42.3 @@ -26,6 +26,7 @@
42.4 * @bug 4241676
42.5 * @summary getContinuationDirContext() should set CPE environment property.
42.6 * @build DummyObjectFactory DummyContext
42.7 + * @run main/othervm GetContDirCtx
42.8 */
42.9
42.10 import java.util.Hashtable;
43.1 --- a/test/sun/management/HotspotClassLoadingMBean/GetClassLoadingTime.java Wed Mar 21 13:37:24 2012 -0700
43.2 +++ b/test/sun/management/HotspotClassLoadingMBean/GetClassLoadingTime.java Wed Mar 21 13:38:55 2012 -0700
43.3 @@ -1,5 +1,5 @@
43.4 /*
43.5 - * Copyright (c) 2003, 2008, Oracle and/or its affiliates. All rights reserved.
43.6 + * Copyright (c) 2003, 2012, Oracle and/or its affiliates. All rights reserved.
43.7 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
43.8 *
43.9 * This code is free software; you can redistribute it and/or modify it
43.10 @@ -27,6 +27,7 @@
43.11 * @summary Basic unit test of HotspotClassLoadingMBean.getClassLoadingTime()
43.12 * @author Steve Bohne
43.13 * @build ClassToLoad0
43.14 + * @run main GetClassLoadingTime
43.15 */
43.16
43.17 /*
43.18 @@ -71,10 +72,8 @@
43.19 }
43.20
43.21 long time2 = mbean.getClassLoadingTime();
43.22 - long count = mbean.getLoadedClassCount();
43.23
43.24 if (trace) {
43.25 - System.out.println("(new count is " + count + ")");
43.26 System.out.println("Class loading time2 (ms): " + time2);
43.27 }
43.28
43.29 @@ -93,8 +92,6 @@
43.30 // so we can avoid delegation and spend lots of time loading the
43.31 // same class over and over, to test the class loading timer.
43.32 class KlassLoader extends ClassLoader {
43.33 - static String klassDir="";
43.34 - static int index=0;
43.35
43.36 public KlassLoader() {
43.37 super(null);
43.38 @@ -102,14 +99,13 @@
43.39
43.40 protected synchronized Class findClass(String name)
43.41 throws ClassNotFoundException {
43.42 - String cname = klassDir
43.43 - + (klassDir == "" ? "" : "/")
43.44 - +name.replace('.', '/')
43.45 + String cname =
43.46 + name.replace('.', '/')
43.47 +".class";
43.48
43.49 FileInputStream in;
43.50 try {
43.51 - in=new FileInputStream(cname);
43.52 + in = new FileInputStream(new File(System.getProperty("test.classes", "."), cname));
43.53 if (in == null) {
43.54 throw new ClassNotFoundException("getResourceAsStream("
43.55 +cname+")");
44.1 --- a/test/sun/misc/Cleaner/exitOnThrow.sh Wed Mar 21 13:37:24 2012 -0700
44.2 +++ b/test/sun/misc/Cleaner/exitOnThrow.sh Wed Mar 21 13:38:55 2012 -0700
44.3 @@ -29,6 +29,7 @@
44.4 # @summary Ensure that if a cleaner throws an exception then the VM exits
44.5 #
44.6 # @build ExitOnThrow
44.7 +# @run shell exitOnThrow.sh
44.8
44.9 # Command-line usage: sh exitOnThrow.sh /path/to/build
44.10
45.1 --- a/test/sun/nio/cs/OLD/TestIBMDB.java Wed Mar 21 13:37:24 2012 -0700
45.2 +++ b/test/sun/nio/cs/OLD/TestIBMDB.java Wed Mar 21 13:38:55 2012 -0700
45.3 @@ -26,6 +26,7 @@
45.4 * @bug 6843578
45.5 * @summary Test IBM DB charsets
45.6 * @build IBM930_OLD IBM933_OLD IBM935_OLD IBM937_OLD IBM939_OLD IBM942_OLD IBM943_OLD IBM948_OLD IBM949_OLD IBM950_OLD IBM970_OLD IBM942C_OLD IBM943C_OLD IBM949C_OLD IBM1381_OLD IBM1383_OLD EUC_CN_OLD EUC_KR_OLD GBK_OLD Johab_OLD MS932_OLD MS936_OLD MS949_OLD MS950_OLD
45.7 + * @run main TestIBMDB
45.8 */
45.9
45.10 import java.nio.charset.*;
46.1 --- a/test/sun/nio/cs/OLD/TestX11CS.java Wed Mar 21 13:37:24 2012 -0700
46.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
46.3 @@ -1,133 +0,0 @@
46.4 -/*
46.5 - * Copyright (c) 2009, Oracle and/or its affiliates. All rights reserved.
46.6 - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
46.7 - *
46.8 - * This code is free software; you can redistribute it and/or modify it
46.9 - * under the terms of the GNU General Public License version 2 only, as
46.10 - * published by the Free Software Foundation.
46.11 - *
46.12 - * This code is distributed in the hope that it will be useful, but WITHOUT
46.13 - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
46.14 - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
46.15 - * version 2 for more details (a copy is included in the LICENSE file that
46.16 - * accompanied this code).
46.17 - *
46.18 - * You should have received a copy of the GNU General Public License version
46.19 - * 2 along with this work; if not, write to the Free Software Foundation,
46.20 - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
46.21 - *
46.22 - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
46.23 - * or visit www.oracle.com if you need additional information or have any
46.24 - * questions.
46.25 - */
46.26 -
46.27 -/*
46.28 - * @test
46.29 - * @bug 1234567
46.30 - * @summary Test updated X11 charsets
46.31 - * @build X11GB2312_OLD X11GBK_OLD X11KSC5601_OLD
46.32 - */
46.33 -
46.34 -import java.nio.charset.*;
46.35 -import java.nio.*;
46.36 -import java.util.*;
46.37 -
46.38 -public class TestX11CS {
46.39 -
46.40 - static char[] decode(byte[] bb, Charset cs)
46.41 - throws Exception {
46.42 - CharsetDecoder dec = cs.newDecoder();
46.43 - ByteBuffer bbf = ByteBuffer.wrap(bb);
46.44 - CharBuffer cbf = CharBuffer.allocate(bb.length);
46.45 - CoderResult cr = dec.decode(bbf, cbf, true);
46.46 - if (cr != CoderResult.UNDERFLOW) {
46.47 - System.out.println("DEC-----------------");
46.48 - int pos = bbf.position();
46.49 - System.out.printf(" cr=%s, bbf.pos=%d, bb[pos]=%x,%x,%x,%x%n",
46.50 - cr.toString(), pos,
46.51 - bb[pos++]&0xff, bb[pos++]&0xff,bb[pos++]&0xff, bb[pos++]&0xff);
46.52 - throw new RuntimeException("Decoding err: " + cs.name());
46.53 - }
46.54 - char[] cc = new char[cbf.position()];
46.55 - cbf.flip(); cbf.get(cc);
46.56 - return cc;
46.57 -
46.58 - }
46.59 -
46.60 - static byte[] encode(char[] cc, Charset cs)
46.61 - throws Exception {
46.62 - ByteBuffer bbf = ByteBuffer.allocate(cc.length * 4);
46.63 - CharBuffer cbf = CharBuffer.wrap(cc);
46.64 - CharsetEncoder enc = cs.newEncoder();
46.65 -
46.66 - CoderResult cr = enc.encode(cbf, bbf, true);
46.67 - if (cr != CoderResult.UNDERFLOW) {
46.68 - System.out.println("ENC-----------------");
46.69 - int pos = cbf.position();
46.70 - System.out.printf(" cr=%s, cbf.pos=%d, cc[pos]=%x%n",
46.71 - cr.toString(), pos, cc[pos]&0xffff);
46.72 - throw new RuntimeException("Encoding err: " + cs.name());
46.73 - }
46.74 - byte[] bb = new byte[bbf.position()];
46.75 - bbf.flip(); bbf.get(bb);
46.76 - return bb;
46.77 - }
46.78 -
46.79 - static char[] getChars(Charset newCS, Charset oldCS) {
46.80 - CharsetEncoder enc = oldCS.newEncoder();
46.81 - CharsetEncoder encNew = newCS.newEncoder();
46.82 - char[] cc = new char[0x10000];
46.83 - int pos = 0;
46.84 - int i = 0;
46.85 - while (i < 0x10000) {
46.86 - if (enc.canEncode((char)i) != encNew.canEncode((char)i)) {
46.87 - System.out.printf(" Err i=%x%n", i);
46.88 - //throw new RuntimeException("canEncode() err!");
46.89 - }
46.90 - if (enc.canEncode((char)i)) {
46.91 - cc[pos++] = (char)i;
46.92 - }
46.93 - i++;
46.94 - }
46.95 - return Arrays.copyOf(cc, pos);
46.96 - }
46.97 -
46.98 - static void compare(Charset newCS, Charset oldCS) throws Exception {
46.99 - System.out.printf(" Diff <%s> <%s>...%n", newCS.name(), oldCS.name());
46.100 - char[] cc = getChars(newCS, oldCS);
46.101 -
46.102 - byte[] bb1 = encode(cc, newCS);
46.103 - byte[] bb2 = encode(cc, oldCS);
46.104 -
46.105 - if (!Arrays.equals(bb1, bb2)) {
46.106 - System.out.printf(" encoding failed!%n");
46.107 - }
46.108 - char[] cc1 = decode(bb1, newCS);
46.109 - char[] cc2 = decode(bb1, oldCS);
46.110 - if (!Arrays.equals(cc1, cc2)) {
46.111 - for (int i = 0; i < cc1.length; i++) {
46.112 - if (cc1[i] != cc2[i]) {
46.113 - System.out.printf("i=%d, cc1=%x cc2=%x, bb=<%x%x>%n",
46.114 - i,
46.115 - cc1[i]&0xffff, cc2[i]&0xffff,
46.116 - bb1[i*2]&0xff, bb1[i*2+1]&0xff);
46.117 - }
46.118 -
46.119 - }
46.120 -
46.121 - System.out.printf(" decoding failed%n");
46.122 - }
46.123 - }
46.124 -
46.125 - public static void main(String[] args) throws Exception {
46.126 - compare(new sun.awt.motif.X11GBK(),
46.127 - new X11GBK_OLD());
46.128 -
46.129 - compare(new sun.awt.motif.X11GB2312(),
46.130 - new X11GB2312_OLD());
46.131 -
46.132 - compare(new sun.awt.motif.X11KSC5601(),
46.133 - new X11KSC5601_OLD());
46.134 -
46.135 - }
46.136 -}
47.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
47.2 +++ b/test/sun/security/krb5/auto/Basic.java Wed Mar 21 13:38:55 2012 -0700
47.3 @@ -0,0 +1,56 @@
47.4 +/*
47.5 + * Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved.
47.6 + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
47.7 + *
47.8 + * This code is free software; you can redistribute it and/or modify it
47.9 + * under the terms of the GNU General Public License version 2 only, as
47.10 + * published by the Free Software Foundation.
47.11 + *
47.12 + * This code is distributed in the hope that it will be useful, but WITHOUT
47.13 + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
47.14 + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
47.15 + * version 2 for more details (a copy is included in the LICENSE file that
47.16 + * accompanied this code).
47.17 + *
47.18 + * You should have received a copy of the GNU General Public License version
47.19 + * 2 along with this work; if not, write to the Free Software Foundation,
47.20 + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
47.21 + *
47.22 + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
47.23 + * or visit www.oracle.com if you need additional information or have any
47.24 + * questions.
47.25 + */
47.26 +
47.27 +/*
47.28 + * @test
47.29 + * @bug 7152176
47.30 + * @summary More krb5 tests
47.31 + * @compile -XDignore.symbol.file Basic.java
47.32 + * @run main/othervm Basic
47.33 + */
47.34 +
47.35 +import sun.security.jgss.GSSUtil;
47.36 +
47.37 +// The basic krb5 test skeleton you can copy from
47.38 +public class Basic {
47.39 +
47.40 + public static void main(String[] args) throws Exception {
47.41 +
47.42 + new OneKDC(null).writeJAASConf();
47.43 +
47.44 + Context c, s;
47.45 + c = Context.fromJAAS("client");
47.46 + s = Context.fromJAAS("server");
47.47 +
47.48 + c.startAsClient(OneKDC.SERVER, GSSUtil.GSS_KRB5_MECH_OID);
47.49 + s.startAsServer(GSSUtil.GSS_KRB5_MECH_OID);
47.50 +
47.51 + Context.handshake(c, s);
47.52 +
47.53 + Context.transmit("i say high --", c, s);
47.54 + Context.transmit(" you say low", s, c);
47.55 +
47.56 + s.dispose();
47.57 + c.dispose();
47.58 + }
47.59 +}
48.1 --- a/test/sun/security/krb5/auto/Context.java Wed Mar 21 13:37:24 2012 -0700
48.2 +++ b/test/sun/security/krb5/auto/Context.java Wed Mar 21 13:38:55 2012 -0700
48.3 @@ -96,6 +96,15 @@
48.4 }
48.5
48.6 /**
48.7 + * No JAAS login at all, can be used to test JGSS without JAAS
48.8 + */
48.9 + public static Context fromThinAir() throws Exception {
48.10 + Context out = new Context();
48.11 + out.s = new Subject();
48.12 + return out;
48.13 + }
48.14 +
48.15 + /**
48.16 * Logins with a JAAS login config entry name
48.17 */
48.18 public static Context fromJAAS(final String name) throws Exception {
48.19 @@ -111,8 +120,10 @@
48.20 String user, char[] pass, boolean storeKey) throws Exception {
48.21 return fromUserPass(null, user, pass, storeKey);
48.22 }
48.23 +
48.24 /**
48.25 * Logins with a username and a password, using Krb5LoginModule directly
48.26 + * @param s existing subject, test multiple princ & creds for single subj
48.27 * @param storeKey true if key should be saved, used on acceptor side
48.28 */
48.29 public static Context fromUserPass(Subject s,
49.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
49.2 +++ b/test/sun/security/krb5/auto/GSS.java Wed Mar 21 13:38:55 2012 -0700
49.3 @@ -0,0 +1,60 @@
49.4 +/*
49.5 + * Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved.
49.6 + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
49.7 + *
49.8 + * This code is free software; you can redistribute it and/or modify it
49.9 + * under the terms of the GNU General Public License version 2 only, as
49.10 + * published by the Free Software Foundation.
49.11 + *
49.12 + * This code is distributed in the hope that it will be useful, but WITHOUT
49.13 + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
49.14 + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
49.15 + * version 2 for more details (a copy is included in the LICENSE file that
49.16 + * accompanied this code).
49.17 + *
49.18 + * You should have received a copy of the GNU General Public License version
49.19 + * 2 along with this work; if not, write to the Free Software Foundation,
49.20 + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
49.21 + *
49.22 + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
49.23 + * or visit www.oracle.com if you need additional information or have any
49.24 + * questions.
49.25 + */
49.26 +
49.27 +/*
49.28 + * @test
49.29 + * @bug 7152176
49.30 + * @summary More krb5 tests
49.31 + * @compile -XDignore.symbol.file GSS.java
49.32 + * @run main/othervm GSS
49.33 + */
49.34 +
49.35 +import sun.security.jgss.GSSUtil;
49.36 +
49.37 +// Testing JGSS without JAAS
49.38 +public class GSS {
49.39 +
49.40 + public static void main(String[] args) throws Exception {
49.41 +
49.42 + new OneKDC(null).writeJAASConf();
49.43 +
49.44 + Context c, s;
49.45 + c = Context.fromThinAir();
49.46 + s = Context.fromThinAir();
49.47 +
49.48 + // This is the only setting needed for JGSS without JAAS. The default
49.49 + // JAAS config entries are already created by OneKDC.
49.50 + System.setProperty("javax.security.auth.useSubjectCredsOnly", "false");
49.51 +
49.52 + c.startAsClient(OneKDC.SERVER, GSSUtil.GSS_KRB5_MECH_OID);
49.53 + s.startAsServer(GSSUtil.GSS_KRB5_MECH_OID);
49.54 +
49.55 + Context.handshake(c, s);
49.56 +
49.57 + Context.transmit("i say high --", c, s);
49.58 + Context.transmit(" you say low", s, c);
49.59 +
49.60 + s.dispose();
49.61 + c.dispose();
49.62 + }
49.63 +}
50.1 --- a/test/sun/security/krb5/auto/KDC.java Wed Mar 21 13:37:24 2012 -0700
50.2 +++ b/test/sun/security/krb5/auto/KDC.java Wed Mar 21 13:38:55 2012 -0700
50.3 @@ -236,80 +236,82 @@
50.4 }
50.5
50.6 /**
50.7 - * Writes or appends KDC keys into a keytab. See doc for writeMultiKtab.
50.8 + * Writes or appends keys into a keytab.
50.9 + * <p>
50.10 + * Attention: This is the most basic one of a series of methods below on
50.11 + * keytab creation or modification. All these methods reference krb5.conf
50.12 + * settings. If you need to modify krb5.conf or switch to another krb5.conf
50.13 + * later, please call <code>Config.refresh()</code> again. For example:
50.14 + * <pre>
50.15 + * kdc.writeKtab("/etc/kdc/ktab", true); // Config is initialized,
50.16 + * System.setProperty("java.security.krb5.conf", "/home/mykrb5.conf");
50.17 + * Config.refresh();
50.18 + * </pre>
50.19 + * Inside this method there are 2 places krb5.conf is used:
50.20 + * <ol>
50.21 + * <li> (Fatal) Generating keys: EncryptionKey.acquireSecretKeys
50.22 + * <li> (Has workaround) Creating PrincipalName
50.23 + * </ol>
50.24 + * @param tab the keytab file name
50.25 * @param append true if append, otherwise, overwrite.
50.26 + * @param names the names to write into, write all if names is empty
50.27 */
50.28 - private static void writeKtab0(String tab, boolean append, KDC... kdcs)
50.29 + public void writeKtab(String tab, boolean append, String... names)
50.30 throws IOException, KrbException {
50.31 KeyTab ktab = append ? KeyTab.getInstance(tab) : KeyTab.create(tab);
50.32 - for (KDC kdc: kdcs) {
50.33 - for (String name : kdc.passwords.keySet()) {
50.34 - char[] pass = kdc.passwords.get(name);
50.35 - int kvno = 0;
50.36 - if (Character.isDigit(pass[pass.length-1])) {
50.37 - kvno = pass[pass.length-1] - '0';
50.38 - }
50.39 - ktab.addEntry(new PrincipalName(name,
50.40 - name.indexOf('/') < 0 ?
50.41 - PrincipalName.KRB_NT_UNKNOWN :
50.42 - PrincipalName.KRB_NT_SRV_HST),
50.43 - pass,
50.44 - kvno,
50.45 - true);
50.46 + Iterable<String> entries =
50.47 + (names.length != 0) ? Arrays.asList(names): passwords.keySet();
50.48 + for (String name : entries) {
50.49 + char[] pass = passwords.get(name);
50.50 + int kvno = 0;
50.51 + if (Character.isDigit(pass[pass.length-1])) {
50.52 + kvno = pass[pass.length-1] - '0';
50.53 }
50.54 + ktab.addEntry(new PrincipalName(name,
50.55 + name.indexOf('/') < 0 ?
50.56 + PrincipalName.KRB_NT_UNKNOWN :
50.57 + PrincipalName.KRB_NT_SRV_HST),
50.58 + pass,
50.59 + kvno,
50.60 + true);
50.61 }
50.62 ktab.save();
50.63 }
50.64
50.65 /**
50.66 * Writes all principals' keys from multiple KDCs into one keytab file.
50.67 - * Note that the keys for the krbtgt principals will not be written.
50.68 - * <p>
50.69 - * Attention: This method references krb5.conf settings. If you need to
50.70 - * setup krb5.conf later, please call <code>Config.refresh()</code> after
50.71 - * the new setting. For example:
50.72 - * <pre>
50.73 - * KDC.writeKtab("/etc/kdc/ktab", kdc); // Config is initialized,
50.74 - * System.setProperty("java.security.krb5.conf", "/home/mykrb5.conf");
50.75 - * Config.refresh();
50.76 - * </pre>
50.77 - *
50.78 - * Inside this method there are 2 places krb5.conf is used:
50.79 - * <ol>
50.80 - * <li> (Fatal) Generating keys: EncryptionKey.acquireSecretKeys
50.81 - * <li> (Has workaround) Creating PrincipalName
50.82 - * </ol>
50.83 - * @param tab The keytab filename to write to.
50.84 * @throws java.io.IOException for any file output error
50.85 * @throws sun.security.krb5.KrbException for any realm and/or principal
50.86 * name error.
50.87 */
50.88 public static void writeMultiKtab(String tab, KDC... kdcs)
50.89 throws IOException, KrbException {
50.90 - writeKtab0(tab, false, kdcs);
50.91 + KeyTab.create(tab).save(); // Empty the old keytab
50.92 + appendMultiKtab(tab, kdcs);
50.93 }
50.94
50.95 /**
50.96 * Appends all principals' keys from multiple KDCs to one keytab file.
50.97 - * See writeMultiKtab for details.
50.98 */
50.99 public static void appendMultiKtab(String tab, KDC... kdcs)
50.100 throws IOException, KrbException {
50.101 - writeKtab0(tab, true, kdcs);
50.102 + for (KDC kdc: kdcs) {
50.103 + kdc.writeKtab(tab, true);
50.104 + }
50.105 }
50.106
50.107 /**
50.108 * Write a ktab for this KDC.
50.109 */
50.110 public void writeKtab(String tab) throws IOException, KrbException {
50.111 - KDC.writeMultiKtab(tab, this);
50.112 + writeKtab(tab, false);
50.113 }
50.114
50.115 /**
50.116 * Appends keys in this KDC to a ktab.
50.117 */
50.118 public void appendKtab(String tab) throws IOException, KrbException {
50.119 - KDC.appendMultiKtab(tab, this);
50.120 + writeKtab(tab, true);
50.121 }
50.122
50.123 /**
51.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
51.2 +++ b/test/sun/security/krb5/auto/TwoTab.java Wed Mar 21 13:38:55 2012 -0700
51.3 @@ -0,0 +1,99 @@
51.4 +/*
51.5 + * Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved.
51.6 + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
51.7 + *
51.8 + * This code is free software; you can redistribute it and/or modify it
51.9 + * under the terms of the GNU General Public License version 2 only, as
51.10 + * published by the Free Software Foundation.
51.11 + *
51.12 + * This code is distributed in the hope that it will be useful, but WITHOUT
51.13 + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
51.14 + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
51.15 + * version 2 for more details (a copy is included in the LICENSE file that
51.16 + * accompanied this code).
51.17 + *
51.18 + * You should have received a copy of the GNU General Public License version
51.19 + * 2 along with this work; if not, write to the Free Software Foundation,
51.20 + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
51.21 + *
51.22 + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
51.23 + * or visit www.oracle.com if you need additional information or have any
51.24 + * questions.
51.25 + */
51.26 +
51.27 +/*
51.28 + * @test
51.29 + * @bug 7152176
51.30 + * @summary More krb5 tests
51.31 + * @compile -XDignore.symbol.file TwoTab.java
51.32 + * @run main/othervm TwoTab
51.33 + */
51.34 +
51.35 +import java.io.File;
51.36 +import java.io.FileOutputStream;
51.37 +import java.nio.file.Files;
51.38 +import java.security.Security;
51.39 +import sun.security.jgss.GSSUtil;
51.40 +import sun.security.krb5.PrincipalName;
51.41 +import sun.security.krb5.internal.ktab.KeyTab;
51.42 +
51.43 +// Two services using their own keytab.
51.44 +public class TwoTab {
51.45 +
51.46 + public static void main(String[] args) throws Exception {
51.47 +
51.48 + KDC k = new OneKDC(null);
51.49 +
51.50 + // Write JAAS conf, two service using different keytabs
51.51 + System.setProperty("java.security.auth.login.config", OneKDC.JAAS_CONF);
51.52 + File f = new File(OneKDC.JAAS_CONF);
51.53 + try (FileOutputStream fos = new FileOutputStream(f)) {
51.54 + fos.write((
51.55 + "server {\n" +
51.56 + " com.sun.security.auth.module.Krb5LoginModule required\n" +
51.57 + " principal=\"" + OneKDC.SERVER + "\"\n" +
51.58 + " useKeyTab=true\n" +
51.59 + " keyTab=server.keytab\n" +
51.60 + " storeKey=true;\n};\n" +
51.61 + "server2 {\n" +
51.62 + " com.sun.security.auth.module.Krb5LoginModule required\n" +
51.63 + " principal=\"" + OneKDC.BACKEND + "\"\n" +
51.64 + " useKeyTab=true\n" +
51.65 + " keyTab=backend.keytab\n" +
51.66 + " storeKey=true;\n};\n"
51.67 + ).getBytes());
51.68 + }
51.69 + f.deleteOnExit();
51.70 +
51.71 + k.writeKtab("server.keytab", false, "server/host.rabbit.hole@RABBIT.HOLE");
51.72 + k.writeKtab("backend.keytab", false, "backend/host.rabbit.hole@RABBIT.HOLE");
51.73 +
51.74 + Context c, s, s2;
51.75 + c = Context.fromUserPass(OneKDC.USER, OneKDC.PASS, false);
51.76 + s = Context.fromJAAS("server");
51.77 + s2 = Context.fromJAAS("server2");
51.78 +
51.79 + c.startAsClient(OneKDC.SERVER, GSSUtil.GSS_KRB5_MECH_OID);
51.80 + s.startAsServer(GSSUtil.GSS_KRB5_MECH_OID);
51.81 +
51.82 + Context.handshake(c, s);
51.83 +
51.84 + Context.transmit("i say high --", c, s);
51.85 + Context.transmit(" you say low", s, c);
51.86 +
51.87 + s.dispose();
51.88 + c.dispose();
51.89 +
51.90 + c = Context.fromUserPass(OneKDC.USER, OneKDC.PASS, false);
51.91 + c.startAsClient(OneKDC.BACKEND, GSSUtil.GSS_KRB5_MECH_OID);
51.92 + s2.startAsServer(GSSUtil.GSS_KRB5_MECH_OID);
51.93 +
51.94 + Context.handshake(c, s2);
51.95 +
51.96 + Context.transmit("i say high --", c, s2);
51.97 + Context.transmit(" you say low", s2, c);
51.98 +
51.99 + s2.dispose();
51.100 + c.dispose();
51.101 + }
51.102 +}
52.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
52.2 +++ b/test/sun/security/pkcs11/KeyAgreement/TestInterop.java Wed Mar 21 13:38:55 2012 -0700
52.3 @@ -0,0 +1,143 @@
52.4 +/*
52.5 + * Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved.
52.6 + * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
52.7 + *
52.8 + * This code is free software; you can redistribute it and/or modify it
52.9 + * under the terms of the GNU General Public License version 2 only, as
52.10 + * published by the Free Software Foundation.
52.11 + *
52.12 + * This code is distributed in the hope that it will be useful, but WITHOUT
52.13 + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
52.14 + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
52.15 + * version 2 for more details (a copy is included in the LICENSE file that
52.16 + * accompanied this code).
52.17 + *
52.18 + * You should have received a copy of the GNU General Public License version
52.19 + * 2 along with this work; if not, write to the Free Software Foundation,
52.20 + * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
52.21 + *
52.22 + * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
52.23 + * or visit www.oracle.com if you need additional information or have any
52.24 + * questions.
52.25 + */
52.26 +
52.27 +/**
52.28 + * @test
52.29 + * @bug 7146728
52.30 + * @summary Interop test for DH with secret that has a leading 0x00 byte
52.31 + * @library ..
52.32 + */
52.33 +import java.math.BigInteger;
52.34 +import java.util.*;
52.35 +
52.36 +import java.security.*;
52.37 +
52.38 +import javax.crypto.*;
52.39 +import javax.crypto.spec.*;
52.40 +
52.41 +public class TestInterop extends PKCS11Test {
52.42 +
52.43 + private final static BigInteger p = new BigInteger
52.44 + ("171718397966129586011229151993178480901904202533705695869569760169920539"
52.45 + + "80807543778874708672297590042574075430109846864794139516459381007417046"
52.46 + + "27996080624930219892858374168155487210358743785481212360509485282294161"
52.47 + + "39585571568998066586304075565145536350296006867635076744949977849997684"
52.48 + + "222020336013226588207303");
52.49 +
52.50 + private final static BigInteger g = new BigInteger("2");
52.51 +
52.52 + private final static BigInteger ya = new BigInteger
52.53 + ("687709211571508809414670982463565909269384277848448625781941269577397703"
52.54 + + "73675199968849153119146758339814638228795348558483510369322822476757204"
52.55 + + "22158455966026517829008713407587339322132253724742557954802911059639161"
52.56 + + "24827916158465757962384625410294483756242900146397201260757102085985457"
52.57 + + "09397033481077351036224");
52.58 +
52.59 + private final static BigInteger xa = new BigInteger
52.60 + ("104917367119952955556289227181599819745346393858545449202252025137706135"
52.61 + + "98100778613457655440586438263591136003106529323555991109623536177695714"
52.62 + + "66884181531401472902830508361532232717792847436112280721439936797741371"
52.63 + + "245140912614191507");
52.64 +
52.65 + private final static BigInteger yb = new BigInteger
52.66 + ("163887874871842952463100699681506173424091615364591742415764095471629919"
52.67 + + "08421025296419917755446931473037086355546823601999684501737493240373415"
52.68 + + "65608293667837249198973539289354492348897732633852665609611113031379864"
52.69 + + "58514616034107537409230452318065341748503347627733368519091332060477528"
52.70 + + "173423377887175351037810");
52.71 +
52.72 + private final static BigInteger xb = new BigInteger
52.73 + ("127757517533485947079959908591028646859165238853082197617179368337276371"
52.74 + + "51601819447716934542027725311863797141734616730248519214531856941516613"
52.75 + + "30313414180008978013330410484011186019824874948204261839391153650949864"
52.76 + + "429505597086564709");
52.77 +
52.78 + public void main(Provider prov) throws Exception {
52.79 + if (prov.getService("KeyAgreement", "DH") == null) {
52.80 + System.out.println("DH not supported, skipping");
52.81 + return;
52.82 + }
52.83 + try {
52.84 + System.out.println("testing generateSecret()");
52.85 +
52.86 + DHPublicKeySpec publicSpec;
52.87 + DHPrivateKeySpec privateSpec;
52.88 + KeyFactory kf = KeyFactory.getInstance("DH");
52.89 + KeyAgreement ka = KeyAgreement.getInstance("DH", prov);
52.90 + KeyAgreement kbSunJCE = KeyAgreement.getInstance("DH", "SunJCE");
52.91 + DHPrivateKeySpec privSpecA = new DHPrivateKeySpec(xa, p, g);
52.92 + DHPublicKeySpec pubSpecA = new DHPublicKeySpec(ya, p, g);
52.93 + PrivateKey privA = kf.generatePrivate(privSpecA);
52.94 + PublicKey pubA = kf.generatePublic(pubSpecA);
52.95 +
52.96 + DHPrivateKeySpec privSpecB = new DHPrivateKeySpec(xb, p, g);
52.97 + DHPublicKeySpec pubSpecB = new DHPublicKeySpec(yb, p, g);
52.98 + PrivateKey privB = kf.generatePrivate(privSpecB);
52.99 + PublicKey pubB = kf.generatePublic(pubSpecB);
52.100 +
52.101 + ka.init(privA);
52.102 + ka.doPhase(pubB, true);
52.103 + byte[] n1 = ka.generateSecret();
52.104 +
52.105 + kbSunJCE.init(privB);
52.106 + kbSunJCE.doPhase(pubA, true);
52.107 + byte[] n2 = kbSunJCE.generateSecret();
52.108 +
52.109 + if (Arrays.equals(n1, n2) == false) {
52.110 + throw new Exception("values mismatch!");
52.111 + } else {
52.112 + System.out.println("values: same");
52.113 + }
52.114 +
52.115 + System.out.println("testing generateSecret(byte[], int)");
52.116 + byte[] n3 = new byte[n1.length];
52.117 + ka.init(privB);
52.118 + ka.doPhase(pubA, true);
52.119 + int n3Len = ka.generateSecret(n3, 0);
52.120 + if (n3Len != n3.length) {
52.121 + throw new Exception("PKCS11 Length mismatch!");
52.122 + } else System.out.println("PKCS11 Length: ok");
52.123 + byte[] n4 = new byte[n2.length];
52.124 + kbSunJCE.init(privA);
52.125 + kbSunJCE.doPhase(pubB, true);
52.126 + int n4Len = kbSunJCE.generateSecret(n4, 0);
52.127 + if (n4Len != n4.length) {
52.128 + throw new Exception("SunJCE Length mismatch!");
52.129 + } else System.out.println("SunJCE Length: ok");
52.130 +
52.131 + if (Arrays.equals(n3, n4) == false) {
52.132 + throw new Exception("values mismatch! ");
52.133 + } else {
52.134 + System.out.println("values: same");
52.135 + }
52.136 + } catch (Exception ex) {
52.137 + System.out.println("Unexpected ex: " + ex);
52.138 + ex.printStackTrace();
52.139 + throw ex;
52.140 + }
52.141 + }
52.142 +
52.143 + public static void main(String[] args) throws Exception {
52.144 + main(new TestInterop());
52.145 + }
52.146 +}
53.1 --- a/test/sun/security/pkcs11/KeyAgreement/TestShort.java Wed Mar 21 13:37:24 2012 -0700
53.2 +++ b/test/sun/security/pkcs11/KeyAgreement/TestShort.java Wed Mar 21 13:38:55 2012 -0700
53.3 @@ -1,5 +1,5 @@
53.4 /*
53.5 - * Copyright (c) 2003, Oracle and/or its affiliates. All rights reserved.
53.6 + * Copyright (c) 2003, 2012, Oracle and/or its affiliates. All rights reserved.
53.7 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
53.8 *
53.9 * This code is free software; you can redistribute it and/or modify it
53.10 @@ -23,7 +23,7 @@
53.11
53.12 /**
53.13 * @test
53.14 - * @bug 4942494
53.15 + * @bug 4942494 7146728
53.16 * @summary KAT test for DH (normal and with secret that has leading a 0x00 byte)
53.17 * @author Andreas Sterbenz
53.18 * @library ..
53.19 @@ -66,7 +66,7 @@
53.20 ("433011588852527167500079509018272713204454720683");
53.21
53.22 private final static byte[] s2 = parse
53.23 - ("19:c7:f1:bb:2e:3d:93:fa:02:d2:e9:9f:75:32:b9:e6:7a:a0:4a:10:45:81:d4:2b:"
53.24 + ("00:19:c7:f1:bb:2e:3d:93:fa:02:d2:e9:9f:75:32:b9:e6:7a:a0:4a:10:45:81:d4:2b:"
53.25 + "e2:77:4c:70:41:39:7c:19:fa:65:64:47:49:8a:ad:0a:fa:9d:e9:62:68:97:c5:52"
53.26 + ":b1:37:03:d9:cd:aa:e1:bd:7e:71:0c:fc:15:a1:95");
53.27
53.28 @@ -88,31 +88,36 @@
53.29 System.out.println("DH not supported, skipping");
53.30 return;
53.31 }
53.32 - DHPublicKeySpec publicSpec;
53.33 - DHPrivateKeySpec privateSpec;
53.34 - KeyFactory kf = KeyFactory.getInstance("DH", provider);
53.35 - KeyAgreement ka = KeyAgreement.getInstance("DH", provider);
53.36 -// KeyAgreement ka = KeyAgreement.getInstance("DH");
53.37 + try {
53.38 + DHPublicKeySpec publicSpec;
53.39 + DHPrivateKeySpec privateSpec;
53.40 + KeyFactory kf = KeyFactory.getInstance("DH", provider);
53.41 + KeyAgreement ka = KeyAgreement.getInstance("DH", provider);
53.42
53.43 - PrivateKey pr1 = kf.generatePrivate(new DHPrivateKeySpec(x1, p, g));
53.44 - PublicKey pu2 = kf.generatePublic(new DHPublicKeySpec(y2, p, g));
53.45 - PublicKey pu3 = kf.generatePublic(new DHPublicKeySpec(y3, p, g));
53.46 + PrivateKey pr1 = kf.generatePrivate(new DHPrivateKeySpec(x1, p, g));
53.47 + PublicKey pu2 = kf.generatePublic(new DHPublicKeySpec(y2, p, g));
53.48 + PublicKey pu3 = kf.generatePublic(new DHPublicKeySpec(y3, p, g));
53.49
53.50 - ka.init(pr1);
53.51 - ka.doPhase(pu2, true);
53.52 - byte[] n2 = ka.generateSecret();
53.53 - if (Arrays.equals(s2, n2) == false) {
53.54 - throw new Exception("mismatch 2");
53.55 + ka.init(pr1);
53.56 + ka.doPhase(pu2, true);
53.57 + byte[] n2 = ka.generateSecret();
53.58 + if (Arrays.equals(s2, n2) == false) {
53.59 + throw new Exception("mismatch 2");
53.60 + }
53.61 + System.out.println("short ok");
53.62 +
53.63 + ka.init(pr1);
53.64 + ka.doPhase(pu3, true);
53.65 + byte[] n3 = ka.generateSecret();
53.66 + if (Arrays.equals(s3, n3) == false) {
53.67 + throw new Exception("mismatch 3");
53.68 + }
53.69 + System.out.println("normal ok");
53.70 + } catch (Exception ex) {
53.71 + System.out.println("Unexpected Exception: " + ex);
53.72 + ex.printStackTrace();
53.73 + throw ex;
53.74 }
53.75 - System.out.println("short ok");
53.76 -
53.77 - ka.init(pr1);
53.78 - ka.doPhase(pu3, true);
53.79 - byte[] n3 = ka.generateSecret();
53.80 - if (Arrays.equals(s3, n3) == false) {
53.81 - throw new Exception("mismatch 3");
53.82 - }
53.83 - System.out.println("normal ok");
53.84
53.85 /*
53.86 KeyPairGenerator kpg = KeyPairGenerator.getInstance("DH", provider);
54.1 --- a/test/sun/security/ssl/com/sun/net/ssl/SSLSecurity/ProviderTest.java Wed Mar 21 13:37:24 2012 -0700
54.2 +++ b/test/sun/security/ssl/com/sun/net/ssl/SSLSecurity/ProviderTest.java Wed Mar 21 13:38:55 2012 -0700
54.3 @@ -27,6 +27,7 @@
54.4 * @compile JavaxSSLContextImpl.java ComSSLContextImpl.java
54.5 * JavaxTrustManagerFactoryImpl.java ComTrustManagerFactoryImpl.java
54.6 * JavaxKeyManagerFactoryImpl.java ComKeyManagerFactoryImpl.java
54.7 + * @run main ProviderTest
54.8 * @summary brokenness in the com.sun.net.ssl.SSLSecurity wrappers
54.9 */
54.10
55.1 --- a/test/sun/tools/jcmd/jcmd_Output1.awk Wed Mar 21 13:37:24 2012 -0700
55.2 +++ b/test/sun/tools/jcmd/jcmd_Output1.awk Wed Mar 21 13:38:55 2012 -0700
55.3 @@ -20,6 +20,11 @@
55.4 current=1;
55.5 }
55.6
55.7 +# or match an empty class name
55.8 +/^[0-9]+ $/ {
55.9 + current=1;
55.10 + }
55.11 +
55.12 { totallines++; matched+=current; current=0; print $0 }
55.13
55.14 END {
56.1 --- a/test/sun/tools/jps/jps-l_Output1.awk Wed Mar 21 13:37:24 2012 -0700
56.2 +++ b/test/sun/tools/jps/jps-l_Output1.awk Wed Mar 21 13:38:55 2012 -0700
56.3 @@ -20,6 +20,11 @@
56.4 matched++;
56.5 }
56.6
56.7 +# or match an empty class name
56.8 +/^[0-9]+ $/ {
56.9 + matched++;
56.10 + }
56.11 +
56.12 { totallines++; print $0 }
56.13
56.14 END {
57.1 --- a/test/sun/tools/jps/jps_Output1.awk Wed Mar 21 13:37:24 2012 -0700
57.2 +++ b/test/sun/tools/jps/jps_Output1.awk Wed Mar 21 13:38:55 2012 -0700
57.3 @@ -20,6 +20,11 @@
57.4 matched++;
57.5 }
57.6
57.7 +# or match an empty class name
57.8 +/^[0-9]+ $/ {
57.9 + matched++;
57.10 + }
57.11 +
57.12 { totallines++; print $0 }
57.13
57.14 END {
58.1 --- a/test/sun/tools/jstat/jstatClassOutput1.sh Wed Mar 21 13:37:24 2012 -0700
58.2 +++ b/test/sun/tools/jstat/jstatClassOutput1.sh Wed Mar 21 13:38:55 2012 -0700
58.3 @@ -1,5 +1,5 @@
58.4 #
58.5 -# Copyright (c) 2004, 2011, Oracle and/or its affiliates. All rights reserved.
58.6 +# Copyright (c) 2004, 2012, Oracle and/or its affiliates. All rights reserved.
58.7 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
58.8 #
58.9 # This code is free software; you can redistribute it and/or modify it
58.10 @@ -33,4 +33,4 @@
58.11
58.12 JSTAT="${TESTJAVA}/bin/jstat"
58.13
58.14 -${JSTAT} -J-XX:+UsePerfData -class 0 2>&1 | awk -f ${TESTSRC}/classOutput1.awk
58.15 +${JSTAT} -J-XX:+UsePerfData -J-Duser.language=en -class 0 2>&1 | awk -f ${TESTSRC}/classOutput1.awk
59.1 --- a/test/sun/tools/jstat/jstatClassloadOutput1.sh Wed Mar 21 13:37:24 2012 -0700
59.2 +++ b/test/sun/tools/jstat/jstatClassloadOutput1.sh Wed Mar 21 13:38:55 2012 -0700
59.3 @@ -1,5 +1,5 @@
59.4 #
59.5 -# Copyright (c) 2010, 2011, Oracle and/or its affiliates. All rights reserved.
59.6 +# Copyright (c) 2010, 2012, Oracle and/or its affiliates. All rights reserved.
59.7 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
59.8 #
59.9 # This code is free software; you can redistribute it and/or modify it
59.10 @@ -33,4 +33,4 @@
59.11
59.12 JSTAT="${TESTJAVA}/bin/jstat"
59.13
59.14 -${JSTAT} -J-XX:+UsePerfData -classload -J-Djstat.showUnsupported=true 0 2>&1 | awk -f ${TESTSRC}/classloadOutput1.awk
59.15 +${JSTAT} -J-XX:+UsePerfData -J-Duser.language=en -classload -J-Djstat.showUnsupported=true 0 2>&1 | awk -f ${TESTSRC}/classloadOutput1.awk
60.1 --- a/test/sun/tools/jstat/jstatCompilerOutput1.sh Wed Mar 21 13:37:24 2012 -0700
60.2 +++ b/test/sun/tools/jstat/jstatCompilerOutput1.sh Wed Mar 21 13:38:55 2012 -0700
60.3 @@ -1,5 +1,5 @@
60.4 #
60.5 -# Copyright (c) 2004, 2011, Oracle and/or its affiliates. All rights reserved.
60.6 +# Copyright (c) 2004, 2012, Oracle and/or its affiliates. All rights reserved.
60.7 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
60.8 #
60.9 # This code is free software; you can redistribute it and/or modify it
60.10 @@ -33,4 +33,4 @@
60.11
60.12 JSTAT="${TESTJAVA}/bin/jstat"
60.13
60.14 -${JSTAT} -J-XX:+UsePerfData -compiler 0 2>&1 | awk -f ${TESTSRC}/compilerOutput1.awk
60.15 +${JSTAT} -J-XX:+UsePerfData -J-Duser.language=en -compiler 0 2>&1 | awk -f ${TESTSRC}/compilerOutput1.awk
61.1 --- a/test/sun/tools/jstat/jstatFileURITest1.sh Wed Mar 21 13:37:24 2012 -0700
61.2 +++ b/test/sun/tools/jstat/jstatFileURITest1.sh Wed Mar 21 13:38:55 2012 -0700
61.3 @@ -1,5 +1,5 @@
61.4 #
61.5 -# Copyright (c) 2004, 2011, Oracle and/or its affiliates. All rights reserved.
61.6 +# Copyright (c) 2004, 2012, Oracle and/or its affiliates. All rights reserved.
61.7 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
61.8 #
61.9 # This code is free software; you can redistribute it and/or modify it
61.10 @@ -40,12 +40,12 @@
61.11 # characters into forward slash characters in an effort to convert
61.12 # TESTSRC into a canonical form useable as URI path.
61.13 cp ${TESTSRC}/hsperfdata_3433 .
61.14 - ${JSTAT} -J-XX:+UsePerfData -gcutil file:/`pwd`/hsperfdata_3433 2>&1 | awk -f ${TESTSRC}/fileURITest1.awk
61.15 + ${JSTAT} -J-XX:+UsePerfData -J-Duser.language=en -gcutil file:/`pwd`/hsperfdata_3433 2>&1 | awk -f ${TESTSRC}/fileURITest1.awk
61.16 RC=$?
61.17 rm -f hsperfdata_3433 2>&1 > /dev/null
61.18 ;;
61.19 *)
61.20 - ${JSTAT} -J-XX:+UsePerfData -gcutil file:${TESTSRC}/hsperfdata_3433 2>&1 | awk -f ${TESTSRC}/fileURITest1.awk
61.21 + ${JSTAT} -J-XX:+UsePerfData -J-Duser.language=en -gcutil file:${TESTSRC}/hsperfdata_3433 2>&1 | awk -f ${TESTSRC}/fileURITest1.awk
61.22 RC=$?
61.23 ;;
61.24 esac
62.1 --- a/test/sun/tools/jstat/jstatGcCapacityOutput1.sh Wed Mar 21 13:37:24 2012 -0700
62.2 +++ b/test/sun/tools/jstat/jstatGcCapacityOutput1.sh Wed Mar 21 13:38:55 2012 -0700
62.3 @@ -1,5 +1,5 @@
62.4 #
62.5 -# Copyright (c) 2004, 2011, Oracle and/or its affiliates. All rights reserved.
62.6 +# Copyright (c) 2004, 2012, Oracle and/or its affiliates. All rights reserved.
62.7 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
62.8 #
62.9 # This code is free software; you can redistribute it and/or modify it
62.10 @@ -33,4 +33,4 @@
62.11
62.12 JSTAT="${TESTJAVA}/bin/jstat"
62.13
62.14 -${JSTAT} -J-XX:+UsePerfData -gccapacity 0 2>&1 | awk -f ${TESTSRC}/gcCapacityOutput1.awk
62.15 +${JSTAT} -J-XX:+UsePerfData -J-Duser.language=en -gccapacity 0 2>&1 | awk -f ${TESTSRC}/gcCapacityOutput1.awk
63.1 --- a/test/sun/tools/jstat/jstatGcCauseOutput1.sh Wed Mar 21 13:37:24 2012 -0700
63.2 +++ b/test/sun/tools/jstat/jstatGcCauseOutput1.sh Wed Mar 21 13:38:55 2012 -0700
63.3 @@ -1,5 +1,5 @@
63.4 #
63.5 -# Copyright (c) 2004, 2011, Oracle and/or its affiliates. All rights reserved.
63.6 +# Copyright (c) 2004, 2012, Oracle and/or its affiliates. All rights reserved.
63.7 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
63.8 #
63.9 # This code is free software; you can redistribute it and/or modify it
63.10 @@ -37,4 +37,4 @@
63.11 # class machine, ergonomics will automatically use UseParallelGC.
63.12 # The UseParallelGC collector does not currently update the gc cause counters.
63.13
63.14 -${JSTAT} -J-XX:+UsePerfData -J-XX:+UseSerialGC -gccause 0 2>&1 | awk -f ${TESTSRC}/gcCauseOutput1.awk
63.15 +${JSTAT} -J-XX:+UsePerfData -J-Duser.language=en -J-XX:+UseSerialGC -gccause 0 2>&1 | awk -f ${TESTSRC}/gcCauseOutput1.awk
64.1 --- a/test/sun/tools/jstat/jstatGcNewCapacityOutput1.sh Wed Mar 21 13:37:24 2012 -0700
64.2 +++ b/test/sun/tools/jstat/jstatGcNewCapacityOutput1.sh Wed Mar 21 13:38:55 2012 -0700
64.3 @@ -1,5 +1,5 @@
64.4 #
64.5 -# Copyright (c) 2004, 2011, Oracle and/or its affiliates. All rights reserved.
64.6 +# Copyright (c) 2004, 2012, Oracle and/or its affiliates. All rights reserved.
64.7 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
64.8 #
64.9 # This code is free software; you can redistribute it and/or modify it
64.10 @@ -33,4 +33,4 @@
64.11
64.12 JSTAT="${TESTJAVA}/bin/jstat"
64.13
64.14 -${JSTAT} -J-XX:+UsePerfData -gcnewcapacity 0 2>&1 | awk -f ${TESTSRC}/gcNewCapacityOutput1.awk
64.15 +${JSTAT} -J-XX:+UsePerfData -J-Duser.language=en -gcnewcapacity 0 2>&1 | awk -f ${TESTSRC}/gcNewCapacityOutput1.awk
65.1 --- a/test/sun/tools/jstat/jstatGcNewOutput1.sh Wed Mar 21 13:37:24 2012 -0700
65.2 +++ b/test/sun/tools/jstat/jstatGcNewOutput1.sh Wed Mar 21 13:38:55 2012 -0700
65.3 @@ -1,5 +1,5 @@
65.4 #
65.5 -# Copyright (c) 2004, 2011, Oracle and/or its affiliates. All rights reserved.
65.6 +# Copyright (c) 2004, 2012, Oracle and/or its affiliates. All rights reserved.
65.7 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
65.8 #
65.9 # This code is free software; you can redistribute it and/or modify it
65.10 @@ -33,4 +33,4 @@
65.11
65.12 JSTAT="${TESTJAVA}/bin/jstat"
65.13
65.14 -${JSTAT} -J-XX:+UsePerfData -gcnew 0 2>&1 | awk -f ${TESTSRC}/gcNewOutput1.awk
65.15 +${JSTAT} -J-XX:+UsePerfData -J-Duser.language=en -gcnew 0 2>&1 | awk -f ${TESTSRC}/gcNewOutput1.awk
66.1 --- a/test/sun/tools/jstat/jstatGcOldCapacityOutput1.sh Wed Mar 21 13:37:24 2012 -0700
66.2 +++ b/test/sun/tools/jstat/jstatGcOldCapacityOutput1.sh Wed Mar 21 13:38:55 2012 -0700
66.3 @@ -1,5 +1,5 @@
66.4 #
66.5 -# Copyright (c) 2004, 2011, Oracle and/or its affiliates. All rights reserved.
66.6 +# Copyright (c) 2004, 2012, Oracle and/or its affiliates. All rights reserved.
66.7 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
66.8 #
66.9 # This code is free software; you can redistribute it and/or modify it
66.10 @@ -33,4 +33,4 @@
66.11
66.12 JSTAT="${TESTJAVA}/bin/jstat"
66.13
66.14 -${JSTAT} -J-XX:+UsePerfData -gcoldcapacity 0 2>&1 | awk -f ${TESTSRC}/gcOldCapacityOutput1.awk
66.15 +${JSTAT} -J-XX:+UsePerfData -J-Duser.language=en -gcoldcapacity 0 2>&1 | awk -f ${TESTSRC}/gcOldCapacityOutput1.awk
67.1 --- a/test/sun/tools/jstat/jstatGcOldOutput1.sh Wed Mar 21 13:37:24 2012 -0700
67.2 +++ b/test/sun/tools/jstat/jstatGcOldOutput1.sh Wed Mar 21 13:38:55 2012 -0700
67.3 @@ -1,5 +1,5 @@
67.4 #
67.5 -# Copyright (c) 2004, 2011, Oracle and/or its affiliates. All rights reserved.
67.6 +# Copyright (c) 2004, 2012, Oracle and/or its affiliates. All rights reserved.
67.7 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
67.8 #
67.9 # This code is free software; you can redistribute it and/or modify it
67.10 @@ -33,4 +33,4 @@
67.11
67.12 JSTAT="${TESTJAVA}/bin/jstat"
67.13
67.14 -${JSTAT} -J-XX:+UsePerfData -gcold 0 2>&1 | awk -f ${TESTSRC}/gcOldOutput1.awk
67.15 +${JSTAT} -J-XX:+UsePerfData -J-Duser.language=en -gcold 0 2>&1 | awk -f ${TESTSRC}/gcOldOutput1.awk
68.1 --- a/test/sun/tools/jstat/jstatGcOutput1.sh Wed Mar 21 13:37:24 2012 -0700
68.2 +++ b/test/sun/tools/jstat/jstatGcOutput1.sh Wed Mar 21 13:38:55 2012 -0700
68.3 @@ -1,5 +1,5 @@
68.4 #
68.5 -# Copyright (c) 2004, 2011, Oracle and/or its affiliates. All rights reserved.
68.6 +# Copyright (c) 2004, 2012, Oracle and/or its affiliates. All rights reserved.
68.7 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
68.8 #
68.9 # This code is free software; you can redistribute it and/or modify it
68.10 @@ -33,4 +33,4 @@
68.11
68.12 JSTAT="${TESTJAVA}/bin/jstat"
68.13
68.14 -${JSTAT} -J-XX:+UsePerfData -gc 0 2>&1 | awk -f ${TESTSRC}/gcOutput1.awk
68.15 +${JSTAT} -J-XX:+UsePerfData -J-Duser.language=en -gc 0 2>&1 | awk -f ${TESTSRC}/gcOutput1.awk
69.1 --- a/test/sun/tools/jstat/jstatGcPermCapacityOutput1.sh Wed Mar 21 13:37:24 2012 -0700
69.2 +++ b/test/sun/tools/jstat/jstatGcPermCapacityOutput1.sh Wed Mar 21 13:38:55 2012 -0700
69.3 @@ -1,5 +1,5 @@
69.4 #
69.5 -# Copyright (c) 2004, 2011, Oracle and/or its affiliates. All rights reserved.
69.6 +# Copyright (c) 2004, 2012, Oracle and/or its affiliates. All rights reserved.
69.7 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
69.8 #
69.9 # This code is free software; you can redistribute it and/or modify it
69.10 @@ -33,4 +33,4 @@
69.11
69.12 JSTAT="${TESTJAVA}/bin/jstat"
69.13
69.14 -${JSTAT} -J-XX:+UsePerfData -gcpermcapacity 0 2>&1 | awk -f ${TESTSRC}/gcPermCapacityOutput1.awk
69.15 +${JSTAT} -J-XX:+UsePerfData -J-Duser.language=en -gcpermcapacity 0 2>&1 | awk -f ${TESTSRC}/gcPermCapacityOutput1.awk
70.1 --- a/test/sun/tools/jstat/jstatLineCounts1.sh Wed Mar 21 13:37:24 2012 -0700
70.2 +++ b/test/sun/tools/jstat/jstatLineCounts1.sh Wed Mar 21 13:38:55 2012 -0700
70.3 @@ -1,5 +1,5 @@
70.4 #
70.5 -# Copyright (c) 2004, 2011, Oracle and/or its affiliates. All rights reserved.
70.6 +# Copyright (c) 2004, 2012, Oracle and/or its affiliates. All rights reserved.
70.7 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
70.8 #
70.9 # This code is free software; you can redistribute it and/or modify it
70.10 @@ -33,4 +33,4 @@
70.11
70.12 JSTAT="${TESTJAVA}/bin/jstat"
70.13
70.14 -${JSTAT} -J-XX:+UsePerfData -gcutil 0 250 5 2>&1 | awk -f ${TESTSRC}/lineCounts1.awk
70.15 +${JSTAT} -J-XX:+UsePerfData -J-Duser.language=en -gcutil 0 250 5 2>&1 | awk -f ${TESTSRC}/lineCounts1.awk
71.1 --- a/test/sun/tools/jstat/jstatLineCounts2.sh Wed Mar 21 13:37:24 2012 -0700
71.2 +++ b/test/sun/tools/jstat/jstatLineCounts2.sh Wed Mar 21 13:38:55 2012 -0700
71.3 @@ -1,5 +1,5 @@
71.4 #
71.5 -# Copyright (c) 2004, 2011, Oracle and/or its affiliates. All rights reserved.
71.6 +# Copyright (c) 2004, 2012, Oracle and/or its affiliates. All rights reserved.
71.7 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
71.8 #
71.9 # This code is free software; you can redistribute it and/or modify it
71.10 @@ -33,4 +33,4 @@
71.11
71.12 JSTAT="${TESTJAVA}/bin/jstat"
71.13
71.14 -${JSTAT} -J-XX:+UsePerfData -gcutil 0 2>&1 | awk -f ${TESTSRC}/lineCounts2.awk
71.15 +${JSTAT} -J-XX:+UsePerfData -J-Duser.language=en -gcutil 0 2>&1 | awk -f ${TESTSRC}/lineCounts2.awk
72.1 --- a/test/sun/tools/jstat/jstatLineCounts3.sh Wed Mar 21 13:37:24 2012 -0700
72.2 +++ b/test/sun/tools/jstat/jstatLineCounts3.sh Wed Mar 21 13:38:55 2012 -0700
72.3 @@ -1,5 +1,5 @@
72.4 #
72.5 -# Copyright (c) 2004, 2011, Oracle and/or its affiliates. All rights reserved.
72.6 +# Copyright (c) 2004, 2012, Oracle and/or its affiliates. All rights reserved.
72.7 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
72.8 #
72.9 # This code is free software; you can redistribute it and/or modify it
72.10 @@ -33,4 +33,4 @@
72.11
72.12 JSTAT="${TESTJAVA}/bin/jstat"
72.13
72.14 -${JSTAT} -J-XX:+UsePerfData -gcutil -h 10 0 250 10 2>&1 | awk -f ${TESTSRC}/lineCounts3.awk
72.15 +${JSTAT} -J-XX:+UsePerfData -J-Duser.language=en -gcutil -h 10 0 250 10 2>&1 | awk -f ${TESTSRC}/lineCounts3.awk
73.1 --- a/test/sun/tools/jstat/jstatLineCounts4.sh Wed Mar 21 13:37:24 2012 -0700
73.2 +++ b/test/sun/tools/jstat/jstatLineCounts4.sh Wed Mar 21 13:38:55 2012 -0700
73.3 @@ -1,5 +1,5 @@
73.4 #
73.5 -# Copyright (c) 2004, 2011, Oracle and/or its affiliates. All rights reserved.
73.6 +# Copyright (c) 2004, 2012, Oracle and/or its affiliates. All rights reserved.
73.7 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
73.8 #
73.9 # This code is free software; you can redistribute it and/or modify it
73.10 @@ -33,4 +33,4 @@
73.11
73.12 JSTAT="${TESTJAVA}/bin/jstat"
73.13
73.14 -${JSTAT} -J-XX:+UsePerfData -gcutil -h 10 0 250 11 2>&1 | awk -f ${TESTSRC}/lineCounts4.awk
73.15 +${JSTAT} -J-XX:+UsePerfData -J-Duser.language=en -gcutil -h 10 0 250 11 2>&1 | awk -f ${TESTSRC}/lineCounts4.awk
74.1 --- a/test/sun/tools/jstat/jstatOptions1.sh Wed Mar 21 13:37:24 2012 -0700
74.2 +++ b/test/sun/tools/jstat/jstatOptions1.sh Wed Mar 21 13:38:55 2012 -0700
74.3 @@ -1,5 +1,5 @@
74.4 #
74.5 -# Copyright (c) 2004, 2011, Oracle and/or its affiliates. All rights reserved.
74.6 +# Copyright (c) 2004, 2012, Oracle and/or its affiliates. All rights reserved.
74.7 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
74.8 #
74.9 # This code is free software; you can redistribute it and/or modify it
74.10 @@ -33,8 +33,8 @@
74.11 JSTAT="${TESTJAVA}/bin/jstat"
74.12
74.13 rm -f jstat.out1 jstat.out2 2>/dev/null
74.14 -${JSTAT} -J-XX:+UsePerfData -options > jstat.out1 2>&1
74.15 -${JSTAT} -J-XX:+UsePerfData -options -J-Djstat.showUnsupported=true > jstat.out2 2>&1
74.16 +${JSTAT} -J-XX:+UsePerfData -J-Duser.language=en -options > jstat.out1 2>&1
74.17 +${JSTAT} -J-XX:+UsePerfData -J-Duser.language=en -options -J-Djstat.showUnsupported=true > jstat.out2 2>&1
74.18
74.19 diff -w jstat.out1 ${TESTSRC}/options1.out
74.20 diff -w jstat.out2 ${TESTSRC}/options2.out
75.1 --- a/test/sun/tools/jstat/jstatPrintCompilationOutput1.sh Wed Mar 21 13:37:24 2012 -0700
75.2 +++ b/test/sun/tools/jstat/jstatPrintCompilationOutput1.sh Wed Mar 21 13:38:55 2012 -0700
75.3 @@ -1,5 +1,5 @@
75.4 #
75.5 -# Copyright (c) 2004, 2011, Oracle and/or its affiliates. All rights reserved.
75.6 +# Copyright (c) 2004, 2012, Oracle and/or its affiliates. All rights reserved.
75.7 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
75.8 #
75.9 # This code is free software; you can redistribute it and/or modify it
75.10 @@ -35,4 +35,4 @@
75.11
75.12 # run with -Xcomp as jstat may complete too quickly to assure
75.13 # that compilation occurs.
75.14 -${JSTAT} -J-XX:+UsePerfData -J-Xcomp -printcompilation 0 2>&1 | awk -f ${TESTSRC}/printCompilationOutput1.awk
75.15 +${JSTAT} -J-XX:+UsePerfData -J-Duser.language=en -J-Xcomp -printcompilation 0 2>&1 | awk -f ${TESTSRC}/printCompilationOutput1.awk
76.1 --- a/test/sun/tools/jstat/jstatSnap1.sh Wed Mar 21 13:37:24 2012 -0700
76.2 +++ b/test/sun/tools/jstat/jstatSnap1.sh Wed Mar 21 13:38:55 2012 -0700
76.3 @@ -1,5 +1,5 @@
76.4 #
76.5 -# Copyright (c) 2004, 2011, Oracle and/or its affiliates. All rights reserved.
76.6 +# Copyright (c) 2004, 2012, Oracle and/or its affiliates. All rights reserved.
76.7 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
76.8 #
76.9 # This code is free software; you can redistribute it and/or modify it
76.10 @@ -33,4 +33,4 @@
76.11
76.12 JSTAT="${TESTJAVA}/bin/jstat"
76.13
76.14 -${JSTAT} -J-XX:+UsePerfData -snap 0 2>&1 | awk -f ${TESTSRC}/snap1.awk
76.15 +${JSTAT} -J-XX:+UsePerfData -J-Duser.language=en -snap 0 2>&1 | awk -f ${TESTSRC}/snap1.awk
77.1 --- a/test/sun/tools/jstat/jstatSnap2.sh Wed Mar 21 13:37:24 2012 -0700
77.2 +++ b/test/sun/tools/jstat/jstatSnap2.sh Wed Mar 21 13:38:55 2012 -0700
77.3 @@ -1,5 +1,5 @@
77.4 #
77.5 -# Copyright (c) 2004, 2011, Oracle and/or its affiliates. All rights reserved.
77.6 +# Copyright (c) 2004, 2012, Oracle and/or its affiliates. All rights reserved.
77.7 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
77.8 #
77.9 # This code is free software; you can redistribute it and/or modify it
77.10 @@ -33,4 +33,4 @@
77.11
77.12 JSTAT="${TESTJAVA}/bin/jstat"
77.13
77.14 -${JSTAT} -J-XX:+UsePerfData -J-Djstat.showUnsupported=true -snap 0 2>&1 | awk -f ${TESTSRC}/snap2.awk
77.15 +${JSTAT} -J-XX:+UsePerfData -J-Duser.language=en -J-Djstat.showUnsupported=true -snap 0 2>&1 | awk -f ${TESTSRC}/snap2.awk
78.1 --- a/test/sun/tools/jstat/jstatTimeStamp1.sh Wed Mar 21 13:37:24 2012 -0700
78.2 +++ b/test/sun/tools/jstat/jstatTimeStamp1.sh Wed Mar 21 13:38:55 2012 -0700
78.3 @@ -1,5 +1,5 @@
78.4 #
78.5 -# Copyright (c) 2004, 2011, Oracle and/or its affiliates. All rights reserved.
78.6 +# Copyright (c) 2004, 2012, Oracle and/or its affiliates. All rights reserved.
78.7 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
78.8 #
78.9 # This code is free software; you can redistribute it and/or modify it
78.10 @@ -33,4 +33,4 @@
78.11
78.12 JSTAT="${TESTJAVA}/bin/jstat"
78.13
78.14 -${JSTAT} -J-XX:+UsePerfData -gcutil -t 0 2>&1 | awk -f ${TESTSRC}/timeStamp1.awk
78.15 +${JSTAT} -J-XX:+UsePerfData -J-Duser.language=en -gcutil -t 0 2>&1 | awk -f ${TESTSRC}/timeStamp1.awk
79.1 --- a/test/sun/tools/jstatd/jpsOutput1.awk Wed Mar 21 13:37:24 2012 -0700
79.2 +++ b/test/sun/tools/jstatd/jpsOutput1.awk Wed Mar 21 13:38:55 2012 -0700
79.3 @@ -11,6 +11,10 @@
79.4 matched++;
79.5 }
79.6
79.7 +/^[0-9]+ $/ {
79.8 + matched++;
79.9 + }
79.10 +
79.11 { totallines++; print $0 }
79.12
79.13 END {
80.1 --- a/test/sun/tools/jstatd/jstatdDefaults.sh Wed Mar 21 13:37:24 2012 -0700
80.2 +++ b/test/sun/tools/jstatd/jstatdDefaults.sh Wed Mar 21 13:38:55 2012 -0700
80.3 @@ -1,5 +1,5 @@
80.4 #
80.5 -# Copyright (c) 2004, 2011, Oracle and/or its affiliates. All rights reserved.
80.6 +# Copyright (c) 2004, 2012, Oracle and/or its affiliates. All rights reserved.
80.7 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
80.8 #
80.9 # This code is free software; you can redistribute it and/or modify it
80.10 @@ -60,7 +60,7 @@
80.11 exit 1
80.12 fi
80.13
80.14 -${JSTAT} -J-XX:+UsePerfData -gcutil ${JSTATD_PID}@${HOSTNAME} 250 5 2>&1 | awk -f ${TESTSRC}/jstatGcutilOutput1.awk
80.15 +${JSTAT} -J-XX:+UsePerfData -J-Duser.language=en -gcutil ${JSTATD_PID}@${HOSTNAME} 250 5 2>&1 | awk -f ${TESTSRC}/jstatGcutilOutput1.awk
80.16 RC=$?
80.17
80.18 if [ ${RC} -ne 0 ]
81.1 --- a/test/sun/tools/jstatd/jstatdExternalRegistry.sh Wed Mar 21 13:37:24 2012 -0700
81.2 +++ b/test/sun/tools/jstatd/jstatdExternalRegistry.sh Wed Mar 21 13:38:55 2012 -0700
81.3 @@ -1,5 +1,5 @@
81.4 #
81.5 -# Copyright (c) 2004, 2011, Oracle and/or its affiliates. All rights reserved.
81.6 +# Copyright (c) 2004, 2012, Oracle and/or its affiliates. All rights reserved.
81.7 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
81.8 #
81.9 # This code is free software; you can redistribute it and/or modify it
81.10 @@ -73,7 +73,7 @@
81.11 exit 1
81.12 fi
81.13
81.14 -${JSTAT} -J-XX:+UsePerfData -gcutil ${JSTATD_PID}@${HOSTNAME}:${PORT} 250 5 2>&1 | awk -f ${TESTSRC}/jstatGcutilOutput1.awk
81.15 +${JSTAT} -J-XX:+UsePerfData -J-Duser.language=en -gcutil ${JSTATD_PID}@${HOSTNAME}:${PORT} 250 5 2>&1 | awk -f ${TESTSRC}/jstatGcutilOutput1.awk
81.16 RC=$?
81.17
81.18 if [ ${RC} -ne 0 ]
82.1 --- a/test/sun/tools/jstatd/jstatdPort.sh Wed Mar 21 13:37:24 2012 -0700
82.2 +++ b/test/sun/tools/jstatd/jstatdPort.sh Wed Mar 21 13:38:55 2012 -0700
82.3 @@ -1,5 +1,5 @@
82.4 #
82.5 -# Copyright (c) 2004, 2011, Oracle and/or its affiliates. All rights reserved.
82.6 +# Copyright (c) 2004, 2012, Oracle and/or its affiliates. All rights reserved.
82.7 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
82.8 #
82.9 # This code is free software; you can redistribute it and/or modify it
82.10 @@ -65,7 +65,7 @@
82.11 exit 1
82.12 fi
82.13
82.14 -${JSTAT} -J-XX:+UsePerfData -gcutil ${JSTATD_PID}@${HOSTNAME}:${PORT} 250 5 2>&1 | awk -f ${TESTSRC}/jstatGcutilOutput1.awk
82.15 +${JSTAT} -J-XX:+UsePerfData -J-Duser.language=en -gcutil ${JSTATD_PID}@${HOSTNAME}:${PORT} 250 5 2>&1 | awk -f ${TESTSRC}/jstatGcutilOutput1.awk
82.16 RC=$?
82.17
82.18 if [ ${RC} -ne 0 ]
83.1 --- a/test/sun/tools/jstatd/jstatdServerName.sh Wed Mar 21 13:37:24 2012 -0700
83.2 +++ b/test/sun/tools/jstatd/jstatdServerName.sh Wed Mar 21 13:38:55 2012 -0700
83.3 @@ -1,5 +1,5 @@
83.4 #
83.5 -# Copyright (c) 2004, 2011, Oracle and/or its affiliates. All rights reserved.
83.6 +# Copyright (c) 2004, 2012, Oracle and/or its affiliates. All rights reserved.
83.7 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
83.8 #
83.9 # This code is free software; you can redistribute it and/or modify it
83.10 @@ -86,8 +86,8 @@
83.11 exit 1
83.12 fi
83.13
83.14 -echo "running: ${JSTAT} -J-XX:+UsePerfData -gcutil ${JSTATD_1_PID}@${HOSTNAME}:${PORT_1} 250 5"
83.15 -${JSTAT} -J-XX:+UsePerfData -gcutil ${JSTATD_1_PID}@${HOSTNAME}:${PORT_1} 250 5 2>&1 | awk -f ${TESTSRC}/jstatGcutilOutput1.awk
83.16 +echo "running: ${JSTAT} -J-XX:+UsePerfData -J-Duser.language=en -gcutil ${JSTATD_1_PID}@${HOSTNAME}:${PORT_1} 250 5"
83.17 +${JSTAT} -J-XX:+UsePerfData -J-Duser.language=en -gcutil ${JSTATD_1_PID}@${HOSTNAME}:${PORT_1} 250 5 2>&1 | awk -f ${TESTSRC}/jstatGcutilOutput1.awk
83.18 RC=$?
83.19
83.20 if [ ${RC} -ne 0 ]
83.21 @@ -95,8 +95,8 @@
83.22 echo "jstat output differs from expected output"
83.23 fi
83.24
83.25 -echo "running: ${JSTAT} -J-XX:+UsePerfData -gcutil ${JSTATD_1_PID}@${HOSTNAME}:${PORT_2}/${SERVERNAME} 250 5"
83.26 -${JSTAT} -J-XX:+UsePerfData -gcutil ${JSTATD_1_PID}@${HOSTNAME}:${PORT_2}/${SERVERNAME} 250 5 2>&1 | awk -f ${TESTSRC}/jstatGcutilOutput1.awk
83.27 +echo "running: ${JSTAT} -J-XX:+UsePerfData -J-Duser.language=en -gcutil ${JSTATD_1_PID}@${HOSTNAME}:${PORT_2}/${SERVERNAME} 250 5"
83.28 +${JSTAT} -J-XX:+UsePerfData -J-Duser.language=en -gcutil ${JSTATD_1_PID}@${HOSTNAME}:${PORT_2}/${SERVERNAME} 250 5 2>&1 | awk -f ${TESTSRC}/jstatGcutilOutput1.awk
83.29 RC=$?
83.30
83.31 if [ ${RC} -ne 0 ]