CVE-2025-24787: Github.com/clidey/whodb/core WhoDB Allows Parameter Injection Vulnerability
HIGHCVE-2025-24787 is a HIGH (CVSS 8.6) whodb allows parameter injection vulnerability (CWE-943: Improper Neutralization of Special Elements in Data Query Logic) affecting Github.com/clidey/whodb/core libraries in the Go ecosystem. The issue involves whodb allows parameter injection in db connection uris leading to local file inclusion. Remediation is available by upgrading affected packages to version 0.0.0-20250127202645-8d67b767e005.
CVE-2025-24787 at a Glance
Security Impact
CVSS: 8.6
The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:N/A:N).
How to Fix CVE-2025-24787
To remediate this vulnerability, upgrade all affected Github.com/clidey/whodb/core dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
Upgrade github.com/clidey/whodb/core to 0.0.0-20250127202645-8d67b767e005
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
inspect dependencies for github.com/clidey/whodb/core
How to Check if You Are Affected
To determine whether your application is affected by CVE-2025-24787, inspect your project dependencies for Github.com/clidey/whodb/core:
inspect dependencies for github.com/clidey/whodb/core
Analyze the terminal output to locate any version of Github.com/clidey/whodb/core in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 0.0.0-20250127202645-8d67b767e005), your application is affected.
Note: Verify declared build manifests and deployed runtime container environments.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-943: Improper Neutralization of Special Elements in Data Query Logic, where the product generates a query intended to access or manipulate data in a data store such as a database, but it does not neutralize or incorrectly neutralizes special elements that can modify the intended logic of the query. In Github.com/clidey/whodb/core, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.
Source Advisory Statement
CVE-2025-24787 Affected Github.com/clidey/whodb/core Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
github.com/clidey/whodb/core
|
Go |
< 0.0.0-20250127202645-8d67b767e005
|
0.0.0-20250127202645-8d67b767e005
|
References
Frequently Asked Questions
What is CVE-2025-24787?
Which Github.com/clidey/whodb/core versions are affected?
What version fixes CVE-2025-24787?
Is github.com/clidey/whodb/core affected?
What is the CVSS score of CVE-2025-24787?
What CWE is associated with CVE-2025-24787?
How can I check Go dependencies for CVE-2025-24787?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-c7w4-9wv8-7x7c",
"modified" : "2025-02-07T17:35:21Z",
"published" : "2025-02-06T19:58:37Z",
"aliases" : [ "CVE-2025-24787" ],
"summary" : "WhoDB allows parameter injection in DB connection URIs leading to local file inclusion",
"details" : "### Summary\n\nThe application is vulnerable to parameter injection in database connection strings, which allows an attacker to read local files on the machine the application is running on.\n\n### Details\n\nThe application uses string concatenation to build database connection URIs which are then passed to corresponding libraries responsible for setting up the database connections.\n\nThis string concatenation is done unsafely and without escaping or encoding the user input. This allows an user, in many cases, to inject arbitrary parameters into the URI string. These parameters can be potentially dangerous depending on the libraries used.\n\nOne of these dangerous parameters is `allowAllFiles` in the library `github.com/go-sql-driver/mysql`. Should this be set to `true`, the library enables running the `LOAD DATA LOCAL INFILE` query on any file on the host machine (in this case, the machine that WhoDB is running on). Source: https://github.com/go-sql-driver/mysql/blob/7403860363ca112af503b4612568c3096fecb466/infile.go#L128\n\nBy injecting `&allowAllFiles=true` into the connection URI and connecting to any MySQL server (such as an attacker-controlled one), the attacker is able to read local files.\n\n### PoC\n\nAs this vulnerability does not require sending requests manually and can all be done using the WhoDB UI, screenshots are provided instead of HTTP requests.\n\nFor this proof-of-concept, a clean instance of WhoDB and MySQL were set up using podman (docker is a suitable alternative):\n\n```\npodman network create whodb-poc\npodman run -d -p 8080:8080 --network whodb-poc docker.io/clidey/whodb\npodman run -d --name mysql -e MYSQL_ROOT_PASSWORD=password --network whodb-poc docker.io/mysql:9\n```\n\nThe attacker connects to the database via WhoDB. Note that in the `Loc` field, the string `&allowAllFiles=true` is inserted:\n\n\n\nAfter connecting, the attacker navigates to the scratchpad in `/scratchpad`.\n\nThe attacker first creates a demo table:\n```sql\nCREATE TABLE poc (\n line TEXT\n);\n```\n\nThe attacker then enables loading files from the server side. For the sake of clarity, do note that while this is required, the file is not being read from the remote server where MySQL is running, but the local machine that WhoDB is running on.\n```sql\nSET GLOBAL local_infile=1;\n```\n\nThe attacker then uses the `LOAD DATA LOCAL INFILE` statement to read the contents of `/etc/passwd` (in this case from inside the container where WhoDB is running) into the previously created table:\n```sql\nLOAD DATA LOCAL INFILE '/etc/passwd'\nINTO TABLE poc\nFIELDS TERMINATED BY '\\0'\nLINES TERMINATED BY '\\n';\n```\n\nThe attacker then navigates to the `poc` table in the _Tables_ view and observes that the file has been read successfully:\n\n\n\n### Impact\n\nWhile this proof-of-concept demonstrates local file inclusion, the root cause of the issue is the unsafe construction of database connection URIs from user input. Not all database connector libraries used in WhoDB were inspected; there may be libraries which allow for even more impactful parameters.\n\nThe attack requires no user authentication to WhoDB (only authentication to any database server, such as an attacker-controlled one) and no special configuration - the default configuration of the application is vulnerable.",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:H/I:N/A:N"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "Go",
"name" : "github.com/clidey/whodb/core"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "0.0.0-20250127202645-8d67b767e005"
} ]
} ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/clidey/whodb/security/advisories/GHSA-c7w4-9wv8-7x7c"
}, {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2025-24787"
}, {
"type" : "WEB",
"url" : "https://github.com/clidey/whodb/commit/8d67b767e00552e5eba2b1537179b74bfa662ee1"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/clidey/whodb"
}, {
"type" : "WEB",
"url" : "https://github.com/go-sql-driver/mysql/blob/7403860363ca112af503b4612568c3096fecb466/infile.go#L128"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-943" ],
"severity" : "HIGH",
"github_reviewed" : true,
"github_reviewed_at" : "2025-02-06T19:58:37Z",
"nvd_published_at" : "2025-02-06T19:15:20Z"
}
}