security_pwd_MD5.xml revision d6c71e7b06ef8919af4c8186b4ffb08766c20a09
<?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="pwd_MD5"/>
<function name="pwd_MD5">
<sequence>
<!--- Test case: Admin Change To MD5 Storage Scheme -->
<testcase name="'Security: Pwd Storage MD5: Preamble'">
<sequence>
<message>
'Security: Pwd Storage MD5: Preamble - Admin Changing to MD5 Storage Scheme'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/security/pwd_storage/admin_change_MD5.ldif' % STAGED_DATA_DIR }
</call>
<call function="'checktestRC'">
{ 'returncode' : RC ,
'result' : STAXResult }
</call>
</sequence>
</testcase>
<!--- Test Case : User Change Password MD5 Scheme-->
<testcase name="'Security: Pwd Storage MD5: Pwd Change'">
<sequence>
<message>
'Security: Pwd Storage MD5: User Changing Password'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=kwinters,ou=people,ou=password tests,o=Pwd Storage Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'forsook' ,
'entryToBeModified' : '%s/security/pwd_storage/user_change_pwd_MD5.ldif' % STAGED_DATA_DIR }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'Security: Pwd Storage MD5: User Binding With New Password'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=kwinters,ou=people,ou=password tests,o=Pwd Storage Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'MD5forsook' ,
'dsBaseDN' : 'dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'extraParams' : '-s base' }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'Security: Pwd Storage MD5: Checking for MD5 Scheme On New Password'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'dsBaseDN' : 'uid=kwinters,ou=people,ou=password tests,o=Pwd Storage Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'userpassword' }
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'checktestString'">
{ 'returnString' : returnString ,
'expectedString' : '{MD5}' }
</call>
</sequence>
</testcase>
<!--- Test case: Admin Reset To SSHA Storage Scheme -->
<testcase name="'Security: Pwd Storage MD5: Postamble'">
<sequence>
<message>
'Security: Pwd Storage MD5: Postamble - Admin Resetting to SSHA Storage Scheme'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/security/pwd_storage/admin_reset_SSHA.ldif' % STAGED_DATA_DIR }
</call>
<call function="'checktestRC'">
{ 'returncode' : RC ,
'result' : STAXResult }
</call>
</sequence>
</testcase>
<return>RC</return>
</sequence>
</function>
</stax>