CVE-2021-41355 — System.DirectoryServices.…
MEDIUMCVE-2021-41355 is a medium-severity (CVSS 5.7) vulnerability in System.DirectoryServices.Protocols. EPSS puts its 30-day exploitation probability at 20.3% (97th percentile). A fix is available for System.DirectoryServices.Protocols — see the affected versions and patch details below.
Credential Disclosure in System.DirectoryServices.Protocols
EPSS Exploitation Probability
Probability of exploitation in the next 30 days, from FIRST.org EPSS.
How urgent is this, really
CVE-2021-41355 by exploitation likelihood (EPSS) against impact (CVSS). Outside the shaded patch-first corner.
Where this sits among everything scored
Of 385,738 CVEs with a current EPSS score, this one falls in the 10–50% band (highlighted). Counts from FIRST.org, log-scaled.
Real-World Exposure
System.DirectoryServices.ProtocolsReal-time download stats are indexed for npm and PyPI packages. This vulnerability affects NuGet packages — download data is not available via public APIs for these ecosystems.
Description
Microsoft is releasing this security advisory to provide information about a vulnerability in .NET. This advisory also provides guidance on what developers can do to update their applications to remove this vulnerability.
A Information Disclosure vulnerability exists in .NET where System.DirectoryServices.Protocols.LdapConnection may send credentials in plain text on Linux.
Patches
Any .NET application that uses System.DirectoryServices.Protocols with a vulnerable version listed below on system based on Linux.
| Package name | Vulnerable versions | Secure versions |
|---|---|---|
| System.DirectoryServices.Protocols | 5.0.0 | 5.0.1 |
Other Details
- Announcement for this issue can be found at dotnet/announcements#202
- An Issue for this can be found at https://github.com/dotnet/runtime/issues/60301
- MSRC details for this can be found at https://msrc.microsoft.com/update-guide/en-US/vulnerability/CVE-2021-41355
Affected Packages
| Ecosystem | Package | Vulnerable range | Fix |
|---|---|---|---|
| .NETNuGet | System.DirectoryServices.Protocols | all versions | 5.0.1dotnet add package System.DirectoryServices.Protocols --version 5.0.1 |
Affected Products
.netmicrosoftpowershellmicrosoftvisual studio 2019microsoftDetection & mitigation playbook
Open-source dependencyDetect
Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for System.DirectoryServices.Protocols, including transitive dependencies — a direct dependency you never call can still pull in a vulnerable version.
Fix
Update System.DirectoryServices.Protocols to 5.0.1 or later, then make sure no transitive (indirect) dependency still pins the vulnerable range — O3 confirms CVE-2021-41355 is resolved across your whole dependency graph.
Workarounds
Assume what was exposed is already known: rotate any credential, token or key that the affected component could return, restrict the endpoint to callers that genuinely need it, and strip sensitive fields from responses and error output at the boundary rather than relying on the client not to read them.
Fixing This On Your OS
If you run this on a Linux distribution, patch through your package manager against the distro's own security advisory below — it tracks the exact backported fix for your release, which can ship on a different timeline (and sometimes a different severity) than the upstream project.
| Product | Fixed in | Advisory |
|---|---|---|
| .NET Core on Red Hat Enterprise Linux | rh-dotnet50-dotnet-0:5.0.208-1.el7_9 | RHSA-2021:3818 |
| Red Hat Enterprise Linux 8 | dotnet5.0-0:5.0.208-1.el8_4 | RHSA-2021:3819 |
Frequently Asked Questions
Is CVE-2021-41355 in your dependencies?
Find it across NuGet, including transitive dependencies.