[root@H0f ~]# cat /etc/ssh/sshd_config
#update by H0f --
# $OpenBSD: sshd_config,v 1.80 // :: djm Exp $ # This is the sshd server system-wide configuration file. See
# sshd_config() for more information. # This sshd was compiled with PATH=/usr/local/bin:/bin:/usr/bin # The strategy used for options in the default sshd_config shipped with
# OpenSSH is to specify options with their default value where
# possible, but leave them commented. Uncommented options change a
# default value. #Port #ssh预设端口
#AddressFamily any
#ListenAddress 0.0.0.0 # 监听的主机适配卡
#ListenAddress :: ## 监听所有的SSH联机 # Disable legacy (protocol version ) support in the server for new
# installations. In future the default will change to require explicit
# activation of protocol
Protocol # 选择的 SSH 协议版本 # HostKey for protocol version # SSH version
#HostKey /etc/ssh/ssh_host_key # SSH version 使用的私钥
# HostKeys for protocol version # SSH version
#HostKey /etc/ssh/ssh_host_rsa_key# SSH version 使用的 RSA 私钥
#HostKey /etc/ssh/ssh_host_dsa_key #SSH version 使用的 DSA 私钥 # Lifetime and size of ephemeral version server key
#KeyRegenerationInterval 1h #key建立时间
#ServerKeyBits # Server key 的长度 # Logging
# obsoletes QuietMode and FascistLogging
#SyslogFacility AUTH
SyslogFacility AUTHPRIV #指定 sshd() 将日志消息通过哪个日志子系统(facility)发送
#LogLevel INFO #登录记录的等级 # Authentication: #LoginGraceTime 2m #限制用户必须在指定的时限内认证成功
#PermitRootLogin yes #允许root用户远程登录
#StrictModes yes #指定是否要求 sshd() 在接受连接请求前对用户主目录和相关的配置文件进行宿主和权限检查。
#MaxAuthTries #指定每个连接最大允许的认证次数。默认值是
#MaxSessions #最大允许保持多少个未认证的连接。默认值是 #RSAAuthentication yes #是否允许使用纯 RSA 公钥认证。仅用于SSH-。默认值是"yes"
RSAAuthentication no
#PubkeyAuthentication yes #是否允许公钥认证。仅可以用于SSH-。默认值为"yes"。
PubkeyAuthentication no
#AuthorizedKeysFile .ssh/authorized_keys #存放该用户可以用来登录的 RSA/DSA 公钥。
#AuthorizedKeysCommand none #是否允许authorized_keys中使用command项
#AuthorizedKeysCommandRunAs nobody #限制能够在authorized_keys中使用command项的用户 # For this to work you will also need host keys in /etc/ssh/ssh_known_hosts
#是否开启基于rhosts的主机RSA算法认证,密钥存放于/etc/ssh/ssh_known_hosts
#RhostsRSAAuthentication no #是否开启基于主机的密钥认证
# similar for protocol version
#HostbasedAuthentication no #是否开启基于主机的密钥认证
# Change to yes if you don't trust ~/.ssh/known_hosts for
# RhostsRSAAuthentication and HostbasedAuthentication
#IgnoreUserKnownHosts no #设置是否忽略主机用户识别,前提是/.ssh/kown_hosts是否可信
# Don't read the user's ~/.rhosts and ~/.shosts files
#IgnoreRhosts yes #不查询用户主目录下的/.rhosts和/.shosts文件 # To disable tunneled clear text passwords, change to no here!
#PasswordAuthentication yes #是否允许使用基于密码的认证
#PermitEmptyPasswords no #是否允许密码为空的用户远程登录
PasswordAuthentication yes # Change to no to disable s/key passwords
#ChallengeResponseAuthentication yes
ChallengeResponseAuthentication no #不开启质疑-应答认证 # Kerberos options #要使用Kerberos认证,服务器需要一个可以校验 KDC identity 的 Kerberos servtab 。
#KerberosAuthentication no #是否允许使用基于 Kerberos的用户认证。默认值为”no”。仅用于SSH-
#KerberosOrLocalPasswd yes #如果 Kerberos 密码认证失败,那么该密码还将要通过其它的认证机制(比如 /etc/passwd)。默认值为”yes”。
#KerberosTicketCleanup yes #是否在用户退出登录后自动销毁用户的 ticket 。默认值是”yes”
#KerberosGetAFSToken no #如果使用了 AFS 并且该用户有一个 Kerberos TGT,那么开启该指令后,
将会在访问用户的家目录前尝试获取一个 AFS token 。默认为”no”
#KerberosUseKuserok yes # GSSAPI options
#GSSAPIAuthentication no #是否允许使用基于 GSSAPI 的用户认证。默认值为”no”。仅用于SSH-。
#GSSAPIAuthentication no
#GSSAPICleanupCredentials yes #是否在用户退出登录后自动销毁用户凭证缓存。默认值是”yes”
GSSAPICleanupCredentials yes
#GSSAPIStrictAcceptorCheck yes #是否对接收到的用户凭证严格校验
#GSSAPIKeyExchange no #是否开启密钥交换 # Set this to 'yes' to enable PAM authentication, account processing,
# and session processing. If this is enabled, PAM authentication will
# be allowed through the ChallengeResponseAuthentication and
# PasswordAuthentication. Depending on your PAM configuration,
# PAM authentication via ChallengeResponseAuthentication may bypass
# the setting of "PermitRootLogin without-password".
# If you just want the PAM account and session checks to run without
# PAM authentication, then enable this but set PasswordAuthentication
# and ChallengeResponseAuthentication to 'no'.
#UsePAM no
UsePAM yes #启用pam认证 # Accept locale-related environment variables
AcceptEnv LANG LC_CTYPE LC_NUMERIC LC_TIME LC_COLLATE LC_MONETARY LC_MESSAGES
AcceptEnv LC_PAPER LC_NAME LC_ADDRESS LC_TELEPHONE LC_MEASUREMENT
AcceptEnv LC_IDENTIFICATION LC_ALL LANGUAGE
AcceptEnv XMODIFIERS #AllowAgentForwarding yes
#AllowTcpForwarding yes #允许TCP转发
#GatewayPorts no #转发路径端口
#X11Forwarding no #是否允许进行 X11 转发。默认值是"no",设为"yes"表示允许
X11Forwarding yes
#X11DisplayOffset #指定 sshd() X11 转发的第一个可用的显示区(display)数字。默认值是
#X11UseLocalhost yes #否应当将X11转发服务器绑定到本地loopback地址。默认值是"yes"
#PrintMotd yes #设置登录后是否显示/etc/motd文件中的信息
#PrintLastLog yes #设置登录后是否显示上一次登录时间
#TCPKeepAlive yes #keepalive检测
#UseLogin no #是否在交互式登录时启用login
#UsePrivilegeSeparation yes #是否让 sshd()通过创建非特权子进程处理接入请求的方法来进行权限分离 默认值是”yes
#PermitUserEnvironment no #指定是否允许 sshd() 处理 ~/.ssh/environment 以及~/.ssh/authorized_keys 中的 environment= 选项。默认值是”no”。
#Compression delayed #是否对通信数据进行加密,还是延迟到认证成功之后再对通信数据加密 可用值:”yes” “delayed”(默认) “no”
#ClientAliveInterval #设置空闲登录的最大时长
#ClientAliveCountMax #在没收到任何数据的时候,最多向3个客户端进行keepalive检测
#ShowPatchLevel no #显示补丁级别
#UseDNS yes #开启域名解析
#PidFile /var/run/sshd.pid #存放守护进程的默认文件
#MaxStartups :: #最大可以保持多少个未认证的连接
#PermitTunnel no #允许tun设备转发
#ChrootDirectory none #是否允许切换目录 # no default banner path
#Banner none #不设置欢迎词 # override default of no subsystems
Subsystem sftp /usr/libexec/openssh/sftp-server # Example of overriding settings on a per-user basis
#Match User anoncvs
# X11Forwarding no #开启X11转发
# AllowTcpForwarding no # 是否允许TCP转发,默认值为"yes"。
# ForceCommand cvs server #限制命令

sshd_config注释的更多相关文章

  1. SSH/SSL 源码编译安装简易操作说明

    环境:CentOS 6.7 安全加固需求,由于某盟扫描系统主机有SSL系列漏洞,客户要求必须修复: 解决方案:将SSH/SSL升级到最新版本,删除SSL旧版本(实测不删除旧版本某盟扫描无法通过). 当 ...

  2. 使用Ambari安装hadoop集群

    最近需要做些spark的工作,所以弄了几台dell7500就这么准备开始搭建集群,之前用过几台更破的台式机搭建过一次,折腾了半个月之久,终于成功搭建,这次不想走老路,所以网上查了一下,发现一个神器AM ...

  3. SFTP+OpenSSH+ChrootDirectory设置

    账户设置 SFTP的账户直接使用Linux操作系统账户,我们可以用useradd命令来创建账户. 首先建立3个要管理的目录:   1 2 3 mkdir /home/sftp/homepage mkd ...

  4. sftp新建用户步骤

    1,切换root用户2,创建sftp组:groupadd sftp3,创建用户并限制进入路径:useradd -g sftp -s /bin/false testuser 修改密码: passwd t ...

  5. Opensshd 源码升级

    OPenssh 下载地址: http://www.openssh.com/ 以下步骤 OS: 6.x  安装Opensshd 7.4p1 验证通过 6.8  安装Opensshd 7.6p1 验证通过 ...

  6. Ubuntu配置SecureCRT登录

    1. 命令行切换到root用户 备注:ubuntu默认root用户没有设置密码,切换需要首先设置密码 sudo passwd root 按照提示输入当前用户密码 按照提示输入要设置的root用户密码 ...

  7. centos升级openssl方法及步骤

    1.下载要升级到的openssl包https://cdn.openbsd.org/pub/OpenBSD/OpenSSH/portable/openssh-7.4p1.tar.gz 2.升级opens ...

  8. 更改ssh,ftp默认端口

    1.  更改ssh端口 放置升级openssh之后做此步骤 配置文件/etc/ssh/sshd_config 注释掉Subsystem      sftp    /usr/libexec/openss ...

  9. sftp 建立用户

    1.创建sftp组:#groupadd sftp 2.创建测试账户:#useradd -g sftp -s /bin/false testuser 修改密码:# passwd sftp 3.修改测试账 ...

随机推荐

  1. Libcurl 简明使用指南

    http://blog.csdn.net/weiling_shen/article/details/7620397 我们的程序中使用的是人家的Easy.h头文件.....完成文件的上传和下传. 尤其是 ...

  2. Luogu 4409 [ZJOI2006]皇帝的烦恼

    BZOJ 1863 lyd口中的夹B递推. 挺妙的解法. 第一个感觉是找到一个最大的相邻的$a_i + a_{i - 1}$就可以了,但是这个想法大概只对了一半,一半的意思是说只有在$n$为偶数的时候 ...

  3. Mat类

    1.Mat类 早期的opencv中,使用IplImage和CvMat数据结构来表示图像.IplImage和 CvMat 都是c语言的结构.使用这两个结构的问题是内存需要手动管理,开发者必须清楚的知道何 ...

  4. Linux操作系统下IPTables配置方法详解

    如果你的IPTABLES基础知识还不了解,建议先去看看. 们来配置一个filter表的防火墙 1.查看本机关于IPTABLES的设置情况 [root@tp ~]# iptables -L -n Cha ...

  5. Android的性能优化

    ArrayList和Vector ArrayList和Vector都是内部以数组实现的List,它们两唯一的区别就是对多线程的支持,ArrayList是线程不安全的,而Vector内部对大多数方法都做 ...

  6. Django之博客系统邮件分享博客

    在上一章中,我们创建了一个基础的博客应用,我们能在http://127.0.0.1:8000/blog/显示我们的博客.在这一章我们将尝试给博客系统添加一些高级的特性,比如通过email来分享帖子,添 ...

  7. Educational Codeforces Round 60 (Rated for Div. 2)D(思维,DP,快速幂)

    #include <bits/stdc++.h>using namespace std;const long long mod = 1e9+7;unordered_map<long ...

  8. 转载Json和Xml的区别,以及它们的底层是如何处理的

    XML:可扩展标记语言       JSON:轻量级的数据交换格式 区别: 1.可读性方面:基本相同,Xml的可读性较好些: 2.可扩展性方面:都有较好的扩展性: 3.编码难度方面:json的编码较容 ...

  9. 防雪崩利器:熔断器 Hystrix 的原理与使用(转)

    https://segmentfault.com/a/1190000005988895 前言 分布式系统中经常会出现某个基础服务不可用造成整个系统不可用的情况, 这种现象被称为服务雪崩效应. 为了应对 ...

  10. window.performance

    利用window.performance查看网页性能 一般我们可以通过浏览器的调试工具-网络面板,或者代理工具查看网页加载过程中的各个阶段的耗时.而利用window.performance属性则可以获 ...