--- a/jdk/test/sun/security/pkcs11/Signature/ByteBuffers.java Tue Jan 26 09:25:53 2016 +0000
+++ b/jdk/test/sun/security/pkcs11/Signature/ByteBuffers.java Tue Jan 26 13:32:07 2016 -0800
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2003, 2015, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2003, 2016, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -28,19 +28,24 @@
* @author Andreas Sterbenz
* @library ..
* @key randomness
+ * @run main/othervm ByteBuffers
+ * @run main/othervm ByteBuffers sm
*/
-import java.util.*;
-import java.nio.*;
-
-import java.security.*;
+import java.nio.ByteBuffer;
+import java.security.KeyPair;
+import java.security.KeyPairGenerator;
+import java.security.Provider;
+import java.security.Signature;
+import java.util.Random;
public class ByteBuffers extends PKCS11Test {
public static void main(String[] args) throws Exception {
- main(new ByteBuffers());
+ main(new ByteBuffers(), args);
}
+ @Override
public void main(Provider p) throws Exception {
/*
@@ -48,9 +53,9 @@
* when running SunPKCS11-Solaris provider (8044554)
*/
if (p.getName().equals("SunPKCS11-Solaris") &&
- System.getProperty("os.name").equals("SunOS") &&
- System.getProperty("os.arch").equals("sparcv9") &&
- System.getProperty("os.version").compareTo("5.11") <= 0 &&
+ props.getProperty("os.name").equals("SunOS") &&
+ props.getProperty("os.arch").equals("sparcv9") &&
+ props.getProperty("os.version").compareTo("5.11") <= 0 &&
getDistro().compareTo("11.2") < 0) {
System.out.println("SunPKCS11-Solaris provider requires " +