+# Try to read an entry inside the Alumni Association container.
+# It should give us noSuchObject if we're not bound...
+No such object (32)
+# ... and should return all attributes if we're bound as anyone
+# under Example.
dn: cn=James A Jones 1,ou=Alumni Association,ou=People,dc=example,dc=com
objectClass: OpenLDAPperson
cn: James A Jones 1
facsimileTelephoneNumber: +1 313 555 4332
telephoneNumber: +1 313 555 0895
+# Using ldapsearch to retrieve all the entries...
dn: cn=All Staff,ou=Groups,dc=example,dc=com
member: cn=Manager,dc=example,dc=com
member: cn=Barbara Jensen,ou=Information Technology Division,ou=People,dc=exam
access to dn.children="ou=Alumni Association,ou=People,dc=example,dc=com"
by dn.regex=".+,dc=example,dc=com" +c continue
by dn.subtree="dc=example,dc=com" +rs continue
+ by dn.children="dc=example,dc=com" +d continue
by * stop
#access to attr=member,uniquemember dn.subtree="dc=example,dc=com"
cat /dev/null > $SEARCHOUT
-#
-# Try to read an entry inside the Alumni Association container. It should
-# give us nothing if we're not bound, and should return all attributes
-# if we're bound as anyone under UM.
-#
-$LDAPSEARCH -b "$JAJDN" -h $LOCALHOST -p $PORT1 "objectclass=*" \
+echo "# Try to read an entry inside the Alumni Association container.
+# It should give us noSuchObject if we're not bound..." \
+>> $SEARCHOUT
+$LDAPSEARCH -b "$JAJDN" -h $LOCALHOST -p $PORT1 "(objectclass=*)" \
>> $SEARCHOUT 2>&1
+echo "# ... and should return all attributes if we're bound as anyone
+# under Example." \
+>> $SEARCHOUT
$LDAPSEARCH -b "$JAJDN" -h $LOCALHOST -p $PORT1 \
- -D "$BABSDN" -w bjensen "objectclass=*" >> $SEARCHOUT 2>&1
+ -D "$BABSDN" -w bjensen "(objectclass=*)" >> $SEARCHOUT 2>&1
#
# Check group access. Try to modify Babs' entry. Two attempts:
EOMODS6
echo "Using ldapsearch to retrieve all the entries..."
+echo "# Using ldapsearch to retrieve all the entries..." >> $SEARCHOUT
$LDAPSEARCH -S "" -b "$BASEDN" -h $LOCALHOST -p $PORT1 \
'objectClass=*' >> $SEARCHOUT 2>&1
RC=$?
$CMP $SEARCHFLT $LDIFFLT > $CMPOUT
if test $? != 0 ; then
- echo "comparison failed - modify operations did not complete correctly"
+ echo "comparison failed - operations did not complete correctly"
exit 1
fi