[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. MySql 5.7中添加用户,新建数据库,用户授权,删除用户,修改密码

    转自http://blog.csdn.net/w690333243/article/details/76576952 1.新建用户 创建test用户,密码是1234. MySQL -u root -p ...

  2. U盘文件或目录损坏且无法读取怎么解决

    转自 http://jingyan.baidu.com/article/020278118afaec1bcc9ce5df.html U盘文件或目录损坏且无法读取怎么解决 听语音 | 浏览:37504 ...

  3. c语言输入数据

    比如要求输入一行数据(注意:没有给出输入多少个),并且以空格隔开那么就可以如下进行判断 '; ],temp,i=; while(c!='\n') { scanf("%d%c",&a ...

  4. essential C++中关于面向过程和面向对象的说明

    昨天在阅读essential C++中看到了一个关于面向过程和面向对象的区别的例子,感觉挺好的.记录下来.... 这个例子是关于照相机的.照相机有三个性质,一个是控制位置:通常使用3个浮点数据来表示其 ...

  5. NIO、AIO

  6. backstop无法访问

    解决方案:重新build代码,重新启动虚拟机.再等一会儿,就OK了.

  7. gRPC官方文档(概念)

    文章来自gRPC 官方文档中文版 gRPC 概念 本文档通过对于 gRPC 的架构和 RPC 生命周期的概览来介绍 gRPC 的主要概念.本文是在假设你已经读过文档部分的前提下展开的.针对具体语言细节 ...

  8. [hdu 2604] Queuing 递推 矩阵快速幂

    Problem Description Queues and Priority Queues are data structures which are known to most computer ...

  9. 读《JavaScript权威指南》笔记(四)--数组、函数

    一.数组 1.数组是值的有序集合.每个值叫做一个元素,而每个元素在数组中有一个位置,以数字表示,称为索引.JavaScript数组是无类型的:数组元素可以是任意类型,并且同一个数组中的不同元素也可能有 ...

  10. P1900 自我数

    题意: 对于每一个正整数n,我们定义d(n)为n加上它每一位数字的和. 例如,d(75)=75+7+5=87.给定任意正整数n作为一个起点,都能构造出一个无限递增的序列:n, d(n), d(d(n) ...