SA Bugzilla – Bug 2870
Update to sa-stats.pl
Last modified: 2004-01-01 08:35:17 UTC
I spent a few hours hacking on sa-stats.pl and here's what's new:* Bug - fixed regex to allow 'user@example.com:1234' usernames* Enhancement - Added dependency on Parse::Syslog; cleans up regex somewhat and should be more portable* Enhancement - Added 'Top 25 Spam Victims' report* Enhancement - Added aggregate stats for bytes processed, time consumed* Enhancement - the debug flag now does something!Aside from that, I refactored some of the code innards.Preliminary tests show it behaves roughly as it did before and it matches the 'user@example.com' test case posted to SA-Talk.diff vs sa-stats.pl 1.3 follows.
Created attachment 1640 [details] Unified diff to sa-stats.pl v1.3 I don't usually post diffs - what's the accepted norm for patches (I used 'diff -u old new')?
I just tried this and it doesn't work at all for me right now because of New Year's, it seems. Parse::Syslog really doesnt handle dates very well, especially when dealing with years. I'll try to fix this. (The code that should do this seems to be broken)
Fixed.