[wp-trac] [WordPress Trac] #39883: Code hooking on `image_downsize` can no longer assume the file is an image

WordPress Trac noreply at wordpress.org
Mon May 22 19:59:06 UTC 2017


#39883: Code hooking on `image_downsize` can no longer assume the file is an image
-----------------------------------+------------------------
 Reporter:  stephdau               |       Owner:  joemcgill
     Type:  defect (bug)           |      Status:  assigned
 Priority:  normal                 |   Milestone:  4.8
Component:  Media                  |     Version:  4.7
 Severity:  normal                 |  Resolution:
 Keywords:  has-patch 2nd-opinion  |     Focuses:
-----------------------------------+------------------------

Comment (by azaozz):

 Frankly I don't like the approach in 39883.2.diff. It feels more like a
 temp hack rather than a fix, still leaves a "backdoor" to sneak in PDF
 attachments to be treated as images. For that reason it doesn't fix this
 ticket either.

 Needing to add a filter would only make things worse, with one plugin
 possibly adding another type that is unexpected in another plugin :(

 Think this should be fixed properly, by adding the missing handler
 functions for this case, possibly in #39980.

 This doesn't seem to affect many sites, so perhaps consider punting and
 fixing '''early''' in 4.9?

--
Ticket URL: <https://core.trac.wordpress.org/ticket/39883#comment:26>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list