CVE-2025-1131
HighCVSS 7.8Exploitation Probability (EPSS)
Low risk11th percentile - higher than 11% of all known CVEs
Summary
The safe_asterisk script included with the Asterisk toolkit sources all .sh files in /etc/asterisk/startup.d/ as root without validating ownership or permissions. Non-root users with legitimate write access to /etc/asterisk can place malicious scripts in startup.d that execute with root privileges upon service restart.
Risk Assessment
A local attacker can escalate privileges to root, leading to full compromise of the Asterisk host. This particularly affects SysV init and FreePBX environments where the script is commonly used.
Recommendation
Restrict write access to /etc/asterisk and the startup.d directory to root only, and audit startup.d for unauthorized scripts. Consider starting Asterisk without safe_asterisk or update the package to a patched version.
Other vulnerabilities in Asterisk
See all- CVE-2017-17850High
An issue was discovered in Asterisk versions 13.18.4 and older, 14.7.4 and older, 15.1.4 and older, and 13.18-cert1 and older that causes a crash when processing certain SIP messages without a contact header. This issue occurs only when the PJSIP channel driver is used.
- CVE-2017-14603High
In Asterisk 11.x before 11.25.3, 13.x before 13.17.2, and 14.x before 14.6.2, insufficient RTCP packet validation could allow reading stale buffer contents. When combined with the 'nat' and 'symmetric_rtp' options, this could allow redirecting where Asterisk sends the next RTCP report.
- CVE-2026-57203Medium
ast_loggrabber executes a Python script from the world-writable /tmp directory. An attacker already authorized to open a shell session on the Asterisk server may place a malicious script there and gain elevated privileges or execute code when an administrator runs ast_loggrabber with elevated privileges.
- CVE-2026-57199Low
app_sms.c copies externally controlled SMS lengths into fixed in-struct buffers without sufficient bounds checks, allowing an attacker to corrupt memory or crash Asterisk. The SMS dialplan application must be explicitly used and input not validated.
- CVE-2026-57192Medium
An out-of-bounds write in the Codec2 decoder caused by a floor/ceil sample-count mismatch leads to a heap buffer overflow. An authenticated attacker can exploit it by sending crafted Codec2 audio packets within an established call.
- CVE-2026-57191High
An unbounded sscanf in res_pjsip_pubsub when parsing the MWI NOTIFY Message-Account field may allow an unauthenticated attacker to send a crafted packet causing a stack buffer overflow and corrupting the transport, permanently disabling all SIP functionality until restart.
- CVE-2026-57190High
The PostgreSQL and TDS/MSSQL Channel Event Log backends cel_pgsql and cel_tds may permit arbitrary SQL execution when untrusted data is set in the CEL eventtype column by the CELGenUserEvent dialplan application. The backend must be loaded and configured, and CELGenUserEvent must be called without validating input.
- CVE-2026-57186High
The chan_ooh323 Q.931 party-number parser lacks the CVE-2022-37325 fix, which was never forward-ported from Asterisk 20 to later versions. Malformed Q.931 elements in an OOH323 request can crash Asterisk.
- CVE-2026-57200High
In Asterisk prior to 20.20.1, 21.12.3, 22.10.1, 23.4.1 and Certified Asterisk 22.8-cert3, an authenticated attacker with read-only ARI permissions may, under certain conditions, perform write operations via REST-over-WebSocket. The authorization bypass enables arbitrary module path loading and conditional remote code execution.
- CVE-2026-57195High
In Asterisk prior to 20.20.1, 21.12.3, 22.10.1, 23.4.1 and Certified Asterisk 20.7-cert11, 22.8-cert3, a NULL pointer dereference in the Asterisk Manager Interface (AMI) may allow an unauthenticated attacker to crash Asterisk when Digest Authentication is used via HTTP.
Original NVD description (English source)
A local privilege escalation vulnerability exists in the safe_asterisk script included with the Asterisk toolkit package. When Asterisk is started via this script (common in SysV init or FreePBX environments), it sources all .sh files located in /etc/asterisk/startup.d/ as root, without validating ownership or permissions. Non-root users with legitimate write access to /etc/asterisk can exploit this behaviour by placing malicious scripts in the startup.d directory, which will then execute with root privileges upon service restart.
Vulnerability data from NVD (NIST) · CISA KEV · EPSS

