renamed
This commit is contained in:
parent
faa58ab03b
commit
f6f0502b9d
1 changed files with 11 additions and 0 deletions
11
smtp_tls_stats.sh
Executable file
11
smtp_tls_stats.sh
Executable file
|
|
@ -0,0 +1,11 @@
|
|||
#!/usr/bin/env bash
|
||||
# Author: Oliver Ladner <oli@lugh.ch>
|
||||
# License: LGPL
|
||||
#
|
||||
# greps mail.log for TLS debug loglines and displays sender count
|
||||
# and cipher used.
|
||||
|
||||
MIN_MAILS=2
|
||||
echo -e "Count\tCipher used\tSending domain"
|
||||
echo "--------------------------------------"
|
||||
grep 'Anonymous TLS connection established from' /var/log/mail.log | sed -r 's/\[[0-9.]*\]://g' | awk {'print $15,$11'} | sort | uniq -c -i | while read line; do [[ $(grep -oE '^\s*[0-9]+' <<< $line) -gt $MIN_MAILS ]] && echo $line | tr -s ' ' '\t'; done | sort -k 2,2 -k 1,1rn
|
||||
Loading…
Add table
Add a link
Reference in a new issue