Failed
com.sun.ts.tests.jacc.web.toolsContracts.Client.Policy_from_standalone (from authorization-tck)
Error Message
test result: Failed. Test case throws exception: TestName: Policy failed : Policy replacement algorithm not used
Stacktrace
test result: Failed. Test case throws exception: TestName: Policy failed : Policy replacement algorithm not used
Standard Output
#Test Results (version 2) #Thu Oct 08 19:24:17 UTC 2020 #-----testdescription----- $file=/home/jenkins/agent/workspace/jakartaee-tck_master/authorization-tck/src/com/sun/ts/tests/jacc/web/toolsContracts/Client.java $root=/home/jenkins/agent/workspace/jakartaee-tck_master/authorization-tck/src assertion_ids=JACC\:SPEC\:14 The security property policy.provider may be used to replace the default\njava.security.Policy implementation class. Similarly, the security \nproperty auth.policy.provider may be used to replace the default\njavax.security.auth.Policy implementation class.\nJACC\:SPEC\:22 To enable delegation of non-jakarta.security.jacc policy decisions to\ndefault system Policy providers, all application servers must implement the \nfollowing Policy replacement algorithm.\n\nFor each JRE of a Jakarta EE 9 or later version Jakarta EE application server, if the system property \njakarta.security.jacc.policy.provider is defined, the application server must \nconstruct an instance of the class identified by the system property,\nconfirm that the resulting object is an instance of java.security.Policy, \nand set, by calling the java.security.Policy.setPolicy, the resulting\nobject as the corresponding Policy object used by the JRE.\nJACC\:SPEC\:53 When a module is deployed, its policy context must be linked to the policy\ncontext of every other module with which it must share the same principal-to-role \nmapping. When an application is deployed, the policy contexts of every module of\nthe application must be linked to the policy contexts of every other module of the \napplication with which it shares a common Policy provider. Policy contexts are\nlinked by calling the linkConfiguration method on the PolicyConfiguration \nobjects of the provider.\nJACC\:SPEC\:56 A\ndeployment tool indicates that a policy context is to be removed from service \neither by calling getPolicyConfiguration with the identifier of the policy context\non the provider's PolicyConfigurationFactory or by calling delete on the \ncorresponding PolicyConfiguration object. If the getPolicyConfiguration method\nis used, the value true should be passed as the second argument to cause the \ncorresponding policy statements to be deleted from the context.\nJACC\:SPEC\:67 The getPolicyConfigurationFactory, and inService methods of the\nabstract factory class, \njakarta.security.jacc.PolicyConfigurationFactory, must throw a\nSecurityException when called by an AccessControlContext that has not been \ngranted the setPolicy SecurityPermission.\nThe getPolicyConfiguration method of all implementations of the \nPolicyConfigurationFactory abstract class must throw a\nSecurityException when called by an AccessControlContext that has not been \ngranted the setPolicy SecurityPermission.\nJACC\:SPEC\:68 All of the public methods of all of the concrete implementations of the\nPolicyConfiguration interface must throw a SecurityException when called \nby an AccessControlContext that has not been granted the setPolicy\nSecurityPermission.\nJACC\:SPEC\:105 A Policy provider must include the policy statements of the default policy\ncontext in every access determination it performs.A Policy provider that either \ndoes not call PolicyContext.getContexdID, or does so and acquires the identifier\nof the default policy context, must use only the policy statements of the default \npolicy context to perform its access determination. classname=com.sun.ts.tests.jacc.web.toolsContracts.Client direction=forward finder=cts id=Policy_from_standalone keywords=all jacc javaee jacc_web Policy standalone_vehicle forward service_eetest=yes testName=Policy testProps=\ log.file.location webServerHost webServerPort test_directory=com/sun/ts/tests/jacc/web/toolsContracts #-----environment----- JAVA_HOME=/opt/jdk1.8.0_191/jre SYSTEMROOT=${env.SystemRoot} TS_HOME=/home/jenkins/agent/workspace/jakartaee-tck_master/authorization-tck/bin/xml/../.. bin.dir=/home/jenkins/agent/workspace/jakartaee-tck_master/authorization-tck/bin/xml/../../bin command.testExecute=com.sun.ts.lib.harness.ExecTSTestCmd CLASSPATH\=${ts.harness.classpath}\:${JAVA_HOME}/../lib/tools.jar DISPLAY\=${ts.display} HOME\="${user.home}" windir\=${windir} SYSTEMROOT\=${SYSTEMROOT} ${JAVA_HOME}/bin/java -Dcts.tmp\=$harness.temp.directory -Dlog.file.location\=${log.file.location} -Djava.security.policy\=${bin.dir}/harness.policy -Dcom.sun.aas.installRoot\=${jacc.home} -Djava.protocol.handler.pkgs\=javax.net.ssl -Djavax.net.ssl.keyStore\=${bin.dir}/certificates/clientcert.jks -Djavax.net.ssl.keyStorePassword\=changeit -Djavax.net.ssl.trustStore\=${jacc.home}/domains/domain1/config/cacerts.jks -Djava.ext.dirs\=${JAVA_HOME}/lib/ext -Ddeliverable.class\=${deliverable.class} $testExecuteClass $testExecuteArgs database.classes=${jdbc.lib.class.path}/derbyclient.jar deliverable.class=com.sun.ts.lib.deliverable.jacc.JACCDeliverable harness.executeMode=0 harness.log.delayseconds=1 harness.log.port=2000 harness.log.traceflag=true harness.socket.retry.count=10 harness.temp.directory=${ts.home}/tmp jacc.classes=${ri.lib}/jakarta.authorization-api.jar\:${ri.lib}/jakarta.security.auth.message-api.jar\:${ri.lib}/common-util.jar\:${ri.lib}/container-common.jar\:${ri.lib}/jakarta.annotation-api.jar\:${ri.lib}/jakarta.resource-api.jar\:${ri.lib}/jmxremote_optional-repackaged.jar\:${ri.lib}/ldapbp-repackaged.jar\:${ri.lib}/security.jar\:${ri.lib}/web-core.jar\:${ri.lib}/web-glue.jar\:${ri.lib}/websecurity.jar\:${ri.lib}/jakarta.servlet-api.jar\:${ri.lib}/jakarta.ejb-api.jar\:${ri.lib}/jakarta.persistence.jar\:${ri.lib}/jakarta.transaction-api.jar\:${ri.lib}/jakarta.jms-api.jar\:${ri.lib}/jakarta.servlet.jsp-api.jar jacc.home=/home/jenkins/agent/workspace/jakartaee-tck_master/glassfish6/glassfish jacc.host=localhost javaee.level=full jdbc.lib.class.path=${jacc.home}/javadb/lib lib.dir=${ts.home}/lib log.file.location=${jacc.home}/domains/domain1/logs porting.ts.url.class.1=com.sun.ts.lib.implementation.sun.common.SunRIURL ri.lib=${jacc.home}/modules ts.display=\:0.0 ts.harness.classpath=${lib.dir}/tsharness.jar\:${lib.dir}/sigtest.jar\:${lib.dir}/commons-logging-1.1.3.jar\:${lib.dir}/commons-httpclient-3.1.jar\:${ts.run.classpath}\:${lib.dir}/javatest.jar\:${ant.home}/lib/ant.jar ts.home=/home/jenkins/agent/workspace/jakartaee-tck_master/authorization-tck/bin/xml/../.. ts.run.classpath=${ts.home}/classes\:${database.classes}\:${jacc.classes} user.home=? webServerHost=${jacc.host} webServerPort=8080 windir=${env.windir} #-----testresult----- description=file\:/home/jenkins/agent/workspace/jakartaee-tck_master/authorization-tck/src/com/sun/ts/tests/jacc/web/toolsContracts/Client.java\#Policy_from_standalone end=Thu Oct 08 19\:24\:17 UTC 2020 environment=ts_unix execStatus=Failed. Test case throws exception\: TestName\: Policy failed \: Policy replacement algorithm not used harnessLoaderMode=Classpath Loader harnessVariety=Full Bundle javatestOS=Linux 3.10.0-1062.12.1.el7.x86_64 (amd64) javatestVersion=5.0 script=com.sun.ts.lib.harness.TSScript sections=script_messages TestRun start=Thu Oct 08 19\:24\:15 UTC 2020 test=com/sun/ts/tests/jacc/web/toolsContracts/Client.java\#Policy_from_standalone timeoutSeconds=600 totalTime=1542 work=/home/jenkins/agent/workspace/jakartaee-tck_master/authorization-tckwork/authorization-tck/com/sun/ts/tests/jacc/web/toolsContracts #section:script_messages ----------messages:(0/0)---------- #section:TestRun ----------messages:(1/3832)---------- command: com.sun.ts.lib.harness.ExecTSTestCmd CLASSPATH=:/home/jenkins/agent/workspace/jakartaee-tck_master/authorization-tck/bin/xml/../../lib/tsharness.jar:/home/jenkins/agent/workspace/jakartaee-tck_master/authorization-tck/bin/xml/../../lib/sigtest.jar:/home/jenkins/agent/workspace/jakartaee-tck_master/authorization-tck/bin/xml/../../lib/commons-logging-1.1.3.jar:/home/jenkins/agent/workspace/jakartaee-tck_master/authorization-tck/bin/xml/../../lib/commons-httpclient-3.1.jar:/home/jenkins/agent/workspace/jakartaee-tck_master/authorization-tck/bin/xml/../../classes:/home/jenkins/agent/workspace/jakartaee-tck_master/glassfish6/glassfish/javadb/lib/derbyclient.jar:/home/jenkins/agent/workspace/jakartaee-tck_master/glassfish6/glassfish/modules/jakarta.authorization-api.jar:/home/jenkins/agent/workspace/jakartaee-tck_master/glassfish6/glassfish/modules/jakarta.security.auth.message-api.jar:/home/jenkins/agent/workspace/jakartaee-tck_master/glassfish6/glassfish/modules/common-util.jar:/home/jenkins/agent/workspace/jakartaee-tck_master/glassfish6/glassfish/modules/container-common.jar:/home/jenkins/agent/workspace/jakartaee-tck_master/glassfish6/glassfish/modules/jakarta.annotation-api.jar:/home/jenkins/agent/workspace/jakartaee-tck_master/glassfish6/glassfish/modules/jakarta.resource-api.jar:/home/jenkins/agent/workspace/jakartaee-tck_master/glassfish6/glassfish/modules/jmxremote_optional-repackaged.jar:/home/jenkins/agent/workspace/jakartaee-tck_master/glassfish6/glassfish/modules/ldapbp-repackaged.jar:/home/jenkins/agent/workspace/jakartaee-tck_master/glassfish6/glassfish/modules/security.jar:/home/jenkins/agent/workspace/jakartaee-tck_master/glassfish6/glassfish/modules/web-core.jar:/home/jenkins/agent/workspace/jakartaee-tck_master/glassfish6/glassfish/modules/web-glue.jar:/home/jenkins/agent/workspace/jakartaee-tck_master/glassfish6/glassfish/modules/websecurity.jar:/home/jenkins/agent/workspace/jakartaee-tck_master/glassfish6/glassfish/modules/jakarta.servlet-api.jar:/home/jenkins/agent/workspace/jakartaee-tck_master/glassfish6/glassfish/modules/jakarta.ejb-api.jar:/home/jenkins/agent/workspace/jakartaee-tck_master/glassfish6/glassfish/modules/jakarta.persistence.jar:/home/jenkins/agent/workspace/jakartaee-tck_master/glassfish6/glassfish/modules/jakarta.transaction-api.jar:/home/jenkins/agent/workspace/jakartaee-tck_master/glassfish6/glassfish/modules/jakarta.jms-api.jar:/home/jenkins/agent/workspace/jakartaee-tck_master/glassfish6/glassfish/modules/jakarta.servlet.jsp-api.jar:/home/jenkins/agent/workspace/jakartaee-tck_master/authorization-tck/bin/xml/../../lib/javatest.jar:/lib/ant.jar:/opt/jdk1.8.0_191/jre/../lib/tools.jar DISPLAY=:0.0 HOME=? windir= SYSTEMROOT= /opt/jdk1.8.0_191/jre/bin/java -Dcts.tmp=/home/jenkins/agent/workspace/jakartaee-tck_master/authorization-tck/bin/xml/../../tmp -Dlog.file.location=/home/jenkins/agent/workspace/jakartaee-tck_master/glassfish6/glassfish/domains/domain1/logs -Djava.security.policy=/home/jenkins/agent/workspace/jakartaee-tck_master/authorization-tck/bin/xml/../../bin/harness.policy -Dcom.sun.aas.installRoot=/home/jenkins/agent/workspace/jakartaee-tck_master/glassfish6/glassfish -Djava.protocol.handler.pkgs=javax.net.ssl -Djavax.net.ssl.keyStore=/home/jenkins/agent/workspace/jakartaee-tck_master/authorization-tck/bin/xml/../../bin/certificates/clientcert.jks -Djavax.net.ssl.keyStorePassword=changeit -Djavax.net.ssl.trustStore=/home/jenkins/agent/workspace/jakartaee-tck_master/glassfish6/glassfish/domains/domain1/config/cacerts.jks -Djava.ext.dirs=/opt/jdk1.8.0_191/jre/lib/ext -Ddeliverable.class=com.sun.ts.lib.deliverable.jacc.JACCDeliverable com.sun.ts.tests.common.vehicle.VehicleClient -p /home/jenkins/agent/workspace/jakartaee-tck_master/authorization-tck/bin/xml/../../tmp/tstest.jte -t Policy -vehicle standalone ----------log:(57/4069)---------- ************************************************************ * props file set to "/tmp/?-cts-props.txt" ************************************************************ 10-08-2020 19:24:15: TRACE: ####### Value of harness.socket.retry.count is "10" 10-08-2020 19:24:15: TRACE: ####### Value of harness.log.port is "2000" 10-08-2020 19:24:15: TRACE: ####### Actual bind value of harness.log.port is "2000" 10-08-2020 19:24:15: TRACE: in ServiceEETest.run() method 10-08-2020 19:24:15: TRACE: Vehicle to be used for this test is: standalone 10-08-2020 19:24:15: TRACE: in custom vehicle so call on EETest. 10-08-2020 19:24:15: TRACE: *** in EETest.run(argv,p) 10-08-2020 19:24:15: TRACE: TESTCLASS=com.sun.ts.tests.jacc.web.toolsContracts.Client 10-08-2020 19:24:15: TRACE: ** IN getRunMethod: testClass=com.sun.ts.tests.jacc.web.toolsContracts.Client 10-08-2020 19:24:15: TRACE: ** IN getRunMethod: testname=Policy 10-08-2020 19:24:15: TRACE: ** GOT RUN METHOD! 10-08-2020 19:24:15: TRACE: **runmethod=Policy 10-08-2020 19:24:15: TRACE: ABOUT TO GET SETUP METHOD! 10-08-2020 19:24:15: TRACE: No setupMethod annotation present 10-08-2020 19:24:15: TRACE: getSetupMethod - checking for testcase specific setup method: Policy_setup 10-08-2020 19:24:15: TRACE: getSetupMethod - checking for default class specific setup method 10-08-2020 19:24:15: TRACE: GOT SETUP METHOD! 10-08-2020 19:24:15: TRACE: No cleanupMethod annotation present 10-08-2020 19:24:15: TRACE: getCleanupMethod - checking for testcase specific cleanup method: Policy_cleanup 10-08-2020 19:24:15: TRACE: getCleanupMethod - checking for default class specific cleanup method 10-08-2020 19:24:15: TRACE: GOT CLEANUP METHOD! 10-08-2020 19:24:15: TRACE: ABOUT TO INVOKE SETUP METHOD! 10-08-2020 19:24:15: setting logFileLocation based on passed in Properties 10-08-2020 19:24:15: log.file.location = /home/jenkins/agent/workspace/jakartaee-tck_master/glassfish6/glassfish/domains/domain1/logs 10-08-2020 19:24:15: Setup ok Log File : /home/jenkins/agent/workspace/jakartaee-tck_master/glassfish6/glassfish/domains/domain1/logs/JACCLog.txt does not exists Check permissions for log file See User guide for Configuring log file permissions 10-08-2020 19:24:15: TRACE: INVOKED SETUP METHOD! 10-08-2020 19:24:15: TRACE: ABOUT TO INVOKE EETEST RUN METHOD! 10-08-2020 19:24:15: Searching log records for record :TSPolicy.refresh() invoked 10-08-2020 19:24:15: Record collection has: 0 records. 10-08-2020 19:24:15: No Matching log Record(s) found for the following String(s) : 10-08-2020 19:24:15: TSPolicy.refresh() invoked 10-08-2020 19:24:15: ERROR: TestName: Policy failed : Policy replacement algorithm not used 10-08-2020 19:24:15: ERROR: Test case throws exception: TestName: Policy failed : Policy replacement algorithm not used 10-08-2020 19:24:15: ERROR: Exception at: 10-08-2020 19:24:15: ERROR: com.sun.ts.lib.harness.EETest$Fault: TestName: Policy failed : Policy replacement algorithm not used at com.sun.ts.tests.jacc.web.toolsContracts.Client.Policy(Client.java:958) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at com.sun.ts.lib.harness.EETest.run(EETest.java:596) at com.sun.ts.lib.harness.ServiceEETest.run(ServiceEETest.java:115) at com.sun.ts.tests.common.vehicle.EmptyVehicleRunner.run(EmptyVehicleRunner.java:40) at com.sun.ts.lib.harness.ServiceEETest.run(ServiceEETest.java:105) at com.sun.ts.lib.harness.EETest.getPropsReady(EETest.java:486) at com.sun.ts.lib.harness.ServiceEETest.run(ServiceEETest.java:209) at com.sun.ts.lib.harness.EETest.run(EETest.java:285) at com.sun.ts.tests.common.vehicle.VehicleClient.main(VehicleClient.java:38) 10-08-2020 19:24:16: TRACE: SLEPT FOR: 1000 STATUS:Failed.Test case throws exception: TestName: Policy failed : Policy replacement algorithm not used result: Failed. Test case throws exception: TestName: Policy failed : Policy replacement algorithm not used test result: Failed. Test case throws exception: TestName: Policy failed : Policy replacement algorithm not used