AWD practice platform construction & virtual machine resources

foreword

Recently, I need to prepare offline AWD, but I don’t have so many gold coins to go to BugKu’s PVP online AWD battle every day to practice, so I thought I could build an AWD offensive and defensive platform for internal use in the team, and record it briefly

basic environment

Ubuntu 20.04, Tsinghua mirror station address
VMware Workstation, official website address
awd-platform, github address

Platform construction

System installation

First, install a new Ubuntu virtual machine according to the instructions, and you can download it from the domestic mirror station. The installation process will not be repeated here. It is best to install a VMTools. After the installation is successful, start the machine. First, use the sudo command to modify the password of the root account and log in. Root account insert image description here
Next, change the source of apt, vim /etc/apt/sources.list, it is best to back up first

# 默认注释了源码镜像以提高 apt update 速度,如有需要可自行取消注释
deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal main restricted universe multiverse
# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal main restricted universe multiverse
deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-updates main restricted universe multiverse
# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-updates main restricted universe multiverse
deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-backports main restricted universe multiverse
# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-backports main restricted universe multiverse
deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-security main restricted universe multiverse
# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-security main restricted universe multiverse

# 预发布软件源,不建议启用
# deb https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-proposed main restricted universe multiverse
# deb-src https://mirrors.tuna.tsinghua.edu.cn/ubuntu/ focal-proposed main restricted universe multiverse

After modifying and saving, update the software package. Of course, you don’t need to upgrade here. You can install it later if you need it.

apt-get update && apt-get upgrade

platform deployment

You can download awd-platform through the git command. You need to install the git command first. If the git download is too slow, you can also download the source code and copy it to the system, and then install python2

apt-get install git
git clone https://gitee.com/jikemofan/awd-platform.git
apt-get install python2

insert image description here
Next, you need to download docker. After changing the source, the speed will be much faster. After installing docker, download the competition docker image

apt install docker.io
docker pull zhl2008/web_14.04
docker tag zhl2008/web_14.04 web_14.04

If the download is too slow here, you can consider docker to change the source, vim /etc/docker/daemon.json, edit the file content as follows

{
  "registry-mirrors": ["https://registry.docker-cn.com","http://hub-mirror.c.163.com"]
}

Remember to restart the docker service after changing the source, service docker restart

environment start

Next, enter the downloaded directory. Here we take the creation of two teams as an example, run the script with python2, first initialize the configuration, and then enable the environment

python2 batch.py web_yunnan_simple 2
python2 start.py ./ 2

insert image description here
Through docker ps, you can check the status of docker enabled, and you can see that web easy has been enabled on ports 8801 and 8802.
insert image description here
If you can’t access it, consider turning off the firewall

Execute the stop_clean.py script to end the game

python2 stop_clean.py

achieve effect


insert image description here
SSH connection in web environment
Save the team ssh connection password in the pass.txt file, the default port of team1 is 2201, and so on
insert image description here
insert image description here

The viewing platform is port 8080, but the button to submit the flag seems to have no effect.
http://10.0.0.197:8080/
It seems that the following url must be passed to submit the flag, emmmmm

http://IP地址:8080/flag_file.php?token=teamx&flag=xxxx

insert image description here

reference

An awd training platform
AWD platform construction and getting started

postscript

It seems that there are still some BUGs in the shooting range, and we will add them later~

Guess you like

Origin blog.csdn.net/monster663/article/details/131035840
AWD
Recommended