FILTER_VALIDATE_URL: document some limitations in the validation - #5861
Open
DanielEScherzer wants to merge 4 commits into
Open
DanielEScherzer wants to merge 4 commits into
DanielEScherzer wants to merge 4 commits into
Conversation
jordikroon
approved these changes
Sep 17, 2026
jordikroon
left a comment
Member
There was a problem hiding this comment.
LGTM. Though not related to this change, we should probably split this manual page into sub pages:
- Input Constants
- Generic Filter Flags
- Sanitization Filter Flags
- Validation Filters
- User Defined Filter
Kind of writing this for myself, but if anyone wants to take the job. Feel free.
Member
Author
|
I'll leave this open for a bit before merging in case there are any objections |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This filter accepts a lot of things that might be unexpected, which led to some Mythos reports. While the limited validation isn't a security issue in PHP itself, it is worth calling out for anyone using
FILTER_VALIDATE_URLfor security-sensitive validation in applications.