{"id":"CVE-2026-72731","aliases":["BIT-discourse-2026-72731","EUVD-2026-55671","GHSA-wm63-83xp-59r5"],"status":"published","title":"Discourse: Strip SQL comments and use non-recursive parameter interpolation in Data Explorer","description":"Discourse is an open-source discussion platform. From 2026.1.0-latest until 2026.1.7, 2026.6.2, 2026.7.1, and 2026.8.0-latest.1, anyone able to run a parameterized Data Explorer query, including non-staff members of a group a query is shared with, could craft parameter values that escaped the intended query and executed arbitrary SQL through plugins/discourse-data-explorer/lib/discourse_data_explorer/data_explorer.rb and plugins/discourse-data-explorer/lib/discourse_data_explorer/workflows/sql_action/v1.rb. Recursive parameter interpolation allowed one parameter value to introduce another parameter, and parameter declarations in SQL comments could be used to inject a statement. Queries run in a read-only transaction, so data could not be modified, but any table could be read. This issue is fixed in versions 2026.1.7, 2026.6.2, 2026.7.1, and 2026.8.0-latest.1.","severity":{"version":"3.1","score":7.1,"vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:L/A:N","level":"high","assessor":"cna","from":"cve"},"epss":{"day":"2026-11-11","score":0.00402,"percentile":0.34906,"model":"v2026.06.15"},"facts":{"in_kev":false,"known_exploited":false,"public_exploit":false,"fix_available":true},"cwes":["CWE-89"],"published":"2026-08-10T16:25:23Z","modified":"2026-10-28T02:31:03Z","fixes":[{"ecosystem":"Bitnami","package":"discourse","fixed_in":["2026.1.7","2026.6.2","2026.7.1"],"sources":["osv"]}],"affected":[{"source":"osv","ecosystem":"Bitnami","package":"discourse","ranges":[{"type":"SEMVER","events":[{"introduced":"0"},{"fixed":"2026.1.7"},{"introduced":"2026.6.0"},{"fixed":"2026.6.2"},{"introduced":"2026.7.0"},{"fixed":"2026.7.1"}]}]}],"products":[{"vendor":"discourse","product":"discourse"}],"references":[{"url":"https://github.com/discourse/discourse/security/advisories/GHSA-wm63-83xp-59r5","tags":["x_refsource_CONFIRM","web","advisory"]},{"url":"https://github.com/discourse/discourse/commit/2bdab888cef561348470dee204a4879d83fbb5c3","tags":["x_refsource_MISC","web","fix"]},{"url":"https://github.com/discourse/discourse/commit/3dc7f0da7aa18548281152e285244efb1cc8ad0d","tags":["x_refsource_MISC","web","fix"]},{"url":"https://github.com/discourse/discourse/commit/674ba6fc64184fd7d8e21183c5d8cb22367faa6e","tags":["x_refsource_MISC","web","fix"]},{"url":"https://github.com/discourse/discourse/commit/ce9ccf24ec3538172dc8f8199728e08f63e57693","tags":["x_refsource_MISC","web","fix"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2026-72731","tags":["web","advisory"]},{"url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/72xxx/CVE-2026-72731.json","tags":["advisory"]}],"sources":{"cve":[{"id":"CVE-2026-72731","title":"Discourse: Strip SQL comments and use non-recursive parameter interpolation in Data Explorer","description":"Discourse is an open-source discussion platform. From 2026.1.0-latest until 2026.1.7, 2026.6.2, 2026.7.1, and 2026.8.0-latest.1, anyone able to run a parameterized Data Explorer query, including non-staff members of a group a query is shared with, could craft parameter values that escaped the intended query and executed arbitrary SQL through plugins/discourse-data-explorer/lib/discourse_data_explorer/data_explorer.rb and plugins/discourse-data-explorer/lib/discourse_data_explorer/workflows/sql_action/v1.rb. Recursive parameter interpolation allowed one parameter value to introduce another parameter, and parameter declarations in SQL comments could be used to inject a statement. Queries run in a read-only transaction, so data could not be modified, but any table could be read. This issue is fixed in versions 2026.1.7, 2026.6.2, 2026.7.1, and 2026.8.0-latest.1.","status":"published","published":"2026-08-10T16:25:23.882Z","modified":"2026-08-10T16:55:58.556Z","cvss":[{"version":"3.1","score":7.1,"vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:L/A:N","level":"high","assessor":"cna"}],"cwes":["CWE-89"],"updated_at":"2026-11-02T14:19:51.277563Z"}],"euvd":[{"id":"EUVD-2026-55671","description":"Discourse is an open-source discussion platform. From 2026.1.0-latest until 2026.1.7, 2026.6.2, 2026.7.1, and 2026.8.0-latest.1, anyone able to run a parameterized Data Explorer query, including non-staff members of a group a query is shared with, could craft parameter values that escaped the intended query and executed arbitrary SQL through plugins/discourse-data-explorer/lib/discourse_data_explorer/data_explorer.rb and plugins/discourse-data-explorer/lib/discourse_data_explorer/workflows/sql_action/v1.rb. Recursive parameter interpolation allowed one parameter value to introduce another parameter, and parameter declarations in SQL comments could be used to inject a statement. Queries run in a read-only transaction, so data could not be modified, but any table could be read. This issue is fixed in versions 2026.1.7, 2026.6.2, 2026.7.1, and 2026.8.0-latest.1.","status":"published","published":"2026-08-10T16:25:23Z","modified":"2026-08-10T16:55:58Z","cvss":[{"version":"3.1","score":7.1,"vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:L/A:N","level":"high"}],"updated_at":"2026-11-02T18:02:01.941928Z"}],"nvd":[{"id":"CVE-2026-72731","description":"Discourse is an open-source discussion platform. From 2026.1.0-latest until 2026.1.7, 2026.6.2, 2026.7.1, and 2026.8.0-latest.1, anyone able to run a parameterized Data Explorer query, including non-staff members of a group a query is shared with, could craft parameter values that escaped the intended query and executed arbitrary SQL through plugins/discourse-data-explorer/lib/discourse_data_explorer/data_explorer.rb and plugins/discourse-data-explorer/lib/discourse_data_explorer/workflows/sql_action/v1.rb. Recursive parameter interpolation allowed one parameter value to introduce another parameter, and parameter declarations in SQL comments could be used to inject a statement. Queries run in a read-only transaction, so data could not be modified, but any table could be read. This issue is fixed in versions 2026.1.7, 2026.6.2, 2026.7.1, and 2026.8.0-latest.1.","status":"published","published":"2026-08-10T17:17:37.663Z","modified":"2026-09-08T20:54:37.79Z","cvss":[{"version":"3.1","score":7.1,"vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:L/A:N","level":"high","assessor":"secondary"}],"cwes":["CWE-89"],"updated_at":"2026-11-02T14:12:36.102748Z"}],"osv":[{"id":"CVE-2026-72731","title":"Discourse: Strip SQL comments and use non-recursive parameter interpolation in Data Explorer","description":"Discourse is an open-source discussion platform. From 2026.1.0-latest until 2026.1.7, 2026.6.2, 2026.7.1, and 2026.8.0-latest.1, anyone able to run a parameterized Data Explorer query, including non-staff members of a group a query is shared with, could craft parameter values that escaped the intended query and executed arbitrary SQL through plugins/discourse-data-explorer/lib/discourse_data_explorer/data_explorer.rb and plugins/discourse-data-explorer/lib/discourse_data_explorer/workflows/sql_action/v1.rb. Recursive parameter interpolation allowed one parameter value to introduce another parameter, and parameter declarations in SQL comments could be used to inject a statement. Queries run in a read-only transaction, so data could not be modified, but any table could be read. This issue is fixed in versions 2026.1.7, 2026.6.2, 2026.7.1, and 2026.8.0-latest.1.","status":"published","published":"2026-08-10T16:25:23.882Z","modified":"2026-10-28T02:31:03.679255296Z","cvss":[{"version":"3.1","score":7.1,"vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:L/A:N","level":"high"}],"cwes":["CWE-89"],"updated_at":"2026-11-02T15:45:15.88521Z"},{"id":"BIT-discourse-2026-72731","title":"Discourse: Strip SQL comments and use non-recursive parameter interpolation in Data Explorer","description":"Discourse is an open-source discussion platform. From 2026.1.0 until 2026.1.7, 2026.6.2, 2026.7.1, and 2026.8.0, anyone able to run a parameterized Data Explorer query, including non-staff members of a group a query is shared with, could craft parameter values that escaped the intended query and executed arbitrary SQL through plugins/discourse-data-explorer/lib/discourse_data_explorer/data_explorer.rb and plugins/discourse-data-explorer/lib/discourse_data_explorer/workflows/sql_action/v1.rb. Recursive parameter interpolation allowed one parameter value to introduce another parameter, and parameter declarations in SQL comments could be used to inject a statement. Queries run in a read-only transaction, so data could not be modified, but any table could be read. This issue is fixed in versions 2026.1.7, 2026.6.2, 2026.7.1, and 2026.8.0.","status":"published","published":"2026-08-17T05:44:38.149Z","modified":"2026-08-17T08:10:36.591616864Z","updated_at":"2026-11-02T15:28:29.152062Z"}]}}
