虚拟机IP为什么会变?
备份官方yum源配置文件
官方yum源配置文件在:
/etc/yum.repos.d/CentOS-Base.repo
里面的内容:
cat /etc/yum.repos.d/CentOS-Base.repo
备份命令:
cp /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.bak
下载阿里云源配置,覆盖原文件
命令:
curl -o /etc/yum.repos.d/CentOS-Base.repo http://mirrors.aliyun.com/repo/Centos-7.repo
再次查看内容:
cat /etc/yum.repos.d/CentOS-Base.repo
CentOS网络配置文件
输入命令(复制以后在终端里面Shift+Insert粘贴):
cd /etc/sysconfig/network-scripts/ifcfg-ens33
按回车打开配置文件。
重启网络
网络配置文件修改以后需要重启网络才能生效,命令:(重要!每次修改了ens33文件都要重启网络)
service network restart
XSS TargetMachine
on 192.168.23.154
install phpstudy
请用浏览器访问面板:
外网:http://119.3.119.253:9080/2C5022
内网:http://192.168.23.154:9080/2C5022
系统初始账号:admin
系统初始密码:xO65Kmys8u
官网:https://www.xp.cn
如果使用的是云服务器,请至安全组开放9080端口
如果使用ftp,请开放21以及30000-30050端口
cd /www/admin/localhost_80/wwwroot
http://192.168.23.154:80/DVWA/setup.php
username: admin
password: password
pikachu
开始攻击
xsser -u "http://192.168.23.154/DVWA/vulnerabilities/" -g "xss_r/?name=XSS" --cookie="PHPSESSID=26fff236515ad941079dbf9d; security=low" -s -v --reverse-check
https://installati.one/install-python3-selenium-kalilinux/
Install python3-selenium Using apt-get
Update apt database with apt-get using the following command.
sudo apt-get update
After updating apt database, We can install python3-selenium using apt-get by running the following command:
sudo apt-get -y install python3-selenium
最终执行成功
XSStriker
python3 xsstrike.py -u "http://192.168.23.154/pikachu/vul/xss/xss_reflected_get.php?message=1&submit=submit"