diff options
Diffstat (limited to '')
-rw-r--r-- | examples/server.go | 6 | ||||
-rw-r--r-- | tests/cert_DONOTUSE.pem (renamed from examples/cert_DONOTUSE.pem) | 0 | ||||
-rw-r--r-- | tests/key_DONOTUSE.pem (renamed from examples/key_DONOTUSE.pem) | 0 |
3 files changed, 4 insertions, 2 deletions
diff --git a/examples/server.go b/examples/server.go index dca74ed..3341991 100644 --- a/examples/server.go +++ b/examples/server.go @@ -24,7 +24,9 @@ func main() { s.SearchFunc("", handler) // start the server - if err := s.ListenAndServe("localhost:3389"); err != nil { + listen := "localhost:3389" + log.Printf("Starting example LDAP server on %s", listen) + if err := s.ListenAndServe(listen); err != nil { log.Fatal("LDAP Server Failed: %s", err.Error()) } } @@ -33,7 +35,7 @@ type ldapHandler struct { } ///////////// Allow anonymous binds only -func (h ldapHandler) Bind(bindDN, bindSimplePw string, conn net.Conn) (uint64, error) { +func (h ldapHandler) Bind(bindDN, bindSimplePw string, conn net.Conn) (ldap.LDAPResultCode, error) { if bindDN == "" && bindSimplePw == "" { return ldap.LDAPResultSuccess, nil } diff --git a/examples/cert_DONOTUSE.pem b/tests/cert_DONOTUSE.pem index ee14324..ee14324 100644 --- a/examples/cert_DONOTUSE.pem +++ b/tests/cert_DONOTUSE.pem diff --git a/examples/key_DONOTUSE.pem b/tests/key_DONOTUSE.pem index 7feaa11..7feaa11 100644 --- a/examples/key_DONOTUSE.pem +++ b/tests/key_DONOTUSE.pem |