{"answers":{"affected":"6 open source packages ship an affected version, including org.geotools.jdbc:gt-jdbc-postgis.","exploited":"It is not confirmed as exploited in the wild, but public exploit code for CVE-2026-76904 exists.","fix":"Upgrade org.geotools.jdbc:gt-jdbc-postgis to a fixed version for your release line: 33.6, 34.5 or 35.1.","what":"CVE-2026-76904 is a critical SQL injection vulnerability in geotools, published on 21 Aug 2026. An attacker can exploit it over the internet without logging in, with no action from the victim."},"fix_prompt":"Check this codebase for CVE-2026-76904 and fix it if it is affected.\n\nWhat it is: CVE-2026-76904 is a critical SQL injection vulnerability in geotools, published on 21 Aug 2026. An attacker can exploit it over the internet without logging in, with no action from the victim.\nExploitation: It is not confirmed as exploited in the wild, but public exploit code for CVE-2026-76904 exists.\n\nAffected packages and fixed versions:\n- org.geotools.jdbc:gt-jdbc-postgis (Maven): affected from 30.5; fixed in 33.6\n- org.geotools.jdbc:gt-jdbc-postgis (Maven): affected from 30.5; fixed in 33.6\n- org.geotools.jdbc:gt-jdbc-postgis (Maven): affected from 34.0; fixed in 34.5\n- org.geotools.jdbc:gt-jdbc-postgis (Maven): affected from 34.0; fixed in 34.5\n- org.geotools.jdbc:gt-jdbc-postgis (Maven): affected from 35.0; fixed in 35.1\n- org.geotools.jdbc:gt-jdbc-postgis (Maven): affected from 35.0; fixed in 35.1\n\nTask:\n1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.\n2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.\n3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.\n4. Run the tests and summarise what changed and why.\n5. If nothing in the project is affected, say so and change nothing.\n\nReference: https://insights.sbomify.com/CVE-2026-76904/ (Markdown: https://insights.sbomify.com/CVE-2026-76904/index.md)","id":"CVE-2026-76904","markdown":"https://insights.sbomify.com/CVE-2026-76904/index.md","name":"CVE-2026-76904","record":{"aliases":["GHSA-mqjf-5f49-2fjh"],"analysis":{"component_type":"library","fix_type":"upgrade","impacts":["data_read","data_modify"],"network_reachable":"yes","non_default_config":true,"product_category":"Java geospatial library","requires_auth":"none","summary":"Attackers can execute arbitrary SQL commands via unauthenticated OGC filters in GeoTools when using PostGIS layers with specific JSON fields.","user_interaction":"not_required","vuln_class":"sql_injection"},"analysis_generated_by":"qwen3.8-flash-next","assigner":"GitHub_M","cpe":[],"cvss":{"score":9.8,"severity":"critical","source":"cna","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H","version":"3.1"},"cwes":[{"id":"CWE-89","name":"Improper Neutralization of Special Elements used in an SQL Command"}],"description":"GeoTools is an open source Java library that provides tools for geospatial data. Starting in version 30.5 and prior to versions 33.6, 34.5, and 33.6, an SQL Injection Vulnerability is present when executing OGC Filters with PostGIS DataStore implementation: `jsonArrayContains` function; Requires PostGIS 12 or greater with a String or JSON field. For PostGIS 12 and greater `jsonArrayContains(\u003ccolumn\u003e, \u003cpointer\u003e, \u003cvalue\u003e)` function writes `\u003cvalue\u003e` into generated SQL without escaping. Patches are available in versions 33.6, 34.5, and 33.6. No known workaround is available. To limit scope of SQL Injection the PostGIS connection pool should be configured with limited rights.","ecosystems":["Maven"],"exploits":{"exploitdb":0,"first_seen":"2026-08-16","github_poc":2,"max_poc_stars":5,"metasploit":0,"nuclei":1,"refs":[{"date":"2026-08-16T08:11:26Z","kind":"github_poc","ref":"https://github.com/YonLiud/CVE-2026-76904","stars":5,"title":"One-Day POC | GeoServer Unauthenticated SQL injection to complete RCE"},{"date":"2026-08-26T10:24:28Z","kind":"github_poc","ref":"https://github.com/bickZero93/CVE-2026-76904","stars":1,"title":"PostGIS SQL Injection GeoTools"},{"date":null,"kind":"nuclei","ref":"http/cves/2026/CVE-2026-76904.yaml","stars":null,"title":"GeoServer jsonArrayContains CQL Filter - SQL Injection"}],"tier":"weaponised"},"has_fix":true,"headline":"GeoTools has unauthenticated SQL injection in the jsonArrayContains filter function against PostGIS layers","id":"CVE-2026-76904","indexable":true,"kev":null,"kind":"cve","links":{"ecosystem":"Maven","product":null,"products":[],"type":"sql_injection","year":"2026"},"n_packages":6,"n_references":9,"next":{"headline":"kin-openapi openai3filter: nil-pointer panic in ConvertErrors on malformed multipart/form-data body enables unauthenticated DoS","id":"CVE-2026-76905"},"packages":[{"ecosystem":"Maven","fixed":["33.6"],"introduced":["30.5"],"last_affected":[],"package":"org.geotools.jdbc:gt-jdbc-postgis","purl":null,"source":"GHSA-mqjf-5f49-2fjh"},{"ecosystem":"Maven","fixed":["33.6"],"introduced":["30.5"],"last_affected":[],"package":"org.geotools.jdbc:gt-jdbc-postgis","purl":"pkg:maven/org.geotools.jdbc/gt-jdbc-postgis","source":"GHSA-mqjf-5f49-2fjh"},{"ecosystem":"Maven","fixed":["34.5"],"introduced":["34.0"],"last_affected":[],"package":"org.geotools.jdbc:gt-jdbc-postgis","purl":null,"source":"GHSA-mqjf-5f49-2fjh"},{"ecosystem":"Maven","fixed":["34.5"],"introduced":["34.0"],"last_affected":[],"package":"org.geotools.jdbc:gt-jdbc-postgis","purl":"pkg:maven/org.geotools.jdbc/gt-jdbc-postgis","source":"GHSA-mqjf-5f49-2fjh"},{"ecosystem":"Maven","fixed":["35.1"],"introduced":["35.0"],"last_affected":[],"package":"org.geotools.jdbc:gt-jdbc-postgis","purl":null,"source":"GHSA-mqjf-5f49-2fjh"},{"ecosystem":"Maven","fixed":["35.1"],"introduced":["35.0"],"last_affected":[],"package":"org.geotools.jdbc:gt-jdbc-postgis","purl":"pkg:maven/org.geotools.jdbc/gt-jdbc-postgis","source":"GHSA-mqjf-5f49-2fjh"}],"prev":{"headline":"CordysCRM: Unauthenticated arbitrary file disclosure via `/attachment/preview/{id}` and `/pic/preview/{id}`","id":"CVE-2026-76902"},"products":["geotools"],"published":"2026-08-21","related":[],"sources":[{"class":"attribution","licence":"CVE Terms of Use (MITRE)","name":"CVE List","prefix":"CVE"},{"class":"attribution","licence":"CC BY 4.0","name":"GitHub Advisory Database","prefix":"GHSA"},{"class":"attribution","licence":"CWE Terms of Use","name":"CWE (MITRE)"},{"class":"attribution","licence":"FIRST CVSS licence","name":"CVSS (FIRST)"},{"class":"attribution","licence":"MIT","name":"Nuclei templates"},{"class":"open","licence":"CC0","name":"PoC-in-GitHub"}],"ssvc":{"automatable":"yes","exploitation":"none","technical_impact":"total"},"state":"PUBLISHED","updated":"2026-08-27","vendors":["geotools"]},"summary":"Attackers can execute arbitrary SQL commands via unauthenticated OGC filters in GeoTools when using PostGIS layers with specific JSON fields.","url":"https://insights.sbomify.com/CVE-2026-76904/"}