Commit 0eaefcea authored by ale's avatar ale

Add logging of expirations

parent 63f7c34b
Pipeline #892 passed with stages
in 47 seconds
......@@ -117,6 +117,7 @@ func (s *KeyStore) expire() {
s.mx.Lock()
for u, k := range s.userKeys {
if k.expiry.Before(t) {
log.Printf("forgetting key for %s", u)
wipeBytes(k.pkey)
delete(s.userKeys, u)
}
......
......@@ -28,7 +28,7 @@ func (s *keyStoreServer) handleOpen(w http.ResponseWriter, r *http.Request) {
return
}
log.Printf("decrypted key for %s", req.Username)
log.Printf("decrypted key for %s, ttl=%d", req.Username, req.TTL)
serverutil.EncodeJSONResponse(w, &emptyResponse)
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment