Skip to content

An SQL injection issue related to the orderBy clause.

High
wanghe-fit2cloud published GHSA-5grx-v727-qmq6 Jul 18, 2024

Package

No package listed

Affected versions

v1.10.9-lts

Patched versions

v1.10.12-tls

Description

Summary

There are many sql injections in the project, and some of them are not well filtered, leading to arbitrary file writes, and ultimately leading to RCEs.
The proof is as follows

Details (one of them )

image image image

PoC

curl 'http://api:30455/api/v1/hosts/command/search' {"page":1,"pageSize":10,"groupID":0,"orderBy":"3","order":"ascending","name":"a"}
image
for example as picture . just change orderby‘s num we can know How many columns does the data table have.Parameters require strict whitelist filtering

Impact

RCE、data leak.

Severity

High

CVE ID

CVE-2024-39907

Weaknesses

Credits