CVE-2026-41171: Unrestrained Uri Localpath File Access

Unconditionally opening a local file stream from a `Uri` without authorization limits allows attackers to read or include arbitrary local files. Introduce validation checks before using `Uri.LocalPath`.

Provally CuratedPublic repositoryHighMedium confidenceVerifiedApache-2.0C#
greprules fetch cve-2026-41171-unrestrained-uri-localpath-file-access --engine opengrep

Description

Unconditionally opening a local file stream from a `Uri` without authorization limits allows attackers to read or include arbitrary local files. Introduce validation checks before using `Uri.LocalPath`.