2 > ${lookup ldap {ldap:///o=University%20of%20Cambridge,c=UK?sn?sub?(cn=Philip%20Hazel)}{$value}fail}
5 > DN is: cn=Philip Hazel,o=University of Cambridge,c=UK
7 > Expect "Hazel" (Unix socket interface)
8 > ${lookup ldap {ldapi://%2Ftmp%2Fldap.sock/o=University%20of%20Cambridge,c=UK?sn?sub?(cn=Philip%20Hazel)}{}fail}
11 > Expect syntax failure
12 > Failed: lookup of "X=y ldap:///o=University%20of%20Cambridge,c=UK?sn?sub?(cn=Philip%20Hazel)" gave DEFER: unknown parameter "X=" precedes LDAP URL
15 > ${lookup ldap {time=1 ldap:///o=University%20of%20Cambridge,c=UK?sn?sub?(cn=Philip%20Hazel)}{$value}fail}
18 > Expect "manager" followed by "Hazel" 5 times
19 > ${lookup ldapm {ldap:///o=University%20of%20Cambridge,c=UK?sn?sub?(cn=*)}{$value}fail}
27 > DN is: cn=P*Hazel,o=University of Cambridge,c=UK
29 > Expect "manager" followed by "Hazel"
30 > ${lookup ldapm {Size=2 ldap:///o=University%20of%20Cambridge,c=UK?sn?sub?(cn=*)}{$value}fail}
34 > Expect "manager" followed by "Hazel" 5 times
35 > ${lookup ldapm {ldap:///o=University%20of%20Cambridge,c=UK?sn?sub?(cn=*)}{$value}fail}
44 > ${lookup ldap {size=1 ldap:///o=University%20of%20Cambridge,c=UK?sn?sub?(cn=*)}{$value}fail}
47 > Expect too many results error
48 > Failed: lookup of "size=0 time=0 ldap:///o=University%20of%20Cambridge,c=UK?sn?sub?(cn=*)" gave DEFER: LDAP search: more than one entry (6) was returned (filter not specific enough?)
51 > ${lookup ldap {size=1 time=0 user="cn=manager,o=University of Cambridge,c=UK" pass=secret ldap:///o=University%20of%20Cambridge,c=UK?sn?sub?(cn=*)}{$value}fail}
54 > Expect invalid credentials
55 > ${lookup ldap {size=1 time=0 user="cn=manager,o=University of Cambridge,c=UK" pass=known ldap:///o=University%20of%20Cambridge,c=UK?sn?sub?(cn=*)}{$value}fail}
56 > Failed: lookup of "size=1 time=0 user="cn=manager,o=University of Cambridge,c=UK" pass=known ldap:///o=University%20of%20Cambridge,c=UK?sn?sub?(cn=*)" gave DEFER: failed to bind the LDAP connection to server NULL:389 - LDAP error 49: Invalid credentials
58 > cn="Philip Hazel" sn=Hazel
59 > ${lookup ldap {ldap:///o=University%20of%20Cambridge,c=UK?sn,cn?sub?(cn=Philip%20Hazel)}{$value}fail}
60 > cn="Philip Hazel" sn="Hazel"
62 > cn="Philip Hazel" sn=Hazel objectClass=person
63 > ${lookup ldap {ldap:///o=University%20of%20Cambridge,c=UK??sub?(cn=Philip%20Hazel)}{$value}fail}
64 > cn="Philip Hazel" sn="Hazel" objectClass="person"
67 > ${lookup ldapm {ldap:///o=University%20of%20Cambridge,c=UK?cn?sub?(cn=Phil%20Hazel)}{$value}fail}
71 > cn="P Hazel" cn="Phil Hazel" sn=Hazel objectClass=person
72 > ${lookup ldapm {ldap:///o=University%20of%20Cambridge,c=UK??sub?(cn=Phil%20Hazel)}{$value}fail}
73 > cn="P Hazel, Phil Hazel" sn="Hazel" objectClass="person"
74 cn="P Hazel, Phil Hazel" sn="Hazel" objectClass="person"
76 > cn=P Hazel, o=University of Cambridge, c=UK
77 > ${lookup ldapdn {ldap:///o=University%20of%20Cambridge,c=UK??sub?(cn=manager)}{$value}fail}
78 > cn=manager,o=University of Cambridge,c=UK
80 > Expect too many results error
81 > Failed: lookup of "ldap:///o=University%20of%20Cambridge,c=UK?sn?sub?(cn=*)" gave DEFER: LDAP search: more than one entry (6) was returned (filter not specific enough?)
84 > ${if ldapauth {size=1 time=0 user="cn=manager,o=University of Cambridge,c=UK" pass=secret ldap:///o=University%20of%20Cambridge,c=UK?sn?sub?(cn=*)}{yes}{no}}
88 > ${if ldapauth {size=1 time=0 user="cn=manager,o=University of Cambridge,c=UK" pass=known ldap:///o=University%20of%20Cambridge,c=UK?sn?sub?(cn=*)}{yes}{no}}
92 > ${if ldapauth {size=1 time=0 user="cn=manager,o=University of Cambridge,c=UK" pass= ldap:///o=University%20of%20Cambridge,c=UK?sn?sub?(cn=*)}{yes}{no}}
96 > ${if ldapauth {size=1 time=0 user="cn=manager,o=University of Cambridge,c=UK" pass=known ldaps://127.0.0.1/o=University%20of%20Cambridge,c=UK?sn?sub?(cn=*)}{yes}{no}}
99 > Expect failure to contact server
100 > ${if ldapauth {size=1 time=0 user="cn=manager,o=University of Cambridge,c=UK" pass=known ldaps://127.0.0.1:9999/o=University%20of%20Cambridge,c=UK?sn?sub?(cn=*)}{yes}{no}}
101 > Failed: failed to bind the LDAP connection to server 127.0.0.1:9999 - ldap_bind() returned -1
104 > ${if ldapauth { size=1 time=0 user="cn=manager,o=University of Cambridge,c=UK" pass=secret ldap:///o=University%20of%20Cambridge,c=UK?sn?sub?(cn=*)}{yes}{no}}
108 > ${if ldapauth { size=1 time=0 user=cn%3dmanager%2co%3DUniversity%20of%20Cambridge%2Cc%3dUK pass=secret ldap:///o=University%20of%20Cambridge,c=UK?sn?sub?(cn=*)}{yes}{no}}
111 > Expect syntax error
112 > ${lookup ldap {ldapz:///o=University%20of%20Cambridge,c=UK?sn?sub?(cn=Philip%20Hazel)}{}fail}
113 > Failed: lookup of "ldapz:///o=University%20of%20Cambridge,c=UK?sn?sub?(cn=Philip%20Hazel)" gave DEFER: LDAP URL does not start with "ldap://", "ldaps://", or "ldapi://" (it starts with "ldapz:///o=Unive...")
115 > Expect error for missing user
116 > ${if ldapauth {size=1 time=0 pass=secret ldap:///o=University%20of%20Cambridge,c=UK?sn?sub?(cn=*)}{yes}{no}}
117 > Failed: ldapauth lookups must specify the username and password
119 > Expect error for missing password
120 > ${if ldapauth {size=1 time=0 user="cn=manager,o=University of Cambridge,c=UK" ldap:///o=University%20of%20Cambridge,c=UK?sn?sub?(cn=*)}{yes}{no}}
121 > Failed: ldapauth lookups must specify the username and password
123 > Expect "no" because of empty password
124 > ${if ldapauth {size=1 time=0 user="cn=manager,o=University of Cambridge,c=UK" pass="" ldap:///o=University%20of%20Cambridge,c=UK?sn?sub?(cn=*)}{yes}{no}}
127 > Expect "FAILED" because no such object
128 > ${lookup ldap {ldap:///o=JUNK}{}{FAILED}}
131 > Expect "P*Hazel (starry)"
132 > ${lookup ldap {ldap:///o=University%20of%20Cambridge,c=UK?cn?sub?(cn=P%5C2AHazel*)}{$value}fail}
135 > DN is: cn=P*Hazel,o=University of Cambridge,c=UK
138 > ${lookup ldap {ldap:///cn=P%5C%2CHazel,o=University%20of%20Cambridge,c=UK?cn?sub?(cn=*)}{$value}fail}
141 > Expect syntax error
142 > ${if ldapauth { soze=1 time=0 user="cn=manager,o=University of Cambridge,c=UK" pass=secret ldap:///o=University%20of%20Cambridge,c=UK?sn?sub?(cn=*)}{yes}{no}}
143 > Failed: unknown parameter "soze=" precedes LDAP URL
145 > Expect syntax error
146 > ${if ldapauth { size=1 time=0 user"cn=manager,o=University of Cambridge,c=UK" pass=secret ldap:///o=University%20of%20Cambridge,c=UK?sn?sub?(cn=*)}{yes}{no}}
147 > Failed: unknown parameter "user"cn=" precedes LDAP URL
156 > Expect 2 x "Hazel" (using ldaps)
157 > ${lookup ldap {user="cn=manager,o=University of Cambridge,c=UK" pass=secret ldaps://127.0.0.1/o=University%20of%20Cambridge,c=UK?sn?sub?(cn=Philip%20Hazel)}{}fail}
171 > ${lookup ldap {ldapi://127.0.0.1/o=University%20of%20Cambridge,c=UK?sn?sub?(cn=Philip%20Hazel)}{}fail}
172 > Failed: lookup of "ldapi://127.0.0.1/o=University%20of%20Cambridge,c=UK?sn?sub?(cn=Philip%20Hazel)" gave DEFER: ldapi requires an absolute path ("127.0.0.1" given)
174 > ${lookup ldap {user="cn=manager,o=University of Cambridge,c=UK" pass="se"cret" ldaps://127.0.0.1/o=University%20of%20Cambridge,c=UK?sn?sub?(cn=Philip%20Hazel)}{}fail}
175 > Failed: lookup of "user="cn=manager,o=University of Cambridge,c=UK" pass="se\"cret" ldaps://127.0.0.1/o=University%20of%20Cambridge,c=UK?sn?sub?(cn=Philip%20Hazel)" gave DEFER: failed to bind the LDAP connection to server 127.0.0.1:636 - LDAP error 49: Invalid credentials
177 > Expect ldap_search to fail
178 > Failed: lookup of "ldap:///o=top?mailRoutingAddress,mailHost,objectClass?sub?(&(mailLocalAddress=3-1546081-domain.net?wendling@stderr.efficientimpacte.com)(objectClass=inetLocalMailRecipient))" gave DEFER: ldap_search failed: -7, Bad search filter
180 > Expect "Hazel" - checking referrals syntax
181 > ${lookup ldap {time=1 referrals=nofollow ldap:///o=University%20of%20Cambridge,c=UK?sn?sub?(cn=Philip%20Hazel)}{$value}fail}