Closed Bug 555069 Opened 11 years ago Closed 11 years ago
Add IP to logging
We should add the request's IP to the logging. Make sure we check X_FORWARDED_FOR. Django should have this built in somewhere, if not, maybe a patch would be appropriate. P5 for now. Whoever gets time can do this, or I will eventually.
Django used to have a middleware for this: http://docs.djangoproject.com/en/dev/releases/1.1/#id1
Assignee: nobody → james
Target Milestone: 5.9 → 5.10
Summary: Add IP to loggging → Add IP to logging
Here's middleware to replace the old Django middleware. http://github.com/jsocol/commonware
I think that will work, r+. Replacing REMOTE_ADDR seems fine but I don't think I've seen it before. Shouldn't matter though.
Wil, I followed Django's old method. If you'd rather it do something else, I can change it.
I think it'll work fine :)
r? http://github.com/jsocol/zamboni/commit/17f4259888aafa1ed65739f00f9a582b2b972f67 Also involved updates to commonware: http://github.com/jsocol/commonware
Added some comments on the commit. r+, thanks
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
11 years ago
Product: addons.mozilla.org → addons.mozilla.org Graveyard
You need to log in before you can comment on or make changes to this bug.