Kali初始化配置——启用SSH
2017-10-20 14:00
232 查看
启用SSH
vi /etc/ssh/sshd_config #修改config文件内容 PermitRootLogin yes #修改内容 PasswordAuthentication yes #修改内容
修改完成示例:
root@kali:~# vi /etc/ssh/sshd_config # possible, but leave them commented. Uncommented options override the # default value. #Port 22 #AddressFamily any #ListenAddress 0.0.0.0 #ListenAddress :: #HostKey /etc/ssh/ssh_host_rsa_key #HostKey /etc/ssh/ssh_host_ecdsa_key #HostKey /etc/ssh/ssh_host_ed25519_key # Ciphers and keying #RekeyLimit default none # Logging #SyslogFacility AUTH #LogLevel INFO # Authentication: #LoginGraceTime 2m PermitRootLogin yes #StrictModes yes #MaxAuthTries 6 #MaxSessions 10 #PubkeyAuthentication yes # Expect .ssh/authorized_keys2 to be disregarded by default in future. #AuthorizedKeysFile .ssh/authorized_keys .ssh/authorized_keys2 #AuthorizedPrincipalsFile none #AuthorizedKeysCommand none #AuthorizedKeysCommandUser nobody # For this to work you will also need host keys in /etc/ssh/ssh_known_hosts #HostbasedAuthentication no # Change to yes if you don't trust ~/.ssh/known_hosts for # HostbasedAuthentication #IgnoreUserKnownHosts no # Don't read the user's ~/.rhosts and ~/.shosts files #IgnoreRhosts yes # To disable tunneled clear text passwords, change to no here! PasswordAuthentication yes #PermitEmptyPasswords no # Change to yes to enable challenge-response passwords (beware issues with # some PAM modules and threads) ChallengeResponseAuthentication no # Kerberos options #KerberosAuthentication no #KerberosOrLocalPasswd yes #KerberosTicketCleanup yes #KerberosGetAFSToken no # GSSAPI options 9ad2 #GSSAPIAuthentication no #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 yes #AllowAgentForwarding yes #AllowTcpForwarding yes #GatewayPorts no X11Forwarding yes #X11DisplayOffset 10 #X11UseLocalhost yes #PermitTTY yes PrintMotd no #PrintLastLog yes #TCPKeepAlive yes #UseLogin no #PermitUserEnvironment no #Compression delayed #ClientAliveInterval 0 #ClientAliveCountMax 3 #UseDNS no #PidFile /var/run/sshd.pid #MaxStartups 10:30:100 #PermitTunnel no #ChrootDirectory none #VersionAddendum none # no default banner path #Banner none # Allow client to pass locale environment variables AcceptEnv LANG LC_* # override default of no subsystems Subsystem sftp /usr/lib/openssh/sftp-server # Example of overriding settings on a per-user basis #Match User anoncvs # X11Forwarding no # AllowTcpForwarding no # PermitTTY no # ForceCommand cvs server
启动SSH服务
/etc/init.d/ssh start #启动服务 /etc/init.d/ssh status #查看服务状态
添加SSH自启动
update-rc.d ssh enable #添加ssh开启自动启动
相关文章推荐
- 配置kali2.0实现远程ssh登陆
- ssh--添加json后,初始化配置一直显示There is no result type defined for type 'json' mapped with name
- kali初始化配置——更新
- 华为S5700交换机初始化和配置telnet,ssh用户方法
- Kali配置SSH及开机自启
- Kali配置SSH及开机自启
- SSH配置中Spring容器初始化
- 安装完系统的初始化配置(网卡、防火墙、SSH等):
- 新版raspbian系统的固定IP配置和启用root账户的ssh登录功能的方法
- Kali配置SSH及开机自启
- Kali_linux系统SSH参数配置
- 关于kali开机自动启动ssh服务的方法以及配置kalissh的一些基本操作
- kali中ssh远程登陆及配置
- SSH集成时不用hbm.xml文件的配置方法
- Linux 下配置Git 服务器-使用SSH连接
- git 用不同的邮箱配置不同的ssh
- Fedora17下安装与配置ssh
- SSH免密码登陆配置
- linux下ssh使用和配置
- SSH免密码登陆配置