WordPress.org

Make WordPress Core

Changeset 40467


Ignore:
Timestamp:
04/17/2017 01:30:35 PM (3 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.0 branch.

Location:
branches/4.0
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/4.0

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

    r40156 r40467  
    28622862            foreach ( $data[$version]['comments'] as $key => $list ) {
    28632863                if ( ! empty( $list ) ) {
    2864                     $metadata[$key] = reset( $list );
     2864                    $metadata[$key] = wp_kses_post( reset( $list ) );
    28652865                    // Fix bug in byte stream analysis.
    28662866                    if ( 'terms_of_use' === $key && 0 === strpos( $metadata[$key], 'yright notice.' ) )
     
    29462946    wp_add_id3_tag_data( $metadata, $data );
    29472947
    2948     $metadata = wp_kses_post_deep( $metadata );
    2949 
    29502948    return $metadata;
    29512949}
     
    29872985    wp_add_id3_tag_data( $metadata, $data );
    29882986
    2989     $metadata = wp_kses_post_deep( $metadata );
    2990 
    29912987    return $metadata;
    29922988}
Note: See TracChangeset for help on using the changeset viewer.