security_teardown_jks.xml revision f71f7a61dec7c9089378d14493ad564a1dedf0b5
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE stax SYSTEM "stax.dtd">
<!--
! CDDL HEADER START
!
! The contents of this file are subject to the terms of the
! Common Development and Distribution License, Version 1.0 only
! (the "License"). You may not use this file except in compliance
! with the License.
!
! You can obtain a copy of the license at
! trunk/opends/resource/legal-notices/OpenDS.LICENSE
! or https://OpenDS.dev.java.net/OpenDS.LICENSE.
! See the License for the specific language governing permissions
! and limitations under the License.
!
! When distributing Covered Code, include this CDDL HEADER in each
! file and include the License file at
! trunk/opends/resource/legal-notices/OpenDS.LICENSE. If applicable,
! add the following below this CDDL HEADER, with the fields enclosed
! by brackets "[]" replaced with your own identifying information:
! Portions Copyright [yyyy] [name of copyright owner]
!
! CDDL HEADER END
!
! Portions Copyright 2006-2007 Sun Microsystems, Inc.
! -->
<stax>
<defaultcall function="teardown_jks"/>
<function name="teardown_jks">
<sequence>
<!--- Test Case : JKS Teardown -->
<!---
Place suite-specific test information here.
#@TestSuiteName Teardown Tests
#@TestSuitePurpose Unconfigure JKS keystore and the secure port.
#@TestSuiteGroup Security JKS Teardown Tests
#@TestScript security_teardown_jks.xml
-->
<!--- Delete Branch through SSL port -->
<testcase name="'Security: JKS: Postamble Reset'">
<!---
Place test-specific test information here.
The tag, TestMarker, must be the same as the tag, TestSuiteName.
#@TestMarker Teardown Tests
#@TestName JKS Teardown Test
#@TestIssue 413
#@TestPurpose Unconfigure JKS keystore.
#@TestPreamble none
#@TestStep Delete entries that were used for the JKS tests.
#@TestStep Unconfigure JKS keystore.
#@TestStep Remove JKS keystore.
#@TestStep Test search with unsecure port.
#@TestPostamble none
#@TestResult Success if OpenDS returns 0 for all operations
-->
<sequence>
<call function="'testCase_Preamble'"/>
<message>
'Security: JKS: Postamble Step 1. Deleting Branch Through SSL Port'
</message>
<call function="'DeleteEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_SSL_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'dsBaseDN' : 'o=SSL Tests,dc=example,dc=com' ,
'extraParams' : '-Z -X -x' }
</call>
<call function="'checkRC'">
{ 'returncode' : RC ,
'result' : STAXResult }
</call>
<!--- Unconfigure JKS Keystore -->
<message>
'Security: JKS: Postamble Step 2. Unconfiguring JKS Keystore'
</message>
<call function="'unconfigureSSL'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'keystoreType' : '%s' % 'jks' }
</call>
<call function="'checkRC'">
{ 'returncode' : RC ,
'result' : STAXResult }
</call>
<!--- Remove JKS Keystore -->
<message>
'Security: JKS: Postamble Step 3. Removing JKS Keystore'
</message>
<call function="'deletefile'">
{ 'filename' : '%/config/keystore' % (OPENDS_BINPATH),
'hostname' : STAF_REMOTE_HOSTNAME }
</call>
<call function="'checkRC'">
{ 'returncode' : RC ,
'result' : STAXResult }
</call>
<!--- Search With Unsecure Port -->
<message>
'Security: JKS: Postamble Step 4. Searching with Unsecure Connection'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'dsBaseDN' : 'dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' }
</call>
<call function="'checktestRC'">
{ 'returncode' : RC ,
'result' : STAXResult }
</call>
<call function="'testCase_Postamble'"/>
</sequence>
</testcase>
</sequence>
</function>
</stax>