Results 1 to 7 of 7
  1. #1
    Join Date
    Oct 2011
    Location
    Dublin, PA
    Posts
    381
    Thanks
    33
    Thanked 18 Times in 16 Posts
    Rep Power
    10

    Find out who's trying to break into your box

    The /var/log/btmp file shows you failed logins. you can use last to read it:

    Code:
    last -f /var/log/btmp
    or simply just use lastb

    Code:
    lastb
    Then spice it up a little bit ...

    Show the top 10 IPs with failed logins (first column is failed # of tries, then 2nd column is the IP)
    Code:
    lastb | awk '{print $3}' | sort | uniq -c | sort -rn | head -10
    Show the top 10 usernames with failed logins
    Code:
    lastb | awk '{print $1}' | sort | uniq -c | sort -rn | head -10

  2. The Following User Says Thank You to Rob For This Useful Post:

    DaReaper (05-02-2012)




  3. #2
    Join Date
    Oct 2011
    Posts
    46
    Thanks
    0
    Thanked 7 Times in 6 Posts
    Rep Power
    10
    by default:
    `last` uses /var/log/wtmp (shows a list of users who logged in)
    `lastb` uses /var/log/btmp (shows bag login attempts)

  4. #3
    Join Date
    Nov 2011
    Posts
    88
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Rep Power
    2
    That's quite interesting I think..CSF/WHM notifies me of failed login attempts already though.

  5. #4
    Join Date
    Jan 2012
    Location
    Bahrain
    Posts
    187
    Thanks
    4
    Thanked 1 Time in 1 Post
    Rep Power
    2
    Quite impressive terminal code there! Two months ago i noticed through my Kloxo's lxguard logs, i noticed around 200+ login failed attempts from different IP's. I could have never thought that a host not advertised a lot would attract so much intrusion.

    Glad there are stuff to detect these and block them out.

  6. #5
    Join Date
    Apr 2012
    Posts
    84
    Thanks
    5
    Thanked 1 Time in 1 Post
    Rep Power
    2
    Yeah its important to check for bad logins, you may look and think, oh well at least they are not getting in, but it could easily be a DDoS. Linux logs are just awesome,

  7. #6
    Join Date
    Jan 2012
    Location
    Bahrain
    Posts
    187
    Thanks
    4
    Thanked 1 Time in 1 Post
    Rep Power
    2
    Quote Originally Posted by scotty View Post
    Yeah its important to check for bad logins, you may look and think, oh well at least they are not getting in, but it could easily be a DDoS. Linux logs are just awesome,
    I had a question in mind when you mentioned about DDoS. Do Dos deflators really works that well when it comes to such situations? There could be different kind of attacks. I've noticed that HTTP attacks from few IP's are much easier to stop than TCP.

  8. #7
    Join Date
    Apr 2012
    Posts
    124
    Thanks
    5
    Thanked 1 Time in 1 Post
    Rep Power
    2
    Quote Originally Posted by DaReaper View Post
    I had a question in mind when you mentioned about DDoS. Do Dos deflators really works that well when it comes to such situations? There could be different kind of attacks. I've noticed that HTTP attacks from few IP's are much easier to stop than TCP.
    It would depend on the size of attack - I have been on the other end of such a DDoS which was huge, the deflators did not hold firm. Anyhow since I have had no such problems. So they could be working.

 

 

Similar Threads

  1. Replies: 6
    Last Post: 11-28-2011, 01:10 PM
  2. HP Needs to Find a Plan and Stick to It
    By Fred in forum Linux News
    Replies: 0
    Last Post: 11-01-2011, 12:30 PM
  3. Replies: 0
    Last Post: 10-29-2011, 08:52 AM

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
           








Check out Linux Central for Linux software and other goodies!





» Stats

Members: 3,574
Threads: 3,920
Posts: 9,442
Top Poster: Fred (1,486)
Welcome to our newest member, dallas03

» Links



Powered by vBadvanced CMPS