I had a script that tried to determine the failed login attempts for the
last 5 min (+5 sec) like this:


# diff <(sudo lastb -Fw -t $(date -d "305 sec ago" +%Y%m%d%H%M%S)) <(sudo lastb 
-Fw) | grep "^>"


Now, I am using the following alternative (which does not require `root` user):

$ journalctl --since "305 sec ago" /*bin/sshd /*bin/login --grep
"(FAILED|Invalid user)" 2>/dev/null

Any suggestions or improvements are welcome.

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/2084854

Title:
  last and lastb missing in 24.10

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/util-linux/+bug/2084854/+subscriptions


-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to