Spam statistics
I wanted to see how much spam I recieved over time so I wrote a small bash script which is run whenever
procmail∞ is given a piece of mail flagged as spam. It is then possible to make a nice plot using gnuplot.
Download
spam_stats.sh∞
Requirements
Installation
Make the script executable and put the script somewhere comfortable. You probably want to edit the
data_file,
plot_file and
gnuplot_add variables found at the top of the file.
If you use procmail then you can use the following procmail rule. In my case, the classification is done by
SpamBayes∞ but a similar rule should work for most other classification systems.
:0 fw:sslock
* ^X-Spambayes-Classification: spam
| spam_stats.sh report
Usage
To create a plot simply run the following command.
$ spam_stats.sh plot
Example output
CategoryComputing