Cleanup interfaces and allow the errorMessage ldap field to be used
Use the correct ldap server-side error code
LDAPResultNotSupported(92) is for a client side error
LDAPResultUnavailable(52) is for when a subsystem is not available
LDAPResultOther(80) is for generic server errors
Provide better errors
Fix binding dn to connection
Fix tests
Make handleSearchRequest conform to rfc4511
Arranges to start the server before running ldap queries removing flakiness
Uses contexts to limit individual command execution time to 100ms
Ensure temporary files use the managed t.TempDir() directory
Set log output to the test output so that go test has a clean output
* switch nmcclain/asn1-ber to go-asn1-ber/and1-ber.
This newer package has ben updated with tests, and looks to actually be supported.
It is also is a forked version of nmcclain/asn1-ber, so supports the same API.
* no need to print errors if client disconnects early and unexpectedly
* added in Close method on server to avoid a race condition
* test ssl certs are untrusted, ldapsearch needs to be told to allow untrusted certs
* Extra time.Wait causes the test to fail
* removed singaling with a custom quit chanel
* feat: support StartTLS in server
* lint: fmt and imports
* feat: rename library to be used by glauth
* chore: renamed packages
---------
Co-authored-by: Daniel Barney <daniel@thoughtplot.io>
Co-authored-by: Mark Rushakoff <mark@influxdata.com>
Co-authored-by: shipperizer <alexcabb@gmail.com>