Best practices for using SSH

Source: Internet
Author: User
Tags ssh access ssh port

Best practices for using SSH
1) only use SSH Protocol 2
2) Limit users SSh access
Allowusers Root Vivek Jerry
White List
Denyuser saroj Anjali Foo
Blacklist
3) Configure idle Log out timeout Interval configuration idle timeout long.
Clientalivecountmax 300
Clientaliveinterval 0
4) Firwall SSH Port # 22
To set the SSH service security access policy using iptables
5) Change SSH port and Limit IP binding
Port 300
Listaddress 192.168.1.5
ListenAddress 202.54.1.5
Do not use the default 22 port
6) Use strong SSH passwords and passphrase
GENPASSWD () {
Local 1=$1
["] = =" "]&& 1=20
TR-DC A-za-z0-9_</dev/urandom | Head-c ${1} | Xargs
}
Use a password that is sufficiently long enough to be complex and regularly replaced.
7) Use public key Based authentication
Use public key authentication.
8) Disable Empty password
9) Thwart SSH crakers (Brute Force attack)
Google:ssh Best Practice
Rate-limit Incoming Port # COnnections
Limit the frequency of SSH access
One) Use Log analyzer
Log good logs, often do log analysis.

Best practices for using SSH

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.