CVE-2026-47347: Weak Url Blocklist Strpbrk

A weak blocklist (checking only for newlines and null bytes using `strpbrk`) is used to sanitize URLs. This may allow attackers to supply unexpected URI characters (such as backslashes) to bypass downstream domain checks or relative-path validations, potentially causing open redirects. Implement a strict allowlist of valid URI characters instead.

Provally CuratedPublic repositoryMediumMedium confidenceVerifiedApache-2.0PHPβ
greprules fetch cve-2026-47347-weak-url-blocklist-strpbrk --engine opengrep

Description

A weak blocklist (checking only for newlines and null bytes using `strpbrk`) is used to sanitize URLs. This may allow attackers to supply unexpected URI characters (such as backslashes) to bypass downstream domain checks or relative-path validations, potentially causing open redirects. Implement a strict allowlist of valid URI characters instead.