From 0888e755d74947a1898aa8df65e0a255c857a6fb Mon Sep 17 00:00:00 2001 From: Sergey Biryukov Date: Fri, 3 May 2024 14:32:17 +0000 Subject: [PATCH] Login and Registration: Check that `post_password` is a string in `wp-login.php`. This prevents a fatal error if an array is passed instead. Follow-up to [19925], [34909], [58023]. Props dd32, swissspidy. Fixes #61136. Built from https://develop.svn.wordpress.org/trunk@58093 git-svn-id: http://core.svn.wordpress.org/trunk@57558 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-includes/version.php | 2 +- wp-login.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/wp-includes/version.php b/wp-includes/version.php index 688cc38818..20d8b6e97c 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -16,7 +16,7 @@ * * @global string $wp_version */ -$wp_version = '6.6-alpha-58092'; +$wp_version = '6.6-alpha-58093'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema. diff --git a/wp-login.php b/wp-login.php index bd4568a469..18811aae57 100644 --- a/wp-login.php +++ b/wp-login.php @@ -753,7 +753,7 @@ switch ( $action ) { break; case 'postpass': - if ( ! array_key_exists( 'post_password', $_POST ) ) { + if ( ! isset( $_POST['post_password'] ) || ! is_string( $_POST['post_password'] ) ) { wp_safe_redirect( wp_get_referer() ); exit; }