Linode Forum
Linode Community Forums
 FAQFAQ    SearchSearch    MembersMembers      Register Register 
 LoginLogin [ Anonymous ] 
Post new topic  Reply to topic
Author Message
PostPosted: Wed Feb 20, 2013 10:41 am 
Offline
Senior Member

Joined: Tue Aug 17, 2010 5:00 pm
Posts: 61
While hunting down toher issues with my VPS, I randomly checked auth.log and I see an alarming number of attempted logins with failures.

For example, this guy tried at least 30 times, all with a different port number.
Code:
Feb 20 05:41:44 traviselijah sshd[8802]: reverse mapping checking getaddrinfo for 31-xdsl.anitex.by [213.184.241.31] failed - POSSIBLE BREAK-IN ATTEMPT!
Feb 20 05:41:44 traviselijah sshd[8802]: pam_unix(sshd:auth): authentication failure; logname= uid=0 euid=0 tty=ssh ruser= rhost=213.184.241.31  user=root
Feb 20 05:41:46 traviselijah sshd[8802]: Failed password for root from 213.184.241.31 port 57022 ssh2


Top
   
PostPosted: Wed Feb 20, 2013 10:46 am 
Offline
Senior Member
User avatar

Joined: Tue Apr 13, 2004 6:54 pm
Posts: 833
This is regular internet noise. It's not a direct attack on you, it's just automated scripting. Ways to mitigate include disabling root login via ssh (or, at least, require ssh keys); move the SSH port to something different; use "fail2ban" or similar to block multiple attempts after a few are detected. Search the forums and you'll find lots of comments :-)

_________________
Rgds
Stephen
(Linux user since kernel version 0.11)


Top
   
PostPosted: Wed Feb 20, 2013 6:22 pm 
Offline
Senior Member
User avatar

Joined: Wed Mar 17, 2004 4:11 pm
Posts: 554
Website: http://www.unixtastic.com
Location: Europe
Everyone gets these automated SSH login attempts. You should disable sshd password authentication on internet connected systems.

I once hacked sshd to log the passwords these scripts use. It's all dictionary words, names, and strings like 'letmein' and 'passw0rd'.


Top
   
PostPosted: Mon Feb 25, 2013 1:18 pm 
Offline
Senior Member

Joined: Tue Aug 17, 2010 5:00 pm
Posts: 61
OK, then dumb question. I am trying to figure out disabling password ssh attempts using the guides, but for those using putty, it directs you to the putty guide, but it also does not tell me how to create a key to use on my Windows box

http://library.linode.com/securing-your ... entication

And

http://library.linode.com/networking/using-putty

unless I am completely dense and do not understand the other terms used...


Top
   
PostPosted: Mon Feb 25, 2013 1:18 pm 
Offline
Senior Member

Joined: Tue Aug 17, 2010 5:00 pm
Posts: 61
Edit: double post mistake


Top
   
PostPosted: Tue Feb 26, 2013 5:20 am 
Offline
Senior Member
User avatar

Joined: Thu Jul 12, 2012 3:55 pm
Posts: 133
Website: http://www.amitywebsolutions.co.uk
Are you, or a few people, the only ones who need SSH access? We block all ports except http,https,email by the firewall except to approved IPs or dynamic hostnames (because only a few of us need access). So to the rest of the world no one can even get to the login screens/prompts. Our servers are web servers, and it amazes me how unsecure web servers are by default (e.g. everyone in the world can get to a SSH/Control Panel/FTP login screen). We've been hacked because someone knew a way in using the root account in Cpanel file manager. Thats when we decided to block all ports.

_________________
Web Development Agency in South Wales


Top
   
PostPosted: Wed Feb 27, 2013 2:05 am 
Offline
Senior Member
User avatar

Joined: Sun Jan 18, 2009 2:41 pm
Posts: 830
You can create a public/private keypair on Windows using puttygen. Pay attention to 8.2.10 - you will need to have the public key in OpenSSH's format to place it in authorized_keys on your Linode.


Top
   
PostPosted: Thu Feb 28, 2013 11:48 am 
Offline
Senior Member

Joined: Wed Jun 27, 2012 10:00 pm
Posts: 87
Website: http://hemonc.org/wiki/Main_Page
One of the very first things I did was disable root & password-only logins. Fail2ban helps a bit too.

Also, if you use both Windows and Mac, keep in mind that Putty uses a nonstandard format for the its SSH private keys, and it won't work in Terminal on Mac. To get it to work, you'd need to load the key in puttygen (on Windows), convert it to OpenSSH's format (via Conversions->Export OpenSSH key).

_________________
Amateur, eager to learn.
My hematology, oncology, and chemotherapy regimen wiki


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic


Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
Jump to:  
RSS

Powered by phpBB® Forum Software © phpBB Group