Make WordPress Core

Changeset 40464


Ignore:
Timestamp:
04/17/2017 01:18:30 PM (7 years ago)
Author:
swissspidy
Message:

Fix broken audio/video functions when sanitizing ID3 data

This fixes a bug where running wp_kses_post_deep() on all the ID3
tag data corrupted blob data.

See #40075, #40085.

Merges [40400] to the 4.3 branch.

Location:
branches/4.3
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/4.3

  • branches/4.3/src/wp-admin/includes/media.php

    r40153 r40464  
    29242924            foreach ( $data[$version]['comments'] as $key => $list ) {
    29252925                if ( 'length' !== $key && ! empty( $list ) ) {
    2926                     $metadata[$key] = reset( $list );
     2926                    $metadata[$key] = wp_kses_post( reset( $list ) );
    29272927                    // Fix bug in byte stream analysis.
    29282928                    if ( 'terms_of_use' === $key && 0 === strpos( $metadata[$key], 'yright notice.' ) )
     
    30083008    wp_add_id3_tag_data( $metadata, $data );
    30093009
    3010     $metadata = wp_kses_post_deep( $metadata );
    3011 
    30123010    return $metadata;
    30133011}
     
    30493047    wp_add_id3_tag_data( $metadata, $data );
    30503048
    3051     $metadata = wp_kses_post_deep( $metadata );
    3052 
    30533049    return $metadata;
    30543050}
Note: See TracChangeset for help on using the changeset viewer.