Query Doctor is a read-only analysis tool. It never applies a rewrite; it reports one.
Open a private security advisory on the GitHub repository (Security → Report a vulnerability), or email the maintainer listed on the GitHub profile. Please do not file a public issue for an exploitable bug. Expect a first reply within a few days.
- Read-only SQL.
src/guard/sqlGuard.tsaccepts one statement and refuses writes, DDL, multiple statements and external paths, for the original and every candidate. The DuckDB sample engine also locks external access. - Credentials are read from the environment or
~/.config/querydoc/*.env, never from the tree..env.examplehas empty values. A gitleaks workflow is defined (.github/workflows/gitleaks.yml) but has not run on GitHub; a local full-history scan found no leaks. - Live-mode API. Binds
127.0.0.1by default; answers only onlocalhost, an IP literal orQUERYDOC_ALLOWED_HOSTSnames (DNS-rebinding guard); cross-origin writes are refused. The Docker image setsHOST=0.0.0.0and runs sample mode. - Dependencies.
npm audit --omit=devreports 0 vulnerabilities at the last release commit.
See FAILURE_MODES.md. The API has no authentication: run live mode on a trusted machine only.