1 LDAP_PERSON_QUERY = (&(|(mail=${quote_ldap:${local_part}}@${domain})(alias=${quote_ldap:${local_part}}@${domain}))(objectclass=inetorgperson)) 2 3 ldap_person: 4 debug_print = "R: ldap_person for $local_part@$domain" 5 driver = accept 6 condition = ${if eq {}{${lookup ldap{ \ 7 user="$ldap_service_bind_dn" \ 8 pass=$ldap_service_password \ 9 ldap://$ldap_host:$ldap_port/$ldap_base_dn?mail?sub?LDAP_PERSON_QUERY} \ 10 }}{no}{yes}} 11 transport = people_transport 12 cannot_route_message = Unknown user