{"schemaVersion":1,"url":"https://cve.openhack.com/cve/CVE-2026-61788","id":"CVE-2026-61788","title":"@bytebase/dbhub's read-only mode does not prevent database writes","description":"DBHub is a database MCP server for Postgres, MySQL, SQL Server, Oracle, MariaDB, SQLite. Prior to version 0.22.6, setting `readonly = true` on the `execute_sql` tool does not make the connection read-only. The connectors are written to set PostgreSQL `default_transaction_read_only=on` (and open SQLite in `readOnly` mode), but that code is gated on a config value that is never populated, so it neve","descriptionLong":"DBHub is a database MCP server for Postgres, MySQL, SQL Server, Oracle, MariaDB, SQLite. Prior to version 0.22.6, setting `readonly = true` on the `execute_sql` tool does not make the connection read-only. The connectors are written to set PostgreSQL `default_transaction_read_only=on` (and open SQLite in `readOnly` mode), but that code is gated on a config value that is never populated, so it never runs. The only thing left enforcing read-only is a classifier that inspects the first keyword of each statement. Any `SELECT` that writes or has side effects through a function call passes it. With an ordinary role this allows sequence tampering; with a privileged role it allows writing arbitrary files on the server (`lo_export`), reading arbitrary host files (`pg_read_file`), and remote code execution (`dblink` + `COPY ... TO PROGRAM`). The HTTP transport is unauthenticated and binds to `0.0.0.0` by default, so this is reachable by any network caller of `/mcp`. Version 0.22.6 patches the issue.","published":"2026-09-24T17:37:40.409Z","updated":"2026-10-28T02:30:36.943849224Z","reserved":"2026-07-10T20:06:05.616Z","status":"Deferred","rejected":false,"assigner":"GitHub_M","metric":{"version":"3.1","score":7.4,"vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:N","rating":"high","source":"GitHub_M"},"metrics":[{"version":"3.1","score":7.4,"vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:N","rating":"high","source":"GitHub_M"},{"version":"3.1","score":7.4,"vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:N","rating":"high","source":"github.com"},{"version":"3.1","score":7.4,"vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:N","rating":"high","source":"OSV"},{"version":"3.1","score":7.4,"vector":"CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:N","rating":"high","source":"GitHub"}],"rating":"high","products":["bytebase dbhub"],"affectedProducts":[{"vendor":"bytebase","product":"dbhub","defaultStatus":null,"versions":[{"version":"< 0.22.6","status":"affected"}],"platforms":[]}],"packages":[{"ecosystem":"npm","name":"@bytebase/dbhub","purl":"pkg:npm/%40bytebase/dbhub","ranges":["<0.22.6"],"fixed":["0.22.6"],"advisory":"GHSA-mwwr-p57h-56pf"}],"cwes":["CWE-184","CWE-636","CWE-863"],"aliases":["GHSA-mwwr-p57h-56pf"],"references":[{"url":"https://github.com/bytebase/dbhub/security/advisories/GHSA-mwwr-p57h-56pf","tags":["x_refsource_CONFIRM","exploit","advisory","web"]},{"url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/61xxx/CVE-2026-61788.json","tags":["advisory"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-61788","tags":["advisory"]},{"url":"https://github.com/bytebase/dbhub/pull/342","tags":["web"]},{"url":"https://github.com/bytebase/dbhub/commit/872bb338f7d31f6afe517a076ac3e3edafaaaf08","tags":["web"]},{"url":"https://github.com/bytebase/dbhub","tags":["package"]},{"url":"https://github.com/bytebase/dbhub/releases/tag/v0.22.6","tags":["web"]}],"patchReferenced":false,"fixAvailable":true,"exploitReferenced":true,"kev":false,"kevAdded":null,"kevDue":null,"kevEntry":null,"ssvc":{"exploitation":"poc","automatable":"no","technicalImpact":"total"},"epss":0.004,"epssPercentile":0.3498,"sources":[{"name":"CVE List","url":"https://www.cve.org/CVERecord?id=CVE-2026-61788","ok":true},{"name":"NVD","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-61788","ok":true,"note":"Deferred"},{"name":"OSV","url":"https://osv.dev/vulnerability/CVE-2026-61788","ok":true,"note":"1 package"},{"name":"GitHub Advisory","url":"https://github.com/advisories/GHSA-mwwr-p57h-56pf","ok":true,"note":"GHSA-mwwr-p57h-56pf"},{"name":"CISA KEV","url":"https://www.cisa.gov/known-exploited-vulnerabilities-catalog","ok":true,"note":"not listed"},{"name":"EPSS","url":"https://api.first.org/data/v1/epss?cve=CVE-2026-61788","ok":true,"note":"scored 2026-11-19"}],"aiTitle":false,"tech":[],"critical":[],"attention":null}