Why the "report after breach" mindset breaks down
What counts as a reportable indicator before a full breach
Scheduling log reviews that actually happen
- Failed SSH authentication attempts grouped by source IP (look for concentration, not just count)
- Successful SSH logins from IPs not on your expected list
- Web application authentication failures above your baseline
- Outbound connections to IPs or domains not in your application's normal communication pattern
- New user accounts or sudoers changes
- Cron job additions or modifications
BASH
#!/bin/bash
# Daily SSH failed-login summary
# Adjust log path for your distro: /var/log/auth.log (Debian/Ubuntu) or /var/log/secure (CentOS/RHEL)
LOG='/var/log/auth.log'
OUTPUT='/var/log/daily-ssh-review.txt'
echo "=== SSH Failed Login Summary: (date) ===" > "OUTPUT"
grep 'Failed password' "LOG" | awk '{print(NF-3)}' | sort | uniq -c | sort -rn >> "$OUTPUT"
echo "" >> "$OUTPUT"
echo "=== Successful logins from non-local IPs ===" >> "$OUTPUT"
grep 'Accepted' "LOG" | grep -v '127.0.0.1' | awk '{print1,2,3,9,11}' >> "$OUTPUT"BASH
# Run daily at 06:00 server time
0 6 * * * /usr/local/bin/daily-ssh-review.shConnecting log findings to BSSN reporting timelines
- Does this meet the threshold for a reportable incident under our sector's BSSN obligations?
- If yes, who initiates the report and through what channel?
What this looks like for hosting and server operators
- Verify log retention periods. Default logrotate configurations on many distributions keep auth logs for four weeks. For IIV-related systems, that may not be enough. Extending retention to 90 days or longer is a common adjustment.
- Confirm that authentication logging captures source IPs, not just success/failure.
- If you provide managed services, consider whether a periodic log summary (even a basic one like the script above) is something you offer or recommend to customers in regulated sectors.
