CVE-2025-43858
C# vulnerability analysis and mitigation

Overview

CVE-2025-43858 affects YoutubeDLSharp, a wrapper for the command-line video downloaders youtube-dl and yt-dlp. The vulnerability exists in versions from 1.0.0-beta4 to versions prior to 1.1.2, where an unsafe conversion of arguments allows injection of malicious commands when starting yt-dlp from a commands prompt on Windows OS. The issue was discovered and disclosed on April 24, 2025 (GitHub Advisory).

Technical details

The vulnerability stems from the UseWindowsEncodingWorkaround feature, which is enabled by default. When this feature is active, the application uses a command prompt to run yt-dlp instead of calling it directly, and fails to properly sanitize user-provided arguments. The vulnerability has been assigned a CVSS v3.1 base score of 9.2 (CRITICAL) with vector string CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:C/C:H/I:H/A:L. The issue is classified under CWE-77 (Command Injection) and CWE-78 (OS Command Injection) (NVD).

Impact

The vulnerability allows attackers to execute arbitrary commands on the Windows system where the application is running. The impact is particularly severe in contexts where the library is used in network-facing applications, such as ASP.NET applications accepting inputs from the internet. The vulnerability affects confidentiality and integrity at a high level, with low impact on availability (GitHub Advisory).

Mitigation and workarounds

The vulnerability has been patched in version 1.1.2, which completely removes the UseWindowsEncodingWorkaround property. For users unable to upgrade immediately, temporary workarounds include disabling UseWindowsEncodingWorkaround when using YoutubeDLProcess directly (though this loses Unicode character support), or implementing URL sanitization using Uri.TryCreate for URL inputs (GitHub Advisory).

Additional resources


SourceThis report was generated using AI

Related C# vulnerabilities:

CVE ID

Severity

Score

Technologies

Component name

CISA KEV exploit

Has fix

Published date

CVE-2025-64095CRITICAL9.8
  • C#C#
  • cpe:2.3:a:dotnetnuke:dotnetnuke
NoYesOct 28, 2025
CVE-2025-64113CRITICAL9.3
  • C#C#
  • MediaBrowser.Server.Core
NoYesDec 08, 2025
CVE-2025-66631HIGH7.2
  • C#C#
  • Csla
NoYesDec 09, 2025
CVE-2025-66625MEDIUM4.9
  • C#C#
  • Umbraco.Cms
NoYesDec 09, 2025
CVE-2025-65955MEDIUM4.9
  • C#C#
  • Magick.NET-Q16-HDRI-arm64
NoYesDec 02, 2025

Free Vulnerability Assessment

Benchmark your Cloud Security Posture

Evaluate your cloud security practices across 9 security domains to benchmark your risk level and identify gaps in your defenses.

Request assessment

Get a personalized demo

Ready to see Wiz in action?

"Best User Experience I have ever seen, provides full visibility to cloud workloads."
David EstlickCISO
"Wiz provides a single pane of glass to see what is going on in our cloud environments."
Adam FletcherChief Security Officer
"We know that if Wiz identifies something as critical, it actually is."
Greg PoniatowskiHead of Threat and Vulnerability Management