[wp-trac] [WordPress Trac] #30377: wp_check_filetype is broken when checking urls with parameters
WordPress Trac
noreply at wordpress.org
Wed Oct 13 10:55:32 UTC 2021
#30377: wp_check_filetype is broken when checking urls with parameters
------------------------------------+-----------------------------
Reporter: supercleanse | Owner: johnbillion
Type: enhancement | Status: reviewing
Priority: normal | Milestone: Future Release
Component: Media | Version: 4.0
Severity: normal | Resolution:
Keywords: has-patch dev-feedback | Focuses:
------------------------------------+-----------------------------
Changes (by johnbillion):
* keywords: needs-testing has-patch => has-patch dev-feedback
* type: defect (bug) => enhancement
Comment:
[attachment:"30377.5.diff"] refreshes the patch and adds more tests,
particularly ones which include URLs and paths which attempt to subvert
the extension detection.
One test fails: `http://example.mp3` incorrectly results in an extension
of `mp3`, but this isn't strictly related to this change and AFAIK none of
the extensions in `wp_get_mime_types()` are valid TLDs anyway.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/30377#comment:44>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list