{"id":"CVE-2024-47879","aliases":["DEBIAN-CVE-2024-47879","EUVD-2024-2917","GHSA-3jm4-c6qf-jrh3","UBUNTU-CVE-2024-47879","USN-7260-1"],"status":"published","title":"OpenRefine's PreviewExpressionCommand, which is eval, lacks protection against cross-site request forgery (CSRF)","description":"OpenRefine is a free, open source tool for working with messy data. Prior to version 3.8.3, lack of cross-site request forgery protection on the `preview-expression` command means that visiting a malicious website could cause an attacker-controlled expression to be executed. The expression can contain arbitrary Clojure or Python code. The attacker must know a valid project ID of a project that contains at least one row, and the attacker must convince the victim to open a malicious webpage. Version 3.8.3 fixes the issue.","severity":{"version":"3.1","score":7.6,"vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:L","level":"high","assessor":"cna","from":"cve"},"epss":{"day":"2026-11-09","score":0.00428,"percentile":0.37293,"model":"v2026.06.15"},"facts":{"in_kev":false,"known_exploited":false,"public_exploit":false,"fix_available":true},"cwes":["CWE-352","CWE-94"],"published":"2024-10-24T17:58:53Z","modified":"2026-11-02T12:02:52Z","fixes":[{"ecosystem":"Maven","package":"org.openrefine:main","fixed_in":["3.8.3"],"sources":["ghsa","osv"]},{"ecosystem":"Debian:13","package":"openrefine","fixed_in":["3.8.7-1"],"sources":["osv"]},{"ecosystem":"Ubuntu:Pro:22.04:LTS","package":"openrefine","fixed_in":["3.5.2-1ubuntu0.1~esm1"],"sources":["osv"]},{"ecosystem":"Ubuntu:Pro:24.04:LTS","package":"openrefine","fixed_in":["3.7.7-1ubuntu0.1~esm1"],"sources":["osv"]}],"affected":[{"source":"ghsa","ecosystem":"Maven","package":"org.openrefine:main","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"3.8.3"}]}]},{"source":"osv","ecosystem":"Debian:12","package":"openrefine","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"}]}],"versions":["3.6.2-2","3.6.2-2+deb12u1","3.6.2-2+deb12u2","3.6.2-2+deb12u3","3.6.2-3","3.7.4-1","3.7.5-1","3.7.6-1","3.7.7-1","3.7.8-1","3.8.7-1","3.8.7-2","3.9.3-1","3.9.5-1","3.9.5-2"]},{"source":"osv","ecosystem":"Debian:13","package":"openrefine","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"3.8.7-1"}]}]},{"source":"osv","ecosystem":"Maven","package":"org.openrefine:main","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"3.8.3"}]}],"versions":["3.6-beta1","3.6-beta2","3.6-rc1","3.6.0","3.6.1","3.6.2","3.7-beta1","3.7-beta2","3.7.0","3.7.2","3.8-beta1","3.8-beta5","3.8.0","3.8.1","3.8.2"]},{"source":"osv","ecosystem":"Ubuntu:Pro:22.04:LTS","package":"openrefine","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"3.5.2-1ubuntu0.1~esm1"}]}],"versions":["3.5.2-1"]},{"source":"osv","ecosystem":"Ubuntu:Pro:24.04:LTS","package":"openrefine","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"3.7.7-1ubuntu0.1~esm1"}]}],"versions":["3.6.2-3","3.7.6-1","3.7.7-1"]},{"source":"osv","ecosystem":"Ubuntu:Pro:22.04:LTS","package":"openrefine","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"3.5.2-1ubuntu0.1~esm1"}]}],"versions":["3.5.2-1"],"bundled":10},{"source":"osv","ecosystem":"Ubuntu:Pro:24.04:LTS","package":"openrefine","ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"3.7.7-1ubuntu0.1~esm1"}]}],"versions":["3.6.2-3","3.7.6-1","3.7.7-1"],"bundled":10}],"products":[{"vendor":"openrefine","product":"openrefine"}],"references":[{"url":"https://github.com/OpenRefine/OpenRefine/security/advisories/GHSA-3jm4-c6qf-jrh3","tags":["x_refsource_CONFIRM","Exploit","Third Party Advisory","advisory","web","report"]},{"url":"https://github.com/OpenRefine/OpenRefine/commit/090924ca923489b6c94397cf1f5df7f7f78f0126","tags":["x_refsource_MISC","Patch","fix","web"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2024-47879","tags":["advisory"]},{"url":"https://github.com/advisories/GHSA-3jm4-c6qf-jrh3"},{"url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2024/47xxx/CVE-2024-47879.json","tags":["advisory"]},{"url":"https://security-tracker.debian.org/tracker/CVE-2024-47879","tags":["advisory"]},{"url":"https://github.com/OpenRefine/OpenRefine","tags":["package"]},{"url":"https://ubuntu.com/security/CVE-2024-47879","tags":["report"]},{"url":"https://www.cve.org/CVERecord?id=CVE-2024-47879","tags":["report"]},{"url":"https://ubuntu.com/security/notices/USN-7260-1","tags":["advisory"]},{"url":"https://ubuntu.com/security/CVE-2023-37476","tags":["report"]},{"url":"https://ubuntu.com/security/CVE-2023-41886","tags":["report"]},{"url":"https://ubuntu.com/security/CVE-2023-41887","tags":["report"]},{"url":"https://ubuntu.com/security/CVE-2024-23833","tags":["report"]},{"url":"https://ubuntu.com/security/CVE-2024-47878","tags":["report"]},{"url":"https://ubuntu.com/security/CVE-2024-47880","tags":["report"]},{"url":"https://ubuntu.com/security/CVE-2024-47881","tags":["report"]},{"url":"https://ubuntu.com/security/CVE-2024-47882","tags":["report"]},{"url":"https://ubuntu.com/security/CVE-2024-49760","tags":["report"]}],"sources":{"cve":[{"id":"CVE-2024-47879","title":"OpenRefine's PreviewExpressionCommand, which is eval, lacks protection against cross-site request forgery (CSRF)","description":"OpenRefine is a free, open source tool for working with messy data. Prior to version 3.8.3, lack of cross-site request forgery protection on the `preview-expression` command means that visiting a malicious website could cause an attacker-controlled expression to be executed. The expression can contain arbitrary Clojure or Python code. The attacker must know a valid project ID of a project that contains at least one row, and the attacker must convince the victim to open a malicious webpage. Version 3.8.3 fixes the issue.","status":"published","published":"2024-10-24T20:17:55.106Z","modified":"2024-10-25T15:24:58.242Z","cvss":[{"version":"3.1","score":7.6,"vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:L","level":"high","assessor":"cna"}],"cwes":["CWE-352","CWE-94"],"updated_at":"2026-11-02T14:33:57.302325Z"}],"euvd":[{"id":"EUVD-2024-2917","description":"OpenRefine is a free, open source tool for working with messy data. Prior to version 3.8.3, lack of cross-site request forgery protection on the `preview-expression` command means that visiting a malicious website could cause an attacker-controlled expression to be executed. The expression can contain arbitrary Clojure or Python code. The attacker must know a valid project ID of a project that contains at least one row, and the attacker must convince the victim to open a malicious webpage. Version 3.8.3 fixes the issue.","status":"published","published":"2024-10-24T20:17:55Z","modified":"2024-10-25T15:24:58Z","cvss":[{"version":"3.1","score":7.6,"vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:L","level":"high"}],"updated_at":"2026-11-03T00:05:18.23832Z"}],"ghsa":[{"id":"GHSA-3jm4-c6qf-jrh3","title":"OpenRefine's PreviewExpressionCommand, which is eval, lacks protection against cross-site request forgery (CSRF)","description":"### Summary\n\nLack of CSRF protection on the `preview-expression` command means that visiting a malicious website could cause an attacker-controlled expression to be executed. The expression can contain arbitrary Clojure or Python code.\n\nThe attacker must know a valid project ID of a project that contains at least one row.\n\n### Details\n\nThe `com.google.refine.commands.expr.PreviewExpressionCommand` class contains the following comment:\n```\n/**\n * The command uses POST but does not actually modify any state so it does not require CSRF.\n */\n```\n\nHowever, this appears to be false (or no longer true). The expression being previewed (executed) can be written in GREL, Python, or Clojure. Since there are no restrictions on what code can be executed, the expression can do anything the user running OpenRefine can do. For instance, the following expressions start a calculator:\n\n```\nclojure:(.exec (Runtime/getRuntime) \"gnome-calculator\")\n```\n\n```\njython:import os;os.system(\"gnome-calculator\")\n```\n\nThe lack of restrictions on expressions is arguably not a problem if the user is typing their own expressions into OpenRefine: they could have just as well typed them into Clojure or Python directly. However, since the `preview-expression` command does not check for a CSRF token, the expression can actually come from a HTML form submitted by a different origin, including arbitrary websites.\n\nIssue #2164 suggested adding CSRF protection to all endpoints, but this endpoint was skipped (and the above comment added) in the associated PR #2182.\n\n### PoC\n\nAn example \"malicious\" page is at https://wandernauta.nl/or/ (of course, actual malicious pages would not wait for the victim to press the submit button).\n\nThe following curl command (substituting the project ID) also demonstrates the issue:\n\n```sh\ncurl -d project=123456789 -d cellIndex=1 -d rowIndices='[0]' -d 'expression=clojure:(.exec (Runtime/getRuntime) \"gnome-calculator\")' http://localhost:3333/command/core/preview-expression/\n```\n\n### Impact\n\nCSRF into remote code execution, provided the attacker knows at least one project ID in the victim's workspace and can convince the victim to open a malicious webpage.","status":"published","published":"2024-10-24T17:58:53Z","modified":"2024-12-04T22:18:03Z","cvss":[{"version":"3.1","score":7.6,"vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:L","level":"high"}],"cwes":["CWE-94","CWE-352"],"updated_at":"2026-11-02T14:38:24.542211Z"}],"nvd":[{"id":"CVE-2024-47879","description":"OpenRefine is a free, open source tool for working with messy data. Prior to version 3.8.3, lack of cross-site request forgery protection on the `preview-expression` command means that visiting a malicious website could cause an attacker-controlled expression to be executed. The expression can contain arbitrary Clojure or Python code. The attacker must know a valid project ID of a project that contains at least one row, and the attacker must convince the victim to open a malicious webpage. Version 3.8.3 fixes the issue.","status":"published","published":"2024-10-24T21:15:12.523Z","modified":"2026-06-17T07:57:54.393Z","cvss":[{"version":"3.1","score":7.6,"vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:L","level":"high","assessor":"secondary"},{"version":"3.1","score":8.8,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H","level":"high","assessor":"primary"}],"cwes":["CWE-94","CWE-352"],"updated_at":"2026-11-02T14:10:34.877798Z"}],"osv":[{"id":"CVE-2024-47879","title":"OpenRefine's PreviewExpressionCommand, which is eval, lacks protection against cross-site request forgery (CSRF)","description":"OpenRefine is a free, open source tool for working with messy data. Prior to version 3.8.3, lack of cross-site request forgery protection on the `preview-expression` command means that visiting a malicious website could cause an attacker-controlled expression to be executed. The expression can contain arbitrary Clojure or Python code. The attacker must know a valid project ID of a project that contains at least one row, and the attacker must convince the victim to open a malicious webpage. Version 3.8.3 fixes the issue.","status":"published","published":"2024-10-24T20:17:55.106Z","modified":"2026-10-28T10:54:31.693614546Z","cvss":[{"version":"3.1","score":7.6,"vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:L","level":"high"}],"cwes":["CWE-352","CWE-94"],"updated_at":"2026-11-02T15:44:43.253252Z"},{"id":"DEBIAN-CVE-2024-47879","description":"OpenRefine is a free, open source tool for working with messy data. Prior to version 3.8.3, lack of cross-site request forgery protection on the `preview-expression` command means that visiting a malicious website could cause an attacker-controlled expression to be executed. The expression can contain arbitrary Clojure or Python code. The attacker must know a valid project ID of a project that contains at least one row, and the attacker must convince the victim to open a malicious webpage. Version 3.8.3 fixes the issue.","status":"published","published":"2024-10-24T21:15:12.523Z","modified":"2026-11-02T12:02:52.488300761Z","cvss":[{"version":"3.1","score":8.8,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H","level":"high"}],"updated_at":"2026-11-02T15:45:43.798789Z"},{"id":"GHSA-3jm4-c6qf-jrh3","title":"OpenRefine's PreviewExpressionCommand, which is eval, lacks protection against cross-site request forgery (CSRF)","description":"### Summary\n\nLack of CSRF protection on the `preview-expression` command means that visiting a malicious website could cause an attacker-controlled expression to be executed. The expression can contain arbitrary Clojure or Python code.\n\nThe attacker must know a valid project ID of a project that contains at least one row.\n\n### Details\n\nThe `com.google.refine.commands.expr.PreviewExpressionCommand` class contains the following comment:\n```\n/**\n * The command uses POST but does not actually modify any state so it does not require CSRF.\n */\n```\n\nHowever, this appears to be false (or no longer true). The expression being previewed (executed) can be written in GREL, Python, or Clojure. Since there are no restrictions on what code can be executed, the expression can do anything the user running OpenRefine can do. For instance, the following expressions start a calculator:\n\n```\nclojure:(.exec (Runtime/getRuntime) \"gnome-calculator\")\n```\n\n```\njython:import os;os.system(\"gnome-calculator\")\n```\n\nThe lack of restrictions on expressions is arguably not a problem if the user is typing their own expressions into OpenRefine: they could have just as well typed them into Clojure or Python directly. However, since the `preview-expression` command does not check for a CSRF token, the expression can actually come from a HTML form submitted by a different origin, including arbitrary websites.\n\nIssue #2164 suggested adding CSRF protection to all endpoints, but this endpoint was skipped (and the above comment added) in the associated PR #2182.\n\n### PoC\n\nAn example \"malicious\" page is at https://wandernauta.nl/or/ (of course, actual malicious pages would not wait for the victim to press the submit button).\n\nThe following curl command (substituting the project ID) also demonstrates the issue:\n\n```sh\ncurl -d project=123456789 -d cellIndex=1 -d rowIndices='[0]' -d 'expression=clojure:(.exec (Runtime/getRuntime) \"gnome-calculator\")' http://localhost:3333/command/core/preview-expression/\n```\n\n### Impact\n\nCSRF into remote code execution, provided the attacker knows at least one project ID in the victim's workspace and can convince the victim to open a malicious webpage.","status":"published","published":"2024-10-24T17:58:53Z","modified":"2024-12-04T22:26:42.883706Z","cvss":[{"version":"3.1","score":7.6,"vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:L","level":"high"}],"cwes":["CWE-352","CWE-94"],"updated_at":"2026-11-02T15:46:35.747385Z"},{"id":"UBUNTU-CVE-2024-47879","description":"OpenRefine is a free, open source tool for working with messy data. Prior to version 3.8.3, lack of cross-site request forgery protection on the `preview-expression` command means that visiting a malicious website could cause an attacker-controlled expression to be executed. The expression can contain arbitrary Clojure or Python code. The attacker must know a valid project ID of a project that contains at least one row, and the attacker must convince the victim to open a malicious webpage. Version 3.8.3 fixes the issue.","status":"published","published":"2024-10-24T21:15:00Z","modified":"2026-02-04T04:31:48.244828Z","cvss":[{"version":"3.1","score":7.6,"vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:U/C:H/I:H/A:L","level":"high"},{"version":"3.1","score":8.8,"vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H","level":"high"}],"updated_at":"2026-11-02T16:55:06.818511Z"},{"id":"USN-7260-1","title":"openrefine vulnerabilities","description":"It was discovered that OpenRefine did not properly handle opening tar\nfiles. If a user or application were tricked into opening a crafted tar\nfile, an attacker could possibly use this issue to execute arbitrary code.\nThis issue only affected Ubuntu 22.04 LTS. (CVE-2023-37476)\n\nIt was discovered that OpenRefine incorrectly handled file permissions and\nuser authentication. An unauthenticated attacker could possibly use this\nissue to leak sensitive information or execute arbitrary code. This issue\nonly affected Ubuntu 22.04 LTS. (CVE-2023-41886, CVE-2023-41887)\n\nIt was discovered that OpenRefine did not properly disallow database\nsettings to be modified when queried. An attacker could possibly use this\nissue to leak sensitive information. This issue only affected\nUbuntu 22.04 LTS and Ubuntu 24.04 LTS. (CVE-2024-23833)\n\nIt was discovered that OpenRefine did not properly sanitize the GET\nparameter for authorized commands, leading to a cross site scripting\nvulnerability. An attacker could possibly use this issue to execute\narbitrary code. (CVE-2024-47878)\n\nIt was discovered that OpenRefine did not properly prevent cross-site\nrequest forgery when running the preview-expression command. If a user or\napplication were tricked into opening a specially crafted webpage, an\nattacker could possibly use this issue to execute arbitrary code.\n(CVE-2024-47879)\n\nIt was discovered that OpenRefine did not properly handle HTTP headers.\nAn attacker could possibly use this issue to execute arbitrary code.\n(CVE-2024-47880)\n\nIt was discovered that OpenRefine incorrectly handled database extensions.\nAn attacker could possibly use this issue to execute arbitrary code.\n(CVE-2024-47881)\n\nIt was discovered that OpenRefine did not properly escape HTML tags in\nexception messages, which could enable code injection. If a user or\napplication were tricked into opening a malicious file, an attacker could\nuse this issue to execute arbitrary code. (CVE-2024-47882)\n\nIt was discovered that OpenRefine did not correctly handle paths when\nexecuting the load-language command. An attacker could possibly use this\nissue to leak sensitive information. (CVE-2024-49760)\n","status":"published","published":"2025-02-10T03:32:44Z","modified":"2026-04-27T17:43:15.654565Z","updated_at":"2026-11-02T16:58:18.876384Z"}]}}
