fix compatibility issues with net/ldap