Make WordPress Core


Ignore:
Timestamp:
12/13/2018 01:55:22 AM (6 years ago)
Author:
peterwilsoncc
Message:

Multisite: Validate activation links.

Merges [44048] 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/screen.php

    r39768 r44069  
    450450            switch ( $base ) {
    451451                case 'post' :
    452                     if ( isset( $_GET['post'] ) )
     452                    if ( isset( $_GET['post'] ) && isset( $_POST['post_ID'] ) && (int) $_GET['post'] !== (int) $_POST['post_ID'] )
     453                        wp_die( __( 'A post ID mismatch has been detected.' ), __( 'Sorry, you are not allowed to edit this item.' ), 400 );
     454                    elseif ( isset( $_GET['post'] ) )
    453455                        $post_id = (int) $_GET['post'];
    454456                    elseif ( isset( $_POST['post_ID'] ) )
Note: See TracChangeset for help on using the changeset viewer.