Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

发现几处安全问题 #6

Open
By-Yexing opened this issue Jan 16, 2024 · 0 comments
Open

发现几处安全问题 #6

By-Yexing opened this issue Jan 16, 2024 · 0 comments

Comments

@By-Yexing
Copy link

1.两处文件上传绕过:
由于在代码中采用了黑名单过滤后缀“.jsp”和“.asp”,攻击者可以利用windows自动去除后缀“.”,"::$DATA”等,来进行绕过。如下:
/uploadFileList 接口:
代码分析:
1705369861116
1705369868122
漏洞复现:
1705369825775
1705369840162
/upFile 接口:
代码分析:
1705369915142
1705369918042
1705369921808
1705369924377
漏洞复现:
1705370134198
1705370140909

建议修复方案:采用白名单防御,仅允许上传.txt,.zip,.png,.mp3等常见后缀,禁止上传脚本格式,,如:.html(可导致产生存储型XSS),.jsp,.jspx, .php .asp等,可导致代码执行!!!

2.两处SQL注入,由于采用了"${"的方式进行拼接,所以导致产生SQL注入问题,如下:
漏洞产生位置:
com/rawchen/mapper/ContentMapper.xml:
1705370443868
com/rawchen/mapper/TagMapper.xml:
image
漏洞复现:
1705370513961
image
image
image

建议修复方案:
1705370283022

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant