当前位置:网站首页>Shanda Wangan shooting range experimental platform project - personal record (V)
Shanda Wangan shooting range experimental platform project - personal record (V)
2022-04-23 19:29:00 【Chen Song】
The address of the column of the series of articles :
Shandong University Network Security shooting range experimental platform
The content of this issue :
- The jump of the shooting range plate
- Turn on the target
One 、 Introduction to the shooting range at this stage
The current project , We made several target environments , such as sql Inject , however Not deployed to docker in
So our target page also has a front end views Under the folder , Sure url visit , It is planned to realize this form of shooting range first , In a few weeks, we will deploy to docker, This is the final version , Can be accessed and attacked by multiple users , Open and destroy the container to prevent the server from being damaged .
Two 、 Page design
1. Shooting range plate
Click on the title SQL-Char Enter the title details page
The main content of the page is placed in a card in :
<!-- card -->
<div>
<el-card style="width: 80%;height:65vh; margin: 150px; margin-top:110px; background-color: #0B1746;border-color: #1E90FF">
<h1 style="color: white;">{
{probleminfo.problemname}}</h1>
<div style="text-align: left;">
<h3 style="display:inline-block; color: white;"> The difficulty coefficient :</h3>
<el-rate style="display:inline-block;" v-model="probleminfo.problemratio" disabled/>
</div>
<div style="text-align: left;">
<h3 style="color: white;display:inline-block;"> Title Description :</h3>
<p style="display:inline-block;color: #DCDCDC">{
{probleminfo.problemcontent}}</p>
</div>
<div style="text-align: left;height:150px;margin-top: 20px;">
<el-button style="background-color: #0B1746;color: white;width: 200px" @click="dialogVisible=true">
<h3> Click to get the target scene </h3>
</el-button>
</div>
<div style="">
<el-input v-model="input" placeholder="flag{}" style="width:60%;display:block;margin-left: 20%" clearable />
<el-button style="width: 100px;margin-top: 20px" type="primary" :icon="Edit" circle> Submit </el-button>
</div>
</el-card>
</div>
Then there's a back button on top
<div style="float: left;margin:30px; margin-left: 150px">
<el-button style="background-color: #0B1746;color: white;" @click="goback"> return </el-button>
</div>
our Click to get the shooting range scene
The button needs to be bound with an event , Open a pop-up window
Let's write the pop-up window first :
<el-dialog v-model="dialogVisible" width="300px">
<!-- v-loading="loading"-->
<h @click="gotopage" style="cursor: pointer;">https://xxx.xx.xx.x</h>
</el-dialog>
The effect is as follows : Pop up a small window , It shows an address , The user clicks to enter the target environment to do questions
3、 ... and 、 Function realization
3.1、 Jump route with parameters
We need to take the title content from the database , Title (problemcontent,problemname). The problem is how to know the subject id( Primary key )
We need to implement the title of the first page id To the second page , Then use this id Go find all the information . So we must implement jump route with parameters .
1. Click trigger method gotopro
2. Jump route with parameters is in router.push Add a query Parameters , Pass on .
gotopro(problemid){
this.$router.push({
path:'/bugpage',query: {
id:problemid}})
},
3. Then the routing effect jumps as follows :
3.2、 Render a new page
Now the new page has received problemid. Then go to the back-end interface /problem/getinfobyid
Check all the information on the subject , Then assign the value to the front-end variable :
getprobleminfo(){
request.get("/problem/getinfobyid",{
params:{
problemid:this.probleminfo.problemid
}
}).then(res =>{
this.probleminfo.problemname=res.data.problemname;
this.probleminfo.problemcontent=res.data.problemcontent;
})
}
The effect is as follows :Name and content It's all loaded out
3.3、 Turn on the target
Our target route is and problemid The associated :
gotopage(){
let href='http://localhost:8080/#'+this.probleminfo.problemid;
window.open(href);
},
such , Click the web link ( Write casually ), You can jump to the target page .
Next time I'll introduce the target plane page
版权声明
本文为[Chen Song]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/04/202204231923279742.html
边栏推荐
- Encyclopedia of professional terms and abbreviations in communication engineering
- Speculation on the way to realize the smooth drag preview of video editing software
- ArcMap connecting ArcGIS Server
- 深度学习环境搭建步骤—gpu
- [报告] Microsoft :Application of deep learning methods in speech enhancement
- LPC1768 关于延时Delay时间与不同等级的优化对比
- OpenHarmony开源开发者成长计划,寻找改变世界的开源新生力!
- MFCC: Mel频率倒谱系数计算感知频率和实际频率转换
- [report] Microsoft: application of deep learning methods in speech enhancement
- 仓库管理数据库系统设计
猜你喜欢
山大网安靶场实验平台项目—个人记录(四)
MySQL syntax collation (2)
First experience of using fluent canvas
Possible root causes include a too low setting for -Xss and illegal cyclic inheritance dependencies
Grafana 分享带可变参数的链接
RuntimeError: Providing a bool or integral fill value without setting the optional `dtype` or `out`
Oracle configuration st_ geometry
MySQL lock
Common SQL commands
山大网安靶场实验平台项目-个人记录(五)
随机推荐
坐标转换WGS-84 转 GCJ-02 和 GCJ-02转WGS-84
2021-2022-2 ACM training team weekly Programming Competition (8) problem solution
优先使用组合而不使用继承
An example of using JNI to directly access surface data
Hot reload debugging
MySQL syntax collation (2)
An idea of rendering pipeline based on FBO
Openlayers 5.0 thermal diagram
[报告] Microsoft :Application of deep learning methods in speech enhancement
对普通bean进行Autowired字段注入
No, some people can't do the National Day avatar applet (you can open the traffic master and earn pocket money)
MySQL syntax collation
命令-sudo
NiO related Basics
Convert string to JSON
ArcMap publishing slicing service
Possible root causes include a too low setting for -Xss and illegal cyclic inheritance dependencies
ArcMap connecting ArcGIS Server
Encyclopedia of professional terms and abbreviations in communication engineering
The most detailed network counting experiment in history (2) -- rip experiment of layer 3 switch