title: FILTER_VALIDATE_URL accepts URLs with invalid userinfo
description: In PHP versions 7.3.x below 7.3.26, 7.4.x below 7.4.14 and 8.0.0, when validating URL with functions like filter_var($url, FILTER_VALIDATE_URL), PHP will accept an URL with invalid password as valid URL. This may lead to functions that rely on URL being valid to mis-parse the URL and produce wrong data as components of the URL.
problem types: CWE-20 Improper Input Validation
affected:
{
product: PHP
vendor: PHP Group
versions:
lessThan: 7.3.26, status: affected, version: 7.3.x, versionType: custom
lessThan: 7.4.14, status: affected, version: 7.4.x, versionType: custom
lessThan: 8.0.1, status: affected, version: 8.0.X, versionType: custom
}
metrics:
cvssV3_1: [
attackComplexity: LOW
attackVector: NETWORK
availabilityImpact: NONE
baseScore: 5.3
baseSeverity: MEDIUM
confidentialityImpact: LOW
integrityImpact: NONE
privilegesRequired: NONE
scope: UNCHANGED
userInteraction: NONE
vectorString: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:N/A:N
version: 3.1
]