test/jdk/java/security/Policy/SignedJar/SignedJarTest.java
changeset 59104 046e4024e55a
parent 51675 b487c1e914d0
equal deleted inserted replaced
59103:4a09d4df104c 59104:046e4024e55a
     1 /*
     1 /*
     2  * Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved.
     2  * Copyright (c) 2015, 2019, Oracle and/or its affiliates. All rights reserved.
     3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     4  *
     4  *
     5  * This code is free software; you can redistribute it and/or modify it
     5  * This code is free software; you can redistribute it and/or modify it
     6  * under the terms of the GNU General Public License version 2 only, as
     6  * under the terms of the GNU General Public License version 2 only, as
     7  * published by the Free Software Foundation.
     7  * published by the Free Software Foundation.
    64         ProcessTools.executeCommand(JAR, "-cvf", "test.jar", "PrivilegeTest.class");
    64         ProcessTools.executeCommand(JAR, "-cvf", "test.jar", "PrivilegeTest.class");
    65 
    65 
    66         //Creating first key , keystore both.jks
    66         //Creating first key , keystore both.jks
    67         ProcessTools.executeCommand(KEYTOOL,
    67         ProcessTools.executeCommand(KEYTOOL,
    68                 "-genkey",
    68                 "-genkey",
       
    69                 "-keyalg", "DSA",
    69                 "-alias", "first",
    70                 "-alias", "first",
    70                 "-keystore", KEYSTORE1,
    71                 "-keystore", KEYSTORE1,
    71                 "-keypass", PASSWORD,
    72                 "-keypass", PASSWORD,
    72                 "-dname", "cn=First",
    73                 "-dname", "cn=First",
    73                 "-storepass", PASSWORD
    74                 "-storepass", PASSWORD
    74         ).shouldHaveExitValue(0);
    75         ).shouldHaveExitValue(0);
    75 
    76 
    76         //Creating Second key, keystore both.jks
    77         //Creating Second key, keystore both.jks
    77         ProcessTools.executeCommand(KEYTOOL,
    78         ProcessTools.executeCommand(KEYTOOL,
    78                 "-genkey",
    79                 "-genkey",
       
    80                 "-keyalg", "DSA",
    79                 // "-storetype","JKS",
    81                 // "-storetype","JKS",
    80                 "-alias", "second",
    82                 "-alias", "second",
    81                 "-keystore", KEYSTORE1,
    83                 "-keystore", KEYSTORE1,
    82                 "-keypass", PASSWORD,
    84                 "-keypass", PASSWORD,
    83                 "-dname", "cn=Second",
    85                 "-dname", "cn=Second",