From dfe22c5b083443ed00df9431cbd3cd7a7b4fd6a7 Mon Sep 17 00:00:00 2001 From: Luke Shumaker Date: Tue, 19 Dec 2017 00:00:43 -0500 Subject: nslcd_{systemd,server}: log more things --- nslcd_systemd/nslcd_systemd.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'nslcd_systemd/nslcd_systemd.go') diff --git a/nslcd_systemd/nslcd_systemd.go b/nslcd_systemd/nslcd_systemd.go index c0024e2..c05b0e9 100644 --- a/nslcd_systemd/nslcd_systemd.go +++ b/nslcd_systemd/nslcd_systemd.go @@ -107,12 +107,13 @@ func handler(backend nslcd_server.Backend, limits nslcd_server.Limits, conn *net Logger: nslcd_server.LoggerFromContext(ctx), } ctx = context.WithValue(ctx, nslcd_server.LoggerKey, log) + defer log.Info("Connection closed") cred, err := getpeercred(conn) if err != nil { - log.Debug("Connection from unknown client") + log.Info("Connection from unknown client") } else { - log.Debug(fmt.Sprintf("Connection from pid=%v uid=%v gid=%v", + log.Info(fmt.Sprintf("Connection from pid=%v uid=%v gid=%v", cred.Pid, cred.Uid, cred.Gid)) ctx = context.WithValue(ctx, nslcd_server.PeerCredKey, cred) } -- cgit v1.2.3