Skip to content

XDSEC/MiniL-2021-Frontend

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

LCTF2018 前端页面

使用方法:

  1. 安装依赖
npm install
  1. 测试运行
npm run dev
  1. 打包项目
npm run build

注意事项

  1. 项目中存在着开发者大量偷懒暴力写法,望谅解。
  2. 前端路由中设置了白名单验证,部分路由需要凭证方可进入。若需进一步开发请于 ./src/router/index.js 中修改。
  3. 后端地址以及轮询时间间隔请于 ./src/router/index.js 中修改。
  4. team页面中的题目类型统计为写死内容,若于比赛题目类别不相符请于 ./src/page/team.vue 中修改。
  5. 由于不同比赛的宣传页面不同,自定义宣传页面建议提供一个开始按钮导向/login

接口列表

接口url 请求方式 请求参数 响应参数 备注
/get_token GET {token: String} Django需要的CSRF Token。换框架注意删除。
/register POST {
    name: "L-team",
    email: "L-team@email.com",
    password: "L-team",
    school: "L-team"
}
{
    code: 1,
    message: "Register Success!"
}
注册接口
/login POST {
    name: "L-team",
    password: "L-team"
}
{
    code: 1,
    message: "Login Success!",
    team_id: 1
}
登陆接口
/get_all GET {
    "0":{
        avatar: "www.xxx.com/image.jpg",
        done: 1,
        title: "官方公告",
        type: "notice",
        text: [
            'Welcome LCTF 2018',
            'Test Message',
            …
        ]},
{}, {}, …}
请求题目接口
/team/:id GET {
    name: 'L-team',
    rank: 1,
    score: "1000.00",
    solves: [{
        category: 'MISC',
        date: '2018-11-17 09:00:00',
        name: '签到题',
        score: '35.34'}, {}, {}]
}
查询队伍接口
/scoreboard GET [{
    score: '1000.00',
    id: 1,
    name: 'L-team'
}, {}, {}]
查询排行榜接口
/challenge_rank GET [{
    category: 'web',
    name: 'Test_Challenge',
    score: '1000.00'
},{}, {}]
查询题目榜接口
/get_score POST {
    id: 1
}
{
    code: 1,
    score: '1000.00'
}
查询分数接口
/submit POST {
    id: "1",
    flag: "LCTF{}"
}
{
    code: 1,
    message: "Your Flag is correct"
}
提交flag接口

所有POST请求的接口默认返回格式为

{
    //用于标记返回值是否为预料中的值。
    //1为成功请求比如登陆成功注册成功提交flag成功。
    //0,为意料之外的值比如登陆失败注册失败提交flag错误。
    code: 1, 
    
    //作为code的说明
    message: "Text", 
    
    //返回成功后的数据,不一定都叫data,具体看接口文档
    data: [] 
}

About

LCTF 2018 Frontend 魔改

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Vue 86.7%
  • JavaScript 12.3%
  • HTML 1.0%
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy