Skip to content
This repository was archived by the owner on Nov 15, 2022. It is now read-only.

Commit 16fffac

Browse files
ankathurjigneshbhodia
authored andcommitted
solving cts_smoke and servet_tck failures (#22609)
* Changing permission * changing permission * Adding more permissions * changing permission * Correcting CTS smoke and transaction failure. * adding more permission * Adding all permissions. * correcting file path. * Adjusting permissions
1 parent f53664b commit 16fffac

File tree

3 files changed

+52
-3
lines changed

3 files changed

+52
-3
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
/*
2+
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER.
3+
*
4+
* Copyright (c) 2019 Oracle and/or its affiliates. All rights reserved.
5+
*
6+
* The contents of this file are subject to the terms of either the GNU
7+
* General Public License Version 2 only ("GPL") or the Common Development
8+
* and Distribution License("CDDL") (collectively, the "License"). You
9+
* may not use this file except in compliance with the License. You can
10+
* obtain a copy of the License at
11+
* https://oss.oracle.com/licenses/CDDL+GPL-1.1
12+
* or LICENSE.txt. See the License for the specific
13+
* language governing permissions and limitations under the License.
14+
*
15+
* When distributing the software, include this License Header Notice in each
16+
* file and include the License file at LICENSE.txt.
17+
*
18+
* GPL Classpath Exception:
19+
* Oracle designates this particular file as subject to the "Classpath"
20+
* exception as provided by Oracle in the GPL Version 2 section of the License
21+
* file that accompanied this code.
22+
*
23+
* Modifications:
24+
* If applicable, add the following below the License Header, with the fields
25+
* enclosed by brackets [] replaced by your own identifying information:
26+
* "Portions Copyright [year] [name of copyright owner]"
27+
*
28+
* Contributor(s):
29+
* If you wish your version of this file to be governed by only the CDDL or
30+
* only the GPL Version 2, indicate your decision by adding "[Contributor]
31+
* elects to include this software in this distribution under the [CDDL or GPL
32+
* Version 2] license." If you don't indicate a single choice of license, a
33+
* recipient has the option to distribute your version of this file under
34+
* either the CDDL, the GPL Version 2 or to extend the choice of license to
35+
* its licensees as provided above. However, if you add GPL Version 2 code
36+
* and therefore, elected the GPL Version 2 license, then the option applies
37+
* only if the new code is made subject to such option by the copyright
38+
* holder.
39+
*/
40+
41+
grant {
42+
permission org.apache.derby.security.SystemPermission "engine", "usederbyinternals";
43+
permission java.io.FilePermission "<<ALL FILES>>", "read,write";
44+
permission java.security.AllPermission;
45+
};

Diff for: appserver/tests/appserv-tests/devtests/transaction/ee/ee.xml

+1-1
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@
6060
<arg line="--dbport"/>
6161
<arg line="${db.port}"/>
6262
<arg line="--jvmoptions"/>
63-
<arg line="'-Djava.security.manager -Djava.security.policy=${env.S1AS_HOME}/domains/domain1/config/server.policy'"/>
63+
<arg line="'-Djava.security.manager -Djava.security.policy=${env.APS_HOME}/devtests/transaction/ee/ee-test.policy'"/>
6464
</exec>
6565
</target>
6666

Diff for: nucleus/admin/template/src/main/resources/config/server.policy

+6-2
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,7 @@ grant codeBase "file:${com.sun.aas.imqLib}/-" {
6262
grant codeBase "file:${com.sun.aas.derbyRoot}/lib/-" {
6363
permission java.lang.RuntimePermission "createClassLoader";
6464
permission java.io.FilePermission "<<ALL FILES>>", "read,write";
65+
permission java.security.AllPermission;
6566
};
6667

6768

@@ -100,7 +101,7 @@ grant {
100101

101102
permission java.lang.RuntimePermission "loadLibrary.*";
102103
permission java.lang.RuntimePermission "queuePrintJob";
103-
permission java.net.SocketPermission "*", "connect";
104+
permission java.net.SocketPermission "*", "connect,resolve";
104105

105106
// work-around for pointbase bug 4864405
106107
permission java.io.FilePermission "${com.sun.aas.instanceRoot}${/}lib${/}databases${/}-", "delete";
@@ -147,6 +148,9 @@ grant codeBase "file:${com.sun.aas.instanceRoot}/applications/-"{
147148
//Added for changes proposed by Derby 10.12.1.1 (DERBY-6648) and Derby 10.14.2.0
148149
grant {
149150
permission org.apache.derby.security.SystemPermission "engine", "usederbyinternals";
151+
152+
permission java.net.SocketPermission "*", "listen";
153+
permission java.net.SocketPermission "*", "accept";
150154
permission java.io.FilePermission "<<ALL FILES>>", "write,read";
151-
permission java.security.AllPermission;
155+
152156
};

0 commit comments

Comments
 (0)