elunez / eladmin

eladmin jpa 版本:项目基于 Spring Boot 2.6.4、 Jpa、 Spring Security、Redis、Vue的前后端分离的后台管理系统,项目采用分模块开发方式, 权限控制采用 RBAC,支持数据字典与数据权限管理,支持一键生成前后端代码,支持动态路由
https://eladmin.vip/demo
Apache License 2.0
21.19k stars 7.34k forks source link

There an Server-side request forgery vulnerability #852

Open LockeTom opened 1 month ago

LockeTom commented 1 month ago

Description Eladmin v2.7 has an Server-side request forgery vulnerability in the Server management.

When an attacker adds a server, an attacker can construct an arbitrary IP address and initiate a test connection request for the IP address on the frontend, and the server will initiate a connection request for the IP address.

Vulnerable code

eladmin-system/src/main/java/me/zhengjie/modules/mnt/rest/ServerDeployController.java

image

Step 1

Add data to the frontend and initiate a test connection

image

Step 2 We use burp to capture packets and change the IP address to DNSlog

image

Step 3 Let's look at the dnglog record,We can see that the server has initiated a connection test request for the IP

image

Versions eladmin ≤ v2.7

Reporter https://github.com/LockeTom

KentKong666 commented 3 weeks ago

This should be controlled when there is a permission-access limit. The PreAuthorize attribute can prevent the attack behavior. Anyway, this is good catch.