使用Xshell链接Linux、kali更换更新源及kali安装软件
作者:互联网
一、Xshell首次链接kali系统中的ssh
Xshell:帮助我们去连接各种服务平台,方便管理服务器,链路可以加密处理(ssh/vsftp)
1.开启kali中的ssh服务,service ssh start,检测是否开启成功查看状态
/etc/init.d/ssh status 或 netstat -ntulp | 22
2.关闭防火墙(目前) /etc/init.d/iptables stop,然后需要找到ssh的配置文件vi /etc/ssh/sshd_config,修改sshd_config文件,命令为:
vi /etc/ssh/sshd_config
将#PasswordAuthentication no的注释去掉,并且将NO修改为YES //kali中默认是yes
3. 将PermitRootLogin without-password修改为
PermitRootLogin yes
4.重启服务 service ssh restart
若重启失败,则输入/usr/sbin/sshd -T,执行命令找到错误的地方进行修改
设置开机自动启动命令是:update-rc.d ssh enable
5.使用Xshell链接,使用root账号或普通账号,打开xshell-->文件-->新建-->协议选择ssh-->主机输入kali的IP地址,用ifconfig查看,端口默认为22,点击链接,接下来输入root账号,最后输入密码,即可链接
注:ssh服务可以更改端口,修改配置文件,port --> port 2222
二、kali更换更新源
1.ping www.baidu.com ping成功则进入下一步(若ping不成功,看前面有关Linux命令的博客)
vim /etc/apt/sources.list
2.leafpad /etc/apt/sources.list 把里面的东西清理干净,可选择下面的更新源复制粘贴上
#阿里云Kali源
deb http://mirrors.aliyun.com/Kali Kali main non-free contrib
deb-src http://mirrors.aliyun.com/Kali Kali main non-free contrib
deb http://mirrors.aliyun.com/Kali-security Kali/updates main contrib non-fr
#新加坡Kali源
deb http://mirror.nus.edu.sg/Kali/Kali/ Kali main non-free contrib
deb-src http://mirror.nus.edu.sg/Kali/Kali/ Kali main non-free contrib
deb http://security.Kali.org/Kali-security Kali/updates main contrib non-free
deb http://mirror.nus.edu.sg/Kali/Kali-security Kali/updates main contrib non-free
deb-src http://mirror.nus.edu.sg/Kali/Kali-security Kali/updates main contrib non-free
#中科大Kali源
deb http://mirrors.ustc.edu.cn/Kali Kali main non-free contrib
deb-src http://mirrors.ustc.edu.cn/Kali Kali main non-free contrib
deb http://mirrors.ustc.edu.cn/Kali-security Kali/updates main contrib non-f
#中科大Kali源
deb http://mirrors.ustc.edu.cn/Kali Kali main non-free contrib
deb-src http://mirrors.ustc.edu.cn/Kali Kali main non-free contrib
deb http://mirrors.ustc.edu.cn/Kali-security Kali/updates main contrib non-free
#163Kali源
deb http://mirrors.163.com/debian wheezy main non-free contrib
deb-src http://mirrors.163.com/debian wheezy main non-free contrib
deb http://mirrors.163.com/debian wheezy-proposed-updates main non-free contrib
deb-src http://mirrors.163.com/debian wheezy-proposed-updates main non-free contrib
deb-src http://mirrors.163.com/debian-security wheezy/updates main non-free contrib
deb http://mirrors.163.com/debian-security wheezy/updates main non-free contrib
#浙江大学Kali源
deb http://mirrors.zju.edu.cn/Kali Kali-rolling main contrib non-free
deb-src http://mirrors.zju.edu.cn/Kali Kali-rolling main contrib non-free
#东软大学Kali源
deb http://mirrors.neusoft.edu.cn/Kali Kali-rolling/main non-free contrib
deb-src http://mirrors.neusoft.edu.cn/Kali Kali-rolling/main non-free contrib
#重庆大学Kali源
deb http://http.Kali.org/Kali Kali-rolling main non-free contrib
deb-src http://http.Kali.org/Kali Kali-rolling main non-free contrib
#清华大学 [更新源]
deb http://mirrors.tuna.tsinghua.edu.cn/kali kali-rolling main contrib non-free
deb-src https://mirrors.tuna.tsinghua.edu.cn/kali kali-rolling main contrib non-free
3.apt-get update&&apt-get upgrade&&apt-get autoclean
如果出现数字签名无效的情况,就下载签名
wget archive.kali.org/archive-key.asc //下载签名
apt-key add archive-key.asc //安装签名
三、kali安装软件(安装好上面的更新源才能安装软件)
1.apt-get install open-vm-tools-desktop(替代vmTools,若自带的vmtools不管用时,安装这个)
2.reboot 重启
标签:non,http,kali,Linux,contrib,Kali,源及,deb,main 来源: https://www.cnblogs.com/yankaohaitaiwei/p/11524427.html