{"id":"CVE-2026-40520","aliases":["CVE-2026-40520"],"related":[],"kind":"vulnerability","state":"published","title":"FreePBX api module Command Injection via GraphQL","summary":"FreePBX api module version 17.0.8 and prior contain a command injection vulnerability in the initiateGqlAPIProcess() function where GraphQL mutation input fields are passed directly to shell_exec() without sanitization or escaping. An authenticated user with a valid bearer token can send a GraphQL moduleOperations mutation with backtick-wrapped commands in the module field to execute arbitrary commands on the underlying host as the web server user.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"FreePBX api module version 17.0.8 and prior contain a command injection vulnerability in the initiateGqlAPIProcess() function where GraphQL mutation input fields are passed directly to shell_exec() without sanitization or escaping. An authenticated user with a valid bearer token can send a GraphQL moduleOperations mutation with backtick-wrapped commands in the module field to execute arbitrary commands on the underlying host as the web server user.","source":"cvelist"},{"lang":"es","text":"El módulo API de FreePBX versión 17.0.8 y anteriores contienen una vulnerabilidad de inyección de comandos en la función initiateGqlAPIProcess() donde los campos de entrada de mutación de GraphQL se pasan directamente a shell_exec() sin saneamiento ni escape. Un usuario autenticado con un token de portador válido puede enviar una mutación GraphQL moduleOperations con comandos envueltos en comillas invertidas en el campo module para ejecutar comandos arbitrarios en el host subyacente como el usuario del servidor web.","source":"nvd"}],"published":"2026-04-21T12:41:05.281Z","modified":"2026-10-26T21:10:00.170Z","severity":{"scorer":"VulnCheck","scheme":"CVSS:4.0","vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:H/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N","score":8.6,"rating":"HIGH"},"severities":[{"scorer":"VulnCheck","scheme":"CVSS:4.0","vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:H/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N","score":8.6,"rating":"HIGH"},{"scorer":"VulnCheck","scheme":"CVSS:3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:H/A:H","score":7.2,"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"}],"cwes":["CWE-78"],"affected":[{"ranges":[{"type":"semver","introduced":"0","lastAffected":"17.0.8","status":"affected"},{"type":"git","version":"5f194e39a47e5481e8947f9694304d32724175f6","status":"unaffected"}],"vendor":"FreePBX","product":"api","repo":"https://github.com/FreePBX/api","source":"cvelist"},{"ranges":[{"status":"affected","fixed":"17.0.8"}],"vendor":"freepbx","product":"api","cpe":"cpe:2.3:a:freepbx:api:*:*:*:*:*:*:*:*","source":"nvd"}],"references":[{"url":"https://github.com/FreePBX/api/commit/5f194e39a47e5481e8947f9694304d32724175f6","tags":["patch"],"sources":["cvelist","nvd"]},{"url":"https://github.com/FreePBX/api/blob/5f194e39a47e5481e8947f9694304d32724175f6/Api.class.php#L546C1-L554C3","tags":["product","related"],"sources":["cvelist","nvd"]},{"url":"https://github.com/FreePBX/api/blob/5f194e39a47e5481e8947f9694304d32724175f6/ApiGqlHelper.class.php#L34C1-L36C136","tags":["product","related"],"sources":["cvelist","nvd"]},{"url":"https://www.vulncheck.com/advisories/freepbx-api-module-command-injection-via-graphql","tags":["third-party-advisory"],"sources":["cvelist","nvd"]}],"credits":["M. Cory Billington of theyhack.me"],"assigner":"VulnCheck","ssvc":{"scorer":"CISA-ADP","exploitation":"none","automatable":"no","technicalImpact":"total","date":"2026-04-21T13:31:32.268Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2026-40520","url":"https://www.cve.org/CVERecord?id=CVE-2026-40520","licence":"CVE Terms of Use","modified":"2026-09-24T14:17:37.983Z"},{"source":"nvd","name":"NVD","id":"CVE-2026-40520","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-40520","licence":"Public domain","modified":"2026-10-26T21:10:00.170Z"}],"updatedAt":"2026-11-25T22:59:19.091Z","epss":{"score":0.02518,"percentile":0.8558,"date":"2026-11-30T12:00:22.000Z"}}