# CVE-2021-41158: FreeSWITCH vulnerable to SIP digest leak for configured gateways

> Archived entry. Full-text search covers entries since 2026-11-10; exact IDs work for all years.

- **Severity:** MEDIUM 5.8
- **CVSS:** 5.8 (v3.1, CNA) `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:C/C:L/I:N/A:N`
- **CVSS metrics:** Attack vector: Network; Attack complexity: Low; Privileges required: None; User interaction: None; Scope: Changed (impact reaches other components); Confidentiality impact: Low; Integrity impact: None; Availability impact: None
- **Exploited in the wild:** Not in CISA KEV
- **Public exploit / PoC:** None known
- **Remote exploitation:** Remote, no login needed
- **EPSS:** 0.83% (percentile 55, 2026-11-26)
- **CWE:** CWE-200
- **Published:** 2021-10-26T13:55:10.000Z
- **Modified:** 2026-06-17T04:07:59.573Z

## Who should check

- Anyone running signalwire freeswitch \< 1.10.7

## Description

FreeSWITCH is a Software Defined Telecom Stack enabling the digital transformation from proprietary telecom switches to a software implementation that runs on any commodity hardware. Prior to version 1.10.7, an attacker can perform a SIP digest leak attack against FreeSWITCH and receive the challenge response of a gateway configured on the FreeSWITCH server. This is done by challenging FreeSWITCH's SIP requests with the realm set to that of the gateway, thus forcing FreeSWITCH to respond with the challenge response which is based on the password of that targeted gateway. Abuse of this vulnerability allows attackers to potentially recover gateway passwords by performing a fast offline password cracking attack on the challenge response. The attacker does not require special network privileges, such as the ability to sniff the FreeSWITCH's network traffic, to exploit this issue. Instead, what is required for this attack to work is the ability to cause the victim server to send SIP request messages to the malicious party. Additionally, to exploit this issue, the attacker needs to specify the correct realm which might in some cases be considered secret. However, because many gateways are actually public, this information can easily be retrieved. The vulnerability appears to be due to the code which handles challenges in \`sofia\_reg.c\`, \`sofia\_reg\_handle\_sip\_r\_challenge()\` which does not check if the challenge is originating from the actual gateway. The lack of these checks allows arbitrary UACs (and gateways) to challenge any request sent by FreeSWITCH with the realm of the gateway being targeted. This issue is patched in version 10.10.7. Maintainers recommend that one should create an association between a SIP session for each gateway and its realm to make a check be put into place for this association when responding to challenges.

## Affected and fixed versions

- signalwire freeswitch: \< 1.10.7 (cvelist)

## Mitigation

- Upgrade freeswitch to 1.10.7 or later.

## Check your systems with an agent

Paste this into a coding agent:

```text
Check whether anything I run is affected by CVE-2021-41158. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2021-41158.md
Affected: signalwire freeswitch < 1.10.7
Fixed in: signalwire freeswitch 1.10.7

Steps:
1. Search this machine and project for signalwire freeswitch: dependency manifests and lockfiles, installed packages, container images and running services.
2. For each match, note the installed version and whether it is inside the affected range.
3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
```

## FAQ

### Is CVE-2021-41158 being exploited?

There is no confirmed exploitation: CVE-2021-41158 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.83% chance of exploitation in the next 30 days (as of 2026-11-26).

### How serious is CVE-2021-41158?

Medium: CVSS 5.8 (v3.1, scored by CNA). Remote, no login needed.

### Which versions are affected by CVE-2021-41158?

signalwire freeswitch \< 1.10.7.

### Is there a fix for CVE-2021-41158?

Yes. Fixed in signalwire freeswitch 1.10.7. Upgrade freeswitch to 1.10.7 or later.

### How do I check if I'm affected by CVE-2021-41158?

Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.

## References

- vendor: <https://github.com/signalwire/freeswitch/security/advisories/GHSA-3v3f-99mv-qvj4>
- patch: <http://seclists.org/fulldisclosure/2021/Oct/40>
- other: <https://github.com/signalwire/freeswitch/releases/tag/v1.10.7>

## Attribution

- CVE Program: CVE® is a registered trademark of The MITRE Corporation. CVE records © 1999–2026 The MITRE Corporation. <https://www.cve.org/Legal/TermsOfUse>
- NVD: This product uses data from the NVD API but is not endorsed or certified by the NVD. <https://nvd.nist.gov/vuln/detail/CVE-2021-41158>

HTML: <https://flawdb.com/CVE-2021-41158> · JSON: <https://flawdb.com/api/v1/entries/CVE-2021-41158>
