WordPress.org

Make WordPress Core


Ignore:
Timestamp:
12/13/2018 01:29:42 AM (10 months ago)
Author:
peterwilsoncc
Message:

Multisite: Validate activation links.

Merges [44048] to the 5.0 branch.

Location:
branches/5.0
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/5.0

  • branches/5.0/src/wp-admin/includes/class-wp-screen.php

    r43807 r44050  
    279279            switch ( $base ) {
    280280                case 'post' :
    281                     if ( isset( $_GET['post'] ) )
     281                    if ( isset( $_GET['post'] ) && isset( $_POST['post_ID'] ) && (int) $_GET['post'] !== (int) $_POST['post_ID'] )
     282                        wp_die( __( 'A post ID mismatch has been detected.' ), __( 'Sorry, you are not allowed to edit this item.' ), 400 );
     283                    elseif ( isset( $_GET['post'] ) )
    282284                        $post_id = (int) $_GET['post'];
    283285                    elseif ( isset( $_POST['post_ID'] ) )
Note: See TracChangeset for help on using the changeset viewer.