From 4c7126d0cdee8b0a81495aff2e3f0b0b79c0a0f1 Mon Sep 17 00:00:00 2001 From: Seth Schoen Date: Sun, 18 Nov 2012 21:31:00 -0800 Subject: [PATCH] basic logging about messages from clients --- server-ca/chocolate.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/server-ca/chocolate.py b/server-ca/chocolate.py index 55cf9e973..3cb66a99d 100755 --- a/server-ca/chocolate.py +++ b/server-ca/chocolate.py @@ -233,6 +233,7 @@ class session(object): recipient = m.request.recipient csr = m.request.csr sig = m.request.sig + self.log("new session from %s" % web.ctx.ip) # Check whether we are the intended recipient of the request. Doing this # before the hashcash check is more work for the server but gives a more # helpful error message (because the hashcash will be wrong automatically @@ -314,6 +315,7 @@ class session(object): r.proceed.polldelay = polldelay def handleexistingsession(self, m, r): + self.log("received message from %s" % web.ctx.ip) if m.request.IsInitialized(): self.die(r, r.BadRequest, uri="https://ca.example.com/failures/requestinexistingsession") return