multiple_aci_tests.xml revision d25372dc8e65a9ed019a88fdf659ca61313f1b31
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE stax SYSTEM "/shared/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
!
! Copyright 2008 Sun Microsystems, Inc.
! -->
<stax>
<defaultcall function="multiple_aci_tests"/>
<function name="multiple_aci_tests">
<sequence>
<block name="'multiple-aci-tests'">
<sequence>
<script>
if not CurrentTestPath.has_key('group'):
CurrentTestPath['group']='aci'
CurrentTestPath['suite']=STAXCurrentBlock
</script>
<call function="'testSuite_Preamble'"/>
<!---
Place suite-specific test information here.
#@TestSuiteName Multiple ACI Tests
#@TestSuitePurpose Test the Support for multiple ACIs
#@TestSuiteGroup Multiple ACi Tests
#@TestScript multiple_aci_tests.xml
-->
<import machine="STAF_LOCAL_HOSTNAME"
file="'%s/testcases/aci/aci_setup.xml' % (TESTS_DIR)"/>
<call function="'aci_setup'" />
<!---
Place test-specific test information here.
The tag, TestMarker, must be the same as the tag, TestSuiteName.
#@TestMarker Multiple ACI Tests
#@TestName Preamble
#@TestIssue 446
#@TestPurpose Prepare for multiple ACI test cases
#@TestPreamble none
#@TestStep Directory Manager adds extra entries
#@TestStep Directory Manager removes global ACI allowing searches
#@TestStep Client searches entry in one branch.
#@TestStep Client searches entry in another branch.
#@TestPostamble none
#@TestResult Success if OpenDS returns 0.
-->
<!-- cross reference to http://docs.sun.com/source/816-6698-10/aci.html -->
<!-- cross reference to DS6 docs -->
<testcase name="getTestCaseName('Preamble')">
<sequence>
<call function="'testCase_Preamble'"/>
<message>
'ACI: Multiple ACIs: Preamble - Adding Branches For Multiple ACI Tests'
</message>
<call function="'addEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeAdded' : '%s/aci/multiple_aci_tests/aci_startup_mult_aci_tests.ldif' % remote.data }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Preamble - Removing Search Global ACI'
</message>
<call function="'modifyGlobalAci'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'aciValue' : GLOBAL_ACI_SEARCH ,
'opType' : 'remove' }
</call>
<message>
'ACI: Multiple ACIs: Preamble - user searching entry that will be targeted in future tests'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber telephonenumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Preamble - user searching entry that will be non-targeted in future tests'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=non-aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber telephonenumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'checktestStringNotPresent'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=non-aci branch,o=Search Tests,o=ACI Tests' }
</call>
<call function="'testCase_Postamble'"/>
</sequence>
</testcase>
<!---
Place test-specific test information here.
The tag, TestMarker, must be the same as the tag, TestSuiteName.
#@TestMarker Multiple ACI Tests
#@TestName Different targetfilters, one aci-one entry
#@TestIssue 446
#@TestPurpose Test three ACIs, different targetfilters, one aci-one entry
#@TestPreamble Admin adds three ACIs.
#@TestStep Client searches entry which should be allowed in targeted branch.
#@TestStep Client searches second entry which should not be allowed in targeted branch.
#@TestStep Client searches entry which is outside of the targeted branch.
#@TestStep Remove aci.
#@TestStep Client searches entry which was previously allowed.
#@TestPostamble none
#@TestResult Success if OpenDS returns 0
for all ldap operations.
Entry is returned only for step 1
and only with the appropriate attributes.
-->
<!-- cross reference to http://docs.sun.com/source/816-6698-10/aci.html -->
<!-- cross reference to DS6 docs -->
<testcase name="getTestCaseName('Different targetfilters, one aci-one entry')">
<sequence>
<call function="'testCase_Preamble'"/>
<script>
curr_aci_ldif_file = 'add_aci1.ldif'
curr_aci=retrieve_aci('%s/aci/multiple_aci_tests/%s' % (local.data,curr_aci_ldif_file));
</script>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-one entry, preamble adding aci,\n %s' % curr_aci
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/%s' % (remote.data,curr_aci_ldif_file) }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-one entry, user searching targeted entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'roomNumber:' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'cn:' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'telephoneNumber:' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-one entry, user searching second entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=scarter,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=scarter,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-one entry, one true, user searching non-targeted entry outside of the scope of the aci'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=non-aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=non-aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-one entry, one true, admin deleting aci'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/del_aci_search.ldif' % remote.data }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-one entry, user searching previously targeted entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'checktestStringNotPresent'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' }
</call>
<call function="'testCase_Postamble'"/>
</sequence>
</testcase>
<!---
Place test-specific test information here.
The tag, TestMarker, must be the same as the tag, TestSuiteName.
#@TestMarker Multiple ACI Tests
#@TestName Different targetfilters, one aci-two entries 1
#@TestIssue 446
#@TestPurpose Test three ACIs, different targetfilters, one aci-two entries, same attribute
#@TestPreamble Admin adds three ACIs.
#@TestStep Client searches entry which should be allowed in targeted branch.
#@TestStep Client searches second entry which should also be allowed in targeted branch.
#@TestStep Client searches entry which is outside of the targeted branch.
#@TestStep Remove aci.
#@TestStep Client searches entry which was previously allowed.
#@TestPostamble none
#@TestResult Success if OpenDS returns 0
for all ldap operations.
Entry is returned only for steps 1 and 2
and only with the appropriate attributes.
-->
<!-- cross reference to http://docs.sun.com/source/816-6698-10/aci.html -->
<!-- cross reference to DS6 docs -->
<testcase name="getTestCaseName('Different targetfilters, one aci-two entries 1')">
<sequence>
<call function="'testCase_Preamble'"/>
<script>
curr_aci_ldif_file = 'add_aci2.ldif'
curr_aci=retrieve_aci('%s/aci/multiple_aci_tests/%s' % (local.data,curr_aci_ldif_file));
</script>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 1, preamble adding aci,\n %s' % curr_aci
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/%s' % (remote.data,curr_aci_ldif_file) }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 1, user searching targeted entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'roomNumber:' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'cn:' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'telephoneNumber:' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 1, user searching second entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=scarter,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=scarter,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'roomNumber:' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'cn:' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'telephoneNumber:' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 1, one true, user searching non-targeted entry outside of the scope of the aci'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=non-aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=non-aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 1, one true, admin deleting aci'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/del_aci_search.ldif' % remote.data }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 1, user searching previously targeted entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'checktestStringNotPresent'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' }
</call>
<call function="'testCase_Postamble'"/>
</sequence>
</testcase>
<!---
Place test-specific test information here.
The tag, TestMarker, must be the same as the tag, TestSuiteName.
#@TestMarker Multiple ACI Tests
#@TestName Different targetfilters, one aci-two entries 2
#@TestIssue 446
#@TestPurpose Test three ACIs, different targetfilters, one aci-two entries, two attributes with not equal
#@TestPreamble Admin adds three ACIs.
#@TestStep Client searches entry which should be allowed in targeted branch.
#@TestStep Client searches second entry which should also be allowed in targeted branch.
#@TestStep Client searches entry which is outside of the targeted branch.
#@TestStep Remove aci.
#@TestStep Client searches entry which was previously allowed.
#@TestPostamble none
#@TestResult Success if OpenDS returns 0
for all ldap operations.
Entry is returned only for steps 1 and 2
and only with the appropriate attributes.
-->
<!-- cross reference to http://docs.sun.com/source/816-6698-10/aci.html -->
<!-- cross reference to DS6 docs -->
<testcase name="getTestCaseName('Different targetfilters, one aci-two entries 2')">
<sequence>
<call function="'testCase_Preamble'"/>
<script>
curr_aci_ldif_file = 'add_aci3.ldif'
curr_aci=retrieve_aci('%s/aci/multiple_aci_tests/%s' % (local.data,curr_aci_ldif_file));
</script>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 2, preamble adding aci,\n %s' % curr_aci
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/%s' % (remote.data,curr_aci_ldif_file) }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 2, user searching targeted entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'roomNumber:' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'cn:' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'telephoneNumber:' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 2, user searching second entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=scarter,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=scarter,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'roomNumber:' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'cn:' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'telephoneNumber:' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 2, one true, user searching non-targeted entry outside of the scope of the aci'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=non-aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=non-aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 2, one true, admin deleting aci'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/del_aci_search.ldif' % remote.data }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 2, user searching previously targeted entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'checktestStringNotPresent'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' }
</call>
<call function="'testCase_Postamble'"/>
</sequence>
</testcase>
<!---
Place test-specific test information here.
The tag, TestMarker, must be the same as the tag, TestSuiteName.
#@TestMarker Multiple ACI Tests
#@TestName Different targetfilters, one aci-two entries 3
#@TestIssue 446
#@TestPurpose Test three ACIs, different targetfilters, one aci-two entries, with two attributes with equal
#@TestPreamble Admin adds three ACIs.
#@TestStep Client searches entry which should be allowed in targeted branch.
#@TestStep Client searches second entry which should also be allowed in targeted branch.
#@TestStep Client searches entry which is outside of the targeted branch.
#@TestStep Remove aci.
#@TestStep Client searches entry which was previously allowed.
#@TestPostamble none
#@TestResult Success if OpenDS returns 0
for all ldap operations.
Entry is returned only for steps 1 and 2
and only with the appropriate attributes.
-->
<!-- cross reference to http://docs.sun.com/source/816-6698-10/aci.html -->
<!-- cross reference to DS6 docs -->
<testcase name="getTestCaseName('Different targetfilters, one aci-two entries 3')">
<sequence>
<call function="'testCase_Preamble'"/>
<script>
curr_aci_ldif_file = 'add_aci4.ldif'
curr_aci=retrieve_aci('%s/aci/multiple_aci_tests/%s' % (local.data,curr_aci_ldif_file));
</script>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 3, preamble adding aci,\n %s' % curr_aci
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/%s' % (remote.data,curr_aci_ldif_file) }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 3, user searching targeted entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'roomNumber:' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'cn:' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'telephoneNumber:' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 3, user searching second entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=scarter,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid telephonenumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=scarter,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'telephoneNumber:' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'cn:' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'roomNumber:' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 3, one true, user searching second entry outside of the scope of the aci'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=non-aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=non-aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 3, one true, admin deleting aci'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/del_aci_search.ldif' % remote.data }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 3, user searching previously targeted entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'checktestStringNotPresent'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' }
</call>
<call function="'testCase_Postamble'"/>
</sequence>
</testcase>
<!---
Place test-specific test information here.
The tag, TestMarker, must be the same as the tag, TestSuiteName.
#@TestMarker Multiple ACI Tests
#@TestName Different targetfilters, one aci-one entry, deny
#@TestIssue 446
#@TestPurpose Test three ACIs, different targetfilters, one aci-one entry, deny
#@TestPreamble Admin adds three ACIs.
#@TestStep Client searches entry which should not be allowed in targeted branch.
#@TestStep Client searches second entry which should not be allowed in targeted branch.
#@TestStep Client searches entry which is outside of the targeted branch.
#@TestStep Remove aci.
#@TestStep Client searches previous entry.
#@TestPostamble none
#@TestResult Success if OpenDS returns 0
for all ldap operations.
Entry is returned for no steps.
-->
<!-- cross reference to http://docs.sun.com/source/816-6698-10/aci.html -->
<!-- cross reference to DS6 docs -->
<testcase name="getTestCaseName('Different targetfilters, one aci-one entry, deny')">
<sequence>
<call function="'testCase_Preamble'"/>
<script>
curr_aci_ldif_file = 'add_aci5.ldif'
curr_aci=retrieve_aci('%s/aci/multiple_aci_tests/%s' % (local.data,curr_aci_ldif_file));
</script>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-one entry, deny, preamble adding aci,\n %s' % curr_aci
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/%s' % (remote.data,curr_aci_ldif_file) }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-one entry, deny, user searching targeted entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-one entry, deny, user searching second entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=scarter,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=scarter,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-one entry, deny, user searching non-targeted entry outside of the scope of the aci'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=non-aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=non-aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-one entry, deny, admin deleting aci'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/del_aci_search.ldif' % remote.data }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-one entry, deny, user searching previously targeted entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'checktestStringNotPresent'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' }
</call>
<call function="'testCase_Postamble'"/>
</sequence>
</testcase>
<!---
Place test-specific test information here.
The tag, TestMarker, must be the same as the tag, TestSuiteName.
#@TestMarker Multiple ACI Tests
#@TestName Different targetfilters, one aci-two entries 1, deny
#@TestIssue 446
#@TestPurpose Test three ACIs, different targetfilters, one aci-two entries, same attribute, deny
#@TestPreamble Admin adds three ACIs, different targetfilters, two statements true with same attrs.
#@TestStep Client searches entry which should not be allowed in targeted branch.
#@TestStep Client searches second entry which should not be allowed in targeted branch.
#@TestStep Client searches entry which is outside of the targeted branch.
#@TestStep Remove aci.
#@TestStep Client searches previous entry.
#@TestPostamble none
#@TestResult Success if OpenDS returns 0
for all ldap operations.
Entry is returned for no steps.
-->
<!-- cross reference to http://docs.sun.com/source/816-6698-10/aci.html -->
<!-- cross reference to DS6 docs -->
<testcase name="getTestCaseName('Different targetfilters, one aci-two entries 1, deny')">
<sequence>
<call function="'testCase_Preamble'"/>
<script>
curr_aci_ldif_file = 'add_aci6.ldif'
curr_aci=retrieve_aci('%s/aci/multiple_aci_tests/%s' % (local.data,curr_aci_ldif_file));
</script>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 1, deny, preamble adding aci,\n %s' % curr_aci
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/%s' % (remote.data,curr_aci_ldif_file) }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 1, deny, user searching targeted entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 1, deny, user searching second entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=scarter,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=scarter,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 1, deny, one true, user searching non-targeted entry outside of the scope of the aci'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=non-aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=non-aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 1, deny, one true, admin deleting aci'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/del_aci_search.ldif' % remote.data }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 1, deny, user searching previously targeted entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'checktestStringNotPresent'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' }
</call>
<call function="'testCase_Postamble'"/>
</sequence>
</testcase>
<!---
Place test-specific test information here.
The tag, TestMarker, must be the same as the tag, TestSuiteName.
#@TestMarker Multiple ACI Tests
#@TestName Different targetfilters, one aci-two entries 2, deny
#@TestIssue 446
#@TestPurpose Test three ACIs, different targetfilters, one aci-two entries, two attributes with not equal, deny
#@TestPreamble Admin adds three ACIs, different targetfilters, two statements true with, two attributes with not equal, deny
#@TestStep Client searches entry which should not be allowed in targeted branch.
#@TestStep Client searches second entry which should not be allowed in targeted branch.
#@TestStep Client searches entry which is outside of the targeted branch.
#@TestStep Remove aci.
#@TestStep Client searches previous entry.
#@TestPostamble none
#@TestResult Success if OpenDS returns 0
for all ldap operations.
Entry is returned for no steps.
-->
<!-- cross reference to http://docs.sun.com/source/816-6698-10/aci.html -->
<!-- cross reference to DS6 docs -->
<testcase name="getTestCaseName('Different targetfilters, one aci-two entries 2, deny')">
<sequence>
<call function="'testCase_Preamble'"/>
<script>
curr_aci_ldif_file = 'add_aci7.ldif'
curr_aci=retrieve_aci('%s/aci/multiple_aci_tests/%s' % (local.data,curr_aci_ldif_file));
</script>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 2, deny, preamble adding aci,\n %s' % curr_aci
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/%s' % (remote.data,curr_aci_ldif_file) }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 2, deny, user searching targeted entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 2, deny, user searching second entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=scarter,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=scarter,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 2, deny, one true, user searching non-targeted entry outside of the scope of the aci'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=non-aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=non-aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 2, deny, one true, admin deleting aci'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/del_aci_search.ldif' % remote.data }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 2, deny, user searching previously targeted entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'checktestStringNotPresent'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' }
</call>
<call function="'testCase_Postamble'"/>
</sequence>
</testcase>
<!---
Place test-specific test information here.
The tag, TestMarker, must be the same as the tag, TestSuiteName.
#@TestMarker Multiple ACI Tests
#@TestName Different targetfilters, one aci-two entries 3, deny
#@TestIssue 446
#@TestPurpose Test three ACIs, different targetfilters, one aci-two entries, with two attributes with equal, deny
#@TestPreamble Admin adds three ACIs.
#@TestStep Client searches entry which should be allowed in targeted branch.
#@TestStep Client searches second entry which should not be allowed in targeted branch.
#@TestStep Client searches entry which is outside of the targeted branch.
#@TestStep Remove aci.
#@TestStep Client searches entry which was previously allowed.
#@TestPostamble none
#@TestResult Success if OpenDS returns 0
for all ldap operations.
Entry is returned only for step 1
and only with the appropriate attributes.
-->
<!-- cross reference to http://docs.sun.com/source/816-6698-10/aci.html -->
<!-- cross reference to DS6 docs -->
<testcase name="getTestCaseName('Different targetfilters, one aci-two entries 3, deny')">
<sequence>
<call function="'testCase_Preamble'"/>
<script>
curr_aci_ldif_file = 'add_aci8.ldif'
curr_aci=retrieve_aci('%s/aci/multiple_aci_tests/%s' % (local.data,curr_aci_ldif_file));
</script>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 3, deny, preamble adding aci,\n %s' % curr_aci
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/%s' % (remote.data,curr_aci_ldif_file) }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 3, deny, user searching targeted entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'roomNumber:' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'cn:' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'telephoneNumber:' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 3, deny, user searching second entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=scarter,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid telephonenumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=scarter,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 3, deny, user searching second entry outside of the scope of the aci'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=non-aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=non-aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 3, deny, admin deleting aci'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/del_aci_search.ldif' % remote.data }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 3, deny, user searching previously targeted entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'checktestStringNotPresent'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' }
</call>
<call function="'testCase_Postamble'"/>
</sequence>
</testcase>
<!---
Place test-specific test information here.
The tag, TestMarker, must be the same as the tag, TestSuiteName.
#@TestMarker Multiple ACI Tests
#@TestName Different targetfilters and targetattr
#@TestIssue 446
#@TestPurpose Test three ACIs, different targetfilters, one aci-two entries, same attribute
#@TestPreamble Admin adds three ACIs.
#@TestStep Client searches entry which should be allowed in targeted branch.
#@TestStep Client searches second entry which should also be allowed in targeted branch.
#@TestStep Client searches entry which is outside of the targeted branch.
#@TestStep Remove aci.
#@TestStep Client searches entry which was previously allowed.
#@TestPostamble none
#@TestResult Success if OpenDS returns 0
for all ldap operations.
Entry is returned only for steps 1 and 2
and only with the appropriate attributes.
-->
<!-- cross reference to http://docs.sun.com/source/816-6698-10/aci.html -->
<!-- cross reference to DS6 docs -->
<testcase name="getTestCaseName('Different targetfilters and targetattr')">
<sequence>
<call function="'testCase_Preamble'"/>
<script>
curr_aci_ldif_file = 'add_aci9.ldif'
curr_aci=retrieve_aci('%s/aci/multiple_aci_tests/%s' % (local.data,curr_aci_ldif_file));
</script>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 1, preamble adding aci,\n %s' % curr_aci
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/%s' % (remote.data,curr_aci_ldif_file) }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 1, user searching targeted entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'roomNumber:' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'cn:' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'telephoneNumber:' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 1, user searching second entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=scarter,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=scarter,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'roomNumber:' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'cn:' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'telephoneNumber:' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 1, one true, user searching non-targeted entry outside of the scope of the aci'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=non-aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=non-aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 1, one true, admin deleting aci'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/del_aci_search.ldif' % remote.data }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Different targetfilters, one aci-two entries 1, user searching previously targeted entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'checktestStringNotPresent'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' }
</call>
<call function="'testCase_Postamble'"/>
</sequence>
</testcase>
<!---
Place test-specific test information here.
The tag, TestMarker, must be the same as the tag, TestSuiteName.
#@TestMarker Multiple ACI Tests
#@TestName Different targetfilters and targeattr, deny one attr
#@TestIssue 446
#@TestPurpose Test three ACIs, different targetfilters, one aci-two entries, two attributes with not equal
#@TestPreamble Admin adds three ACIs.
#@TestStep Client searches entry which should be allowed in targeted branch.
#@TestStep Client searches second entry which should also be allowed in targeted branch.
#@TestStep Client searches entry which is outside of the targeted branch.
#@TestStep Remove aci.
#@TestStep Client searches entry which was previously allowed.
#@TestPostamble none
#@TestResult Success if OpenDS returns 0
for all ldap operations.
Entry is returned only for steps 1 and 2
and only with the appropriate attributes.
-->
<!-- cross reference to http://docs.sun.com/source/816-6698-10/aci.html -->
<!-- cross reference to DS6 docs -->
<testcase name="getTestCaseName('Different targetfilters and targeattr, deny one attr')">
<sequence>
<call function="'testCase_Preamble'"/>
<script>
curr_aci_ldif_file = 'add_aci10.ldif'
curr_aci=retrieve_aci('%s/aci/multiple_aci_tests/%s' % (local.data,curr_aci_ldif_file));
</script>
<message>
'ACI: Multiple ACIs: Different targetfilters and targeattr, deny one attr, preamble adding aci,\n %s' % curr_aci
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/%s' % (remote.data,curr_aci_ldif_file) }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Different targetfilters and targeattr, deny one attr, user searching targeted entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'roomNumber:' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'cn:' ,
'expectedResult' : '0' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'telephoneNumber:' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters and targeattr, deny one attr, user searching second entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=scarter,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=scarter,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'roomNumber:' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'cn:' ,
'expectedResult' : '0' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'telephoneNumber:' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters and targeattr, deny one attr, one true, user searching non-targeted entry outside of the scope of the aci'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=non-aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=non-aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters and targeattr, deny one attr, one true, admin deleting aci'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/del_aci_search.ldif' % remote.data }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Different targetfilters and targeattr, deny one attr, user searching previously targeted entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'checktestStringNotPresent'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' }
</call>
<call function="'testCase_Postamble'"/>
</sequence>
</testcase>
<!---
Place test-specific test information here.
The tag, TestMarker, must be the same as the tag, TestSuiteName.
#@TestMarker Multiple ACI Tests
#@TestName Different targetfilters and targetattr with not equals
#@TestIssue 446
#@TestPurpose Test three ACIs, different targetfilters and targetattr with not equals
#@TestPreamble Admin adds three ACIs.
#@TestStep Client searches entry which should be allowed in targeted branch.
#@TestStep Client searches second entry which should also be allowed in targeted branch.
#@TestStep Client searches entry which is outside of the targeted branch.
#@TestStep Remove aci.
#@TestStep Client searches entry which was previously allowed.
#@TestPostamble none
#@TestResult Success if OpenDS returns 0
for all ldap operations.
Entry is returned only for steps 1 and 2
and only with the appropriate attributes.
-->
<!-- cross reference to http://docs.sun.com/source/816-6698-10/aci.html -->
<!-- cross reference to DS6 docs -->
<testcase name="getTestCaseName('Different targetfilters and targetattr with not equals')">
<sequence>
<call function="'testCase_Preamble'"/>
<script>
curr_aci_ldif_file = 'add_aci11.ldif'
curr_aci=retrieve_aci('%s/aci/multiple_aci_tests/%s' % (local.data,curr_aci_ldif_file));
</script>
<message>
'ACI: Multiple ACIs: Different targetfilters and targetattr with not equals, preamble adding aci,\n %s' % curr_aci
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/%s' % (remote.data,curr_aci_ldif_file) }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Different targetfilters and targetattr with not equals, user searching targeted entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'roomNumber:' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'cn:' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'telephoneNumber:' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters and targetattr with not equals, user searching second entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=scarter,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid telephonenumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=scarter,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'telephoneNumber:' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'cn:' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'roomNumber:' ,
'expectedResult' : '0' }
</call>
<if expr="returnCode != '0'">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Different targetfilters and targetattr with not equals, one true, user searching second entry outside of the scope of the aci'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=non-aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=non-aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '1' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters and targetattr with not equals, admin deleting aci'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/del_aci_search.ldif' % remote.data }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Different targetfilters and targetattr with not equals, user searching previously targeted entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'checktestStringNotPresent'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' }
</call>
<call function="'testCase_Postamble'"/>
</sequence>
</testcase>
<!---
Place test-specific test information here.
The tag, TestMarker, must be the same as the tag, TestSuiteName.
#@TestMarker Multiple ACI Tests
#@TestName Different targetfilters and targetattr, separate search-read with missing read
#@TestIssue 446
#@TestPurpose Test three ACIs, different targetfilters and targetattr, separate search-read with missing read
#@TestPreamble Admin adds three ACIs.
#@TestStep Client searches entry which should not be allowed in targeted branch.
#@TestStep Client searches second entry which should be allowed in targeted branch.
#@TestStep Client searches entry which is outside of the targeted branch.
#@TestStep Remove aci.
#@TestStep Client searches entry which was previously allowed.
#@TestPostamble none
#@TestResult Success if OpenDS returns 0
for all ldap operations.
Entries are returned only for steps 1 and 2
and only with the appropriate attributes.
-->
<!-- cross reference to http://docs.sun.com/source/816-6698-10/aci.html -->
<!-- cross reference to DS6 docs -->
<testcase name="getTestCaseName('Different targetfilters and targetattr, separate search-read with missing read')">
<sequence>
<call function="'testCase_Preamble'"/>
<script>
curr_aci_ldif_file = 'add_aci12.ldif'
curr_aci=retrieve_aci('%s/aci/multiple_aci_tests/%s' % (local.data,curr_aci_ldif_file));
</script>
<message>
'ACI: Multiple ACIs: Different targetfilters and targetattr, separate search-read with missing read, preamble adding aci,\n %s' % curr_aci
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/%s' % (remote.data,curr_aci_ldif_file) }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Different targetfilters and targetattr, separate search-read with missing read, user searching targeted entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'roomNumber:' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters and targetattr, separate search-read with missing read, user searching second entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=scarter,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid telephonenumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=scarter,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'telephoneNumber:' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'cn:' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'roomNumber:' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters and targetattr, separate search-read missing read, user searching second entry outside of the scope of the aci'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=non-aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=non-aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters and targetattr, separate search-read missing read, admin deleting aci'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/del_aci_search.ldif' % remote.data }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Different targetfilters and targetattr, separate search-read missing read, user searching previously targeted entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'checktestStringNotPresent'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' }
</call>
<call function="'testCase_Postamble'"/>
</sequence>
</testcase>
<!---
Place test-specific test information here.
The tag, TestMarker, must be the same as the tag, TestSuiteName.
#@TestMarker Multiple ACI Tests
#@TestName Different targetfilters and targetattr, separate search-read
#@TestIssue 446
#@TestPurpose Test three ACIs, different targetfilters and targetattr, separate search-read
#@TestPreamble Admin adds three ACIs.
#@TestStep Client searches entry which should be allowed in targeted branch.
#@TestStep Client searches second entry which should also be allowed in targeted branch.
#@TestStep Client searches entry which is outside of the targeted branch.
#@TestStep Remove aci.
#@TestStep Client searches entry which was previously allowed.
#@TestPostamble none
#@TestResult Success if OpenDS returns 0
for all ldap operations.
Entry is returned only for steps 1 and 2
and only with the appropriate attributes.
-->
<!-- cross reference to http://docs.sun.com/source/816-6698-10/aci.html -->
<!-- cross reference to DS6 docs -->
<testcase name="getTestCaseName('Different targetfilters and targetattr, separate search-read')">
<sequence>
<call function="'testCase_Preamble'"/>
<script>
curr_aci_ldif_file = 'add_aci13.ldif'
curr_aci=retrieve_aci('%s/aci/multiple_aci_tests/%s' % (local.data,curr_aci_ldif_file));
</script>
<message>
'ACI: Multiple ACIs: Different targetfilters and targetattr, separate search-read, preamble adding aci,\n %s' % curr_aci
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/%s' % (remote.data,curr_aci_ldif_file) }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Different targetfilters and targetattr, separate search-read, user searching targeted entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'roomNumber:' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'cn:' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'telephoneNumber:' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters and targetattr, separate search-read, user searching second entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=scarter,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid telephonenumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=scarter,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'telephoneNumber:' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'cn:' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'roomNumber:' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters and targetattr, separate search-read, user searching second entry outside of the scope of the aci'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=non-aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=non-aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters and targetattr, separate search-read, admin deleting aci'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/del_aci_search.ldif' % remote.data }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Different targetfilters and targetattr, separate search-read, user searching previously targeted entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'checktestStringNotPresent'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' }
</call>
<call function="'testCase_Postamble'"/>
</sequence>
</testcase>
<!---
Place test-specific test information here.
The tag, TestMarker, must be the same as the tag, TestSuiteName.
#@TestMarker Multiple ACI Tests
#@TestName Different targetfilters and targetattr, separate search-read with deny search
#@TestIssue 446
#@TestPurpose Test three ACIs, different targetfilters and targetattr, separate search-read with deny search
#@TestPreamble Admin adds three ACIs.
#@TestStep Client searches entry which should not be allowed in targeted branch.
#@TestStep Client searches second entry which should be allowed in targeted branch.
#@TestStep Client searches entry which is outside of the targeted branch.
#@TestStep Remove aci.
#@TestStep Client searches entry which was previously allowed.
#@TestPostamble none
#@TestResult Success if OpenDS returns 0
for all ldap operations.
Entry is returned only for step 2
and only with the appropriate attributes.
-->
<!-- cross reference to http://docs.sun.com/source/816-6698-10/aci.html -->
<!-- cross reference to DS6 docs -->
<testcase name="getTestCaseName('Different targetfilters and targetattr, separate search-read with deny search')">
<sequence>
<call function="'testCase_Preamble'"/>
<script>
curr_aci_ldif_file = 'add_aci14.ldif'
curr_aci=retrieve_aci('%s/aci/multiple_aci_tests/%s' % (local.data,curr_aci_ldif_file));
</script>
<message>
'ACI: Multiple ACIs: Different targetfilters and targetattr, separate search-read with deny search, preamble adding aci,\n %s' % curr_aci
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/%s' % (remote.data,curr_aci_ldif_file) }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Different targetfilters and targetattr, separate search-read with deny search, user searching targeted entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters and targetattr, separate search-read with deny search, user searching second entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=scarter,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid telephonenumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=scarter,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'telephoneNumber:' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'cn:' ,
'expectedResult' : '1' }
</call>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'roomNumber:' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters and targetattr, separate search-read with deny search, user searching second entry outside of the scope of the aci'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=non-aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=non-aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Different targetfilters and targetattr, separate search-read with deny search, admin deleting aci'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/del_aci_search.ldif' % remote.data }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Different targetfilters and targetattr, separate search-read with deny search, user searching previously targeted entry'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'checktestStringNotPresent'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' }
</call>
<call function="'testCase_Postamble'"/>
</sequence>
</testcase>
<!---
Place test-specific test information here.
The tag, TestMarker, must be the same as the tag, TestSuiteName.
#@TestMarker Multiple ACI Tests
#@TestName Separate targattrfilters with add:l and del:l
#@TestIssue 444
#@TestPurpose Test with separate targattrfilters
#@TestPreamble Admin adds an aci with the target equal to the dn of one existing branch.
#@TestStep Client replaces l in an entry with the targeted branch dn.
#@TestStep Client replaces mail in an entry with the targeted branch dn.
#@TestStep Client replaces l in an entry that is not with the targeted branch dn.
#@TestStep Remove aci.
#@TestStep Client replaces l from an entry with the previously targeted branch dn.
#@TestPostamble none
#@TestResult Success if OpenDS returns 0
for all ldapmodify operations,
0 for step 1, and
50 for all other steps.
-->
<!-- cross reference to http://docs.sun.com/source/816-6698-10/aci.html -->
<!-- cross reference to DS6 docs -->
<testcase name="getTestCaseName('Separate targattrfilters with add:l and del:l')">
<sequence>
<call function="'testCase_Preamble'"/>
<script>
curr_aci_ldif_file = 'add_aci31.ldif'
curr_aci=retrieve_aci('%s/aci/multiple_aci_tests/%s' % (local.data,curr_aci_ldif_file));
</script>
<message>
'ACI: Multiple ACIs: Separate targattrfilters with add:l and del:l, preamble adding aci,\n %s' % curr_aci
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/%s' % (remote.data,curr_aci_ldif_file) }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Separate targattrfilters with add:l and del:l, user replacing l in targeted entry'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/replace_l31.ldif' % remote.data }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Separate targattrfilters with add:l and del:l, user replacing mail in targeted entry'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/replace_mail31.ldif' % remote.data ,
'expectedRC' : 50
}
</call>
<message>
'ACI: Multiple ACIs: Separate targattrfilters with add:l and del:l, user replacing l in non-targeted entry'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/replace_l31a.ldif' % remote.data ,
'expectedRC' : 50
}
</call>
<message>
'ACI: Multiple ACIs: Separate targattrfilters with add:l and del:l, admin deleting aci'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/del_aci_modify.ldif' % remote.data }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Separate targattrfilters with add:l and del:l, user replacing l in previously targeted entry'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/replace_l31.ldif' % remote.data ,
'expectedRC' : 50
}
</call>
<call function="'testCase_Postamble'"/>
</sequence>
</testcase>
<!---
Place test-specific test information here.
The tag, TestMarker, must be the same as the tag, TestSuiteName.
#@TestMarker Multiple ACI Tests
#@TestName Separate targattrfilters with deny add:l and allow del:l
#@TestIssue 444
#@TestPurpose Test with separate targattrfilters
#@TestPreamble Admin adds an aci with the target equal to the dn of one existing branch.
#@TestStep Client replaces l in an entry with the targeted branch dn.
#@TestStep Client replaces mail in an entry with the targeted branch dn.
#@TestStep Client replaces l in an entry that is not with the targeted branch dn.
#@TestStep Remove aci.
#@TestStep Client replaces l from an entry with the previously targeted branch dn.
#@TestPostamble none
#@TestResult Success if OpenDS returns 0
for all ldapmodify operations,
and 50 for all other steps.
-->
<!-- cross reference to http://docs.sun.com/source/816-6698-10/aci.html -->
<!-- cross reference to DS6 docs -->
<testcase name="getTestCaseName('Separate targattrfilters with deny add:l and allow del:l')">
<sequence>
<call function="'testCase_Preamble'"/>
<script>
curr_aci_ldif_file = 'add_aci32.ldif'
curr_aci=retrieve_aci('%s/aci/multiple_aci_tests/%s' % (local.data,curr_aci_ldif_file));
</script>
<message>
'ACI: Multiple ACIs: Separate targattrfilters with deny add:l and allow del:l, preamble adding aci,\n %s' % curr_aci
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/%s' % (remote.data,curr_aci_ldif_file) }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Separate targattrfilters with deny add:l and allow del:l, user replacing l in targeted entry'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/replace_l32.ldif' % remote.data ,
'expectedRC' : 50
}
</call>
<message>
'ACI: Multiple ACIs: Separate targattrfilters with deny add:l and allow del:l, user replacing mail in targeted entry'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/replace_mail32.ldif' % remote.data ,
'expectedRC' : 50
}
</call>
<message>
'ACI: Multiple ACIs: Separate targattrfilters with deny add:l and allow del:l, user replacing l in non-targeted entry'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/replace_l32a.ldif' % remote.data ,
'expectedRC' : 50
}
</call>
<message>
'ACI: Multiple ACIs: Separate targattrfilters with deny add:l and allow del:l, admin deleting aci'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/del_aci_modify.ldif' % remote.data }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Separate targattrfilters with deny add:l and allow del:l, user replacing l in previously targeted entry'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/replace_l32.ldif' % remote.data ,
'expectedRC' : 50
}
</call>
<call function="'testCase_Postamble'"/>
</sequence>
</testcase>
<!---
Place test-specific test information here.
The tag, TestMarker, must be the same as the tag, TestSuiteName.
#@TestMarker Multiple ACI Tests
#@TestName Separate targattrfilters with allow add:l and deny del:l
#@TestIssue 444
#@TestPurpose Test with separate targattrfilters
#@TestPreamble Admin adds an aci with the target equal to the dn of one existing branch.
#@TestStep Client replaces l in an entry with the targeted branch dn.
#@TestStep Client replaces mail in an entry with the targeted branch dn.
#@TestStep Client replaces l in an entry that is not with the targeted branch dn.
#@TestStep Remove aci.
#@TestStep Client replaces l from an entry with the previously targeted branch dn.
#@TestPostamble none
#@TestResult Success if OpenDS returns 0
for all ldapmodify operations,
and 50 for all other steps.
-->
<!-- cross reference to http://docs.sun.com/source/816-6698-10/aci.html -->
<!-- cross reference to DS6 docs -->
<testcase name="getTestCaseName('Separate targattrfilters with allow add:l and deny del:l')">
<sequence>
<call function="'testCase_Preamble'"/>
<script>
curr_aci_ldif_file = 'add_aci33.ldif'
curr_aci=retrieve_aci('%s/aci/multiple_aci_tests/%s' % (local.data,curr_aci_ldif_file));
</script>
<message>
'ACI: Multiple ACIs: Separate targattrfilters with allow add:l and deny del:l, preamble adding aci,\n %s' % curr_aci
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/%s' % (remote.data,curr_aci_ldif_file) }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Separate targattrfilters with allow add:l and deny del:l, user replacing l in targeted entry'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/replace_l33.ldif' % remote.data ,
'expectedRC' : 50
}
</call>
<message>
'ACI: Multiple ACIs: Separate targattrfilters with allow add:l and deny del:l, user replacing mail in targeted entry'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/replace_mail33.ldif' % remote.data ,
'expectedRC' : 50
}
</call>
<message>
'ACI: Multiple ACIs: Separate targattrfilters with allow add:l and deny del:l, user replacing l in non-targeted entry'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/replace_l33a.ldif' % remote.data ,
'expectedRC' : 50
}
</call>
<message>
'ACI: Multiple ACIs: Separate targattrfilters with allow add:l and deny del:l, admin deleting aci'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/del_aci_modify.ldif' % remote.data }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Separate targattrfilters with allow add:l and deny del:l, user replacing l in previously targeted entry'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/replace_l33.ldif' % remote.data ,
'expectedRC' : 50
}
</call>
<call function="'testCase_Postamble'"/>
</sequence>
</testcase>
<!---
Place test-specific test information here.
The tag, TestMarker, must be the same as the tag, TestSuiteName.
#@TestMarker Multiple ACI Tests
#@TestName Separate targetattrs
#@TestIssue 444
#@TestPurpose Test with separate targetattrs
#@TestPreamble Admin adds an aci with the target equal to the dn of one existing branch.
#@TestStep Client replaces l in an entry with the targeted branch dn.
#@TestStep Client replaces mail in an entry with the targeted branch dn.
#@TestStep Client replaces l in an entry that is not with the targeted branch dn.
#@TestStep Remove aci.
#@TestStep Client replaces l from an entry with the previously targeted branch dn.
#@TestPostamble none
#@TestResult Success if OpenDS returns 0
for all ldapmodify operations,
and 50 for all other steps.
-->
<testcase name="getTestCaseName('Separate targetattrs')">
<sequence>
<call function="'testCase_Preamble'"/>
<script>
curr_aci_ldif_file = 'add_aci34.ldif'
curr_aci=retrieve_aci('%s/aci/multiple_aci_tests/%s' % (local.data,curr_aci_ldif_file));
</script>
<message>
'ACI: Multiple ACIs: Separate targetattrs, preamble adding aci,\n %s' % curr_aci
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/%s' % (remote.data,curr_aci_ldif_file) }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Separate targetattrs, user modifying entry from targeted branch'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/replace_l34.ldif' % remote.data }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Separate targetattrs, user modifying prohibited attr in entry from targeted branch'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/replace_title34.ldif' % remote.data ,
'expectedRC' : 50
}
</call>
<message>
'ACI: Multiple ACIs: Separate targetattrs, user modifying entry from non-targeted branch'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/replace_l34a.ldif' % remote.data ,
'expectedRC' : 50
}
</call>
<message>
'ACI: Multiple ACIs: Separate targetattrs, admin deleting aci'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/del_aci_modify.ldif' % remote.data }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Separate targetattrs, user modifying entry in previously targeted branch'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/mod_common_prohibited_entry.ldif' % remote.data ,
'expectedRC' : 50
}
</call>
<call function="'testCase_Postamble'"/>
</sequence>
</testcase>
<!---
Place test-specific test information here.
The tag, TestMarker, must be the same as the tag, TestSuiteName.
#@TestMarker Multiple ACI Tests
#@TestName Separate targetattrs with not equals
#@TestIssue 444
#@TestPurpose Test with separate targetattrs
#@TestPreamble Admin adds an aci with the target equal to the dn of one existing branch.
#@TestStep Client replaces l in an entry with the targeted branch dn.
#@TestStep Client replaces mail in an entry with the targeted branch dn.
#@TestStep Client replaces l in an entry that is not with the targeted branch dn.
#@TestStep Remove aci.
#@TestStep Client replaces l from an entry with the previously targeted branch dn.
#@TestPostamble none
#@TestResult Success if OpenDS returns 0
for all ldapmodify operations,
0 for steps 1, 2 and 3, and
50 for all other steps.
-->
<testcase name="getTestCaseName('Separate targetattrs with not equals')">
<sequence>
<call function="'testCase_Preamble'"/>
<script>
curr_aci_ldif_file = 'add_aci35.ldif'
curr_aci=retrieve_aci('%s/aci/multiple_aci_tests/%s' % (local.data,curr_aci_ldif_file));
</script>
<message>
'ACI: Multiple ACIs: Separate targetattrs with not equals, preamble adding aci,\n %s' % curr_aci
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/%s' % (remote.data,curr_aci_ldif_file) }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Separate targetattrs with not equals, user modifying entry from targeted branch'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/replace_l35.ldif' % remote.data }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Separate targetattrs with not equals, user modifying prohibited attr in entry from targeted branch'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/replace_title35.ldif' % remote.data }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Separate targetattrs with not equals, user modifying entry from non-targeted branch'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/replace_l35a.ldif' % remote.data }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Separate targetattrs with not equals, admin deleting aci'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/del_aci_modify.ldif' % remote.data }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Separate targetattrs with not equals, user modifying entry in previously targeted branch'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/mod_common_prohibited_entry.ldif' % remote.data ,
'expectedRC' : 50
}
</call>
<call function="'testCase_Postamble'"/>
</sequence>
</testcase>
<!---
Place test-specific test information here.
The tag, TestMarker, must be the same as the tag, TestSuiteName.
#@TestMarker Multiple ACI Tests
#@TestName Separate targetattrs and targattrfilters with equals and not equals
#@TestIssue 444
#@TestPurpose Test with separate targetattrs
#@TestPreamble Admin adds an aci with the target equal to the dn of one existing branch.
#@TestStep Client replaces l in an entry with the targeted branch dn.
#@TestStep Client replaces title in an entry with the targeted branch dn.
#@TestStep Client replaces another title in an entry with the targeted branch dn.
#@TestStep Client replaces l in an entry that is not with the targeted branch dn.
#@TestStep Remove aci.
#@TestStep Client replaces l from an entry with the previously targeted branch dn.
#@TestPostamble none
#@TestResult Success if OpenDS returns 0
for all ldapmodify operations,
0 for steps 1 and 2, and
50 for all other steps.
-->
<testcase name="getTestCaseName('Separate targetattrs and targattrfilters with equals and not equals')">
<sequence>
<call function="'testCase_Preamble'"/>
<script>
curr_aci_ldif_file = 'add_aci36.ldif'
curr_aci=retrieve_aci('%s/aci/multiple_aci_tests/%s' % (local.data,curr_aci_ldif_file));
</script>
<message>
'ACI: Multiple ACIs: Separate targetattrs and targattrfilters with equals and not equals, preamble adding aci,\n %s' % curr_aci
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/%s' % (remote.data,curr_aci_ldif_file) }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Separate targetattrs and targattrfilters with equals and not equals, user modifying entry from targeted branch'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/replace_l36.ldif' % remote.data }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Separate targetattrs and targattrfilters with equals and not equals, user modifying prohibited attr in entry from targeted branch'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/replace_title36.ldif' % remote.data ,
'expectedRC' : 50
}
</call>
<message>
'ACI: Multiple ACIs: Separate targetattrs and targattrfilters with equals and not equals, user modifying prohibited attr in entry from targeted branch'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/replace_title36.1.ldif' % remote.data ,
'expectedRC' : 50
}
</call>
<message>
'ACI: Multiple ACIs: Separate targetattrs and targattrfilters with equals and not equals, user modifying entry from non-targeted branch'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/replace_l36a.ldif' % remote.data ,
'expectedRC' : 50
}
</call>
<message>
'ACI: Multiple ACIs: Separate targetattrs and targattrfilters with equals and not equals, admin deleting aci'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/del_aci_modify.ldif' % remote.data }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Separate targetattrs and targattrfilters with equals and not equals, user modifying entry in previously targeted branch'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/mod_common_prohibited_entry.ldif' % remote.data ,
'expectedRC' : 50
}
</call>
<call function="'testCase_Postamble'"/>
</sequence>
</testcase>
<!---
Place test-specific test information here.
The tag, TestMarker, must be the same as the tag, TestSuiteName.
#@TestMarker Multiple ACI Tests
#@TestName Separate targetattrs and targattrfilters with not equals
#@TestIssue 444
#@TestPurpose Test with separate targetattrs
#@TestPreamble Admin adds an aci with the target equal to the dn of one existing branch.
#@TestStep Client replaces l in an entry with the targeted branch dn.
#@TestStep Client replaces title in an entry with the targeted branch dn.
#@TestStep Client replaces another title in an entry with the targeted branch dn.
#@TestStep Client replaces l in an entry that is not with the targeted branch dn.
#@TestStep Remove aci.
#@TestStep Client replaces l from an entry with the previously targeted branch dn.
#@TestPostamble none
#@TestResult Success if OpenDS returns 0
for all ldapmodify operations,
0 for steps 1, 2,`and 3, and
50 for all other steps.
-->
<testcase name="getTestCaseName('Separate targetattrs and targattrfilters with not equals')">
<sequence>
<call function="'testCase_Preamble'"/>
<script>
curr_aci_ldif_file = 'add_aci37.ldif'
curr_aci=retrieve_aci('%s/aci/multiple_aci_tests/%s' % (local.data,curr_aci_ldif_file));
</script>
<message>
'ACI: Multiple ACIs: Separate targetattrs and targattrfilters with not equals, preamble adding aci,\n %s' % curr_aci
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/%s' % (remote.data,curr_aci_ldif_file) }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Separate targetattrs and targattrfilters with not equals, user modifying entry from targeted branch'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/replace_l37.ldif' % remote.data }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Separate targetattrs and targattrfilters with not equals, user modifying prohibited attr in entry from targeted branch'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/replace_title37.ldif' % remote.data ,
'expectedRC' : 50
}
</call>
<message>
'ACI: Multiple ACIs: Separate targetattrs and targattrfilters with not equals, user modifying prohibited attr in entry from targeted branch'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/replace_title37.1.ldif' % remote.data ,
'expectedRC' : 50
}
</call>
<message>
'ACI: Multiple ACIs: Separate targetattrs and targattrfilters with not equals, user modifying entry from non-targeted branch'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/replace_l37a.ldif' % remote.data ,
'expectedRC' : 50
}
</call>
<message>
'ACI: Multiple ACIs: Separate targetattrs and targattrfilters with not equals, admin deleting aci'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/del_aci_modify.ldif' % remote.data }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Separate targetattrs and targattrfilters with not equals, user modifying entry in previously targeted branch'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/mod_common_prohibited_entry.ldif' % remote.data ,
'expectedRC' : 50
}
</call>
<call function="'testCase_Postamble'"/>
</sequence>
</testcase>
<!---
Place test-specific test information here.
The tag, TestMarker, must be the same as the tag, TestSuiteName.
#@TestMarker Multiple ACI Tests
#@TestName Separate targetattrs and targattrfilters with deny
#@TestIssue 444
#@TestPurpose Test with separate targetattrs
#@TestPreamble Admin adds an aci with the target equal to the dn of one existing branch.
#@TestStep Client replaces l in an entry with the targeted branch dn.
#@TestStep Client replaces mail in an entry with the targeted branch dn.
#@TestStep Client replaces l in an entry that is not with the targeted branch dn.
#@TestStep Remove aci.
#@TestStep Client replaces l from an entry with the previously targeted branch dn.
#@TestPostamble none
#@TestResult Success if OpenDS returns 0
for all ldapmodify operations,
0 for step 1, and
50 for all other steps.
-->
<testcase name="getTestCaseName('Separate targetattrs and targattrfilters with deny')">
<sequence>
<call function="'testCase_Preamble'"/>
<script>
curr_aci_ldif_file = 'add_aci38.ldif'
curr_aci=retrieve_aci('%s/aci/multiple_aci_tests/%s' % (local.data,curr_aci_ldif_file));
</script>
<message>
'ACI: Multiple ACIs: Separate targetattrs and targattrfilters with deny, preamble adding aci,\n %s' % curr_aci
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/%s' % (remote.data,curr_aci_ldif_file) }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Separate targetattrs and targattrfilters with deny, user modifying entry from targeted branch'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/replace_l38.ldif' % remote.data }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Separate targetattrs and targattrfilters with deny, user modifying prohibited attr in entry from targeted branch'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/replace_title38.ldif' % remote.data ,
'expectedRC' : 50
}
</call>
<message>
'ACI: Multiple ACIs: Separate targetattrs and targattrfilters with deny, user modifying prohibited attr in entry from targeted branch'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/replace_title38.1.ldif' % remote.data ,
'expectedRC' : 50
}
</call>
<message>
'ACI: Multiple ACIs: Separate targetattrs and targattrfilters with deny, user modifying entry from non-targeted branch'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/replace_l38a.ldif' % remote.data ,
'expectedRC' : 50
}
</call>
<message>
'ACI: Multiple ACIs: Separate targetattrs and targattrfilters with deny, admin deleting aci'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/del_aci_modify.ldif' % remote.data }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Separate targetattrs and targattrfilters with deny, user modifying entry in previously targeted branch'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/mod_common_prohibited_entry.ldif' % remote.data ,
'expectedRC' : 50
}
</call>
<call function="'testCase_Postamble'"/>
</sequence>
</testcase>
<!---
Place test-specific test information here.
The tag, TestMarker, must be the same as the tag, TestSuiteName.
#@TestMarker Multiple ACI Tests
#@TestName Separate targetattrs with deny and targattrfilters
#@TestIssue 444
#@TestPurpose Test with separate targetattrs
#@TestPreamble Admin adds an aci with the target equal to the dn of one existing branch.
#@TestStep Client replaces l in an entry with the targeted branch dn.
#@TestStep Client replaces mail in an entry with the targeted branch dn.
#@TestStep Client replaces l in an entry that is not with the targeted branch dn.
#@TestStep Remove aci.
#@TestStep Client replaces l from an entry with the previously targeted branch dn.
#@TestPostamble none
#@TestResult Success if OpenDS returns 0
for all ldapmodify operations,
0 for steps 1, 2, and 3 and
50 for all other steps.
-->
<testcase name="getTestCaseName('Separate targetattrs with deny and targattrfilters ')">
<sequence>
<call function="'testCase_Preamble'"/>
<script>
curr_aci_ldif_file = 'add_aci39.ldif'
curr_aci=retrieve_aci('%s/aci/multiple_aci_tests/%s' % (local.data,curr_aci_ldif_file));
</script>
<message>
'ACI: Multiple ACIs: Separate targetattrs with deny and targattrfilters , preamble adding aci,\n %s' % curr_aci
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/%s' % (remote.data,curr_aci_ldif_file) }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Separate targetattrs with deny and targattrfilters , user modifying entry from targeted branch'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/replace_l39.ldif' % remote.data ,
'expectedRC' : 50
}
</call>
<message>
'ACI: Multiple ACIs: Separate targetattrs with deny and targattrfilters , user modifying prohibited attr in entry from targeted branch'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/replace_title39.ldif' % remote.data ,
'expectedRC' : 50
}
</call>
<message>
'ACI: Multiple ACIs: Separate targetattrs with deny and targattrfilters , user modifying prohibited attr in entry from targeted branch'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/replace_title39.1.ldif' % remote.data ,
'expectedRC' : 50
}
</call>
<message>
'ACI: Multiple ACIs: Separate targetattrs with deny and targattrfilters , user modifying entry from non-targeted branch'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/replace_l37a.ldif' % remote.data ,
'expectedRC' : 50
}
</call>
<message>
'ACI: Multiple ACIs: Separate targetattrs with deny and targattrfilters , admin deleting aci'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/del_aci_modify.ldif' % remote.data }
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Separate targetattrs with deny and targattrfilters , user modifying entry in previously targeted branch'
</message>
<call function="'modifyEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'entryToBeModified' : '%s/aci/multiple_aci_tests/mod_common_prohibited_entry.ldif' % remote.data ,
'expectedRC' : 50
}
</call>
<call function="'testCase_Postamble'"/>
</sequence>
</testcase>
<!---
Place test-specific test information here.
The tag, TestMarker, must be the same as the tag, TestSuiteName.
#@TestMarker Multiple ACI Tests
#@TestName Postamble
#@TestIssue 446
#@TestPurpose Reset global ACI to default settings
#@TestPreamble none
#@TestStep Client searches entry in one branch.
#@TestStep Client searches entry in another branch.
#@TestStep Directory Manager replaces default global aci.
#@TestPostamble none
#@TestResult Success if OpenDS returns 0.
-->
<!-- cross reference to http://docs.sun.com/source/816-6698-10/aci.html -->
<!-- cross reference to DS6 docs -->
<testcase name="getTestCaseName('Postamble')">
<sequence>
<call function="'testCase_Preamble'"/>
<message>
'ACI: Multiple ACIs: Postamble - user searching entry that was targeted'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber telephonenumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Postamble - user searching entry that was non-targeted'
</message>
<call function="'SearchObject'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : 'uid=auser,ou=people,o=ACI Tests,dc=example,dc=com' ,
'dsInstancePswd' : 'ACIRules' ,
'dsBaseDN' : 'uid=dmiller,ou=People,ou=non-aci branch,o=Search Tests,o=ACI Tests,dc=example,dc=com' ,
'dsFilter' : 'objectclass=*' ,
'attributes' : 'cn sn uid roomnumber telephonenumber'}
</call>
<script>
returnString = STAXResult[0][1]
</script>
<call function="'searchStringForSubstring'">
{ 'returnString' : returnString ,
'testString' : 'dn: uid=dmiller,ou=People,ou=non-aci branch,o=Search Tests,o=ACI Tests' ,
'expectedResult' : '0' }
</call>
<message>
'ACI: Multiple ACIs: Postamble - delete branch, o=Search Tests'
</message>
<call function="'DeleteEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'dsBaseDN' : 'o=Search Tests, o=ACI Tests,dc=example,dc=com' ,
'extraParams' : '-x'}
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Postamble - delete branch, o=Modify Tests'
</message>
<call function="'DeleteEntry'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstancePort' : DIRECTORY_INSTANCE_PORT ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'dsBaseDN' : 'o=Modify Tests, o=ACI Tests,dc=example,dc=com' ,
'extraParams' : '-x'}
</call>
<if expr="RC != 0">
<tcstatus result="'fail'"/>
</if>
<message>
'ACI: Multiple ACIs: Postamble - Resetting Search Global ACI'
</message>
<call function="'modifyGlobalAci'">
{ 'dsInstanceHost' : DIRECTORY_INSTANCE_HOST ,
'dsInstanceDn' : DIRECTORY_INSTANCE_DN ,
'dsInstancePswd' : DIRECTORY_INSTANCE_PSWD ,
'aciValue' : GLOBAL_ACI_SEARCH ,
'opType' : 'add' }
</call>
<call function="'testCase_Postamble'"/>
</sequence>
</testcase>
<import machine="STAF_LOCAL_HOSTNAME"
file="'%s/testcases/aci/aci_cleanup.xml' % (TESTS_DIR)"/>
<call function="'aci_cleanup'" />
<call function="'testSuite_Postamble'"/>
</sequence>
</block>
</sequence>
</function>
</stax>