From c4b15e91bfef82f43e344389452c762df7b7f5cc Mon Sep 17 00:00:00 2001 From: Andrew Nacin Date: Wed, 26 Mar 2014 14:38:39 +0000 Subject: [PATCH] Upgrader skins: Strip tags before displaying error data. fixes #25394. git-svn-id: https://develop.svn.wordpress.org/trunk@27737 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/includes/class-wp-upgrader-skins.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/wp-admin/includes/class-wp-upgrader-skins.php b/src/wp-admin/includes/class-wp-upgrader-skins.php index ed6c5e6447..def73abbe6 100644 --- a/src/wp-admin/includes/class-wp-upgrader-skins.php +++ b/src/wp-admin/includes/class-wp-upgrader-skins.php @@ -65,7 +65,7 @@ class WP_Upgrader_Skin { } elseif ( is_wp_error($errors) && $errors->get_error_code() ) { foreach ( $errors->get_error_messages() as $message ) { if ( $errors->get_error_data() && is_string( $errors->get_error_data() ) ) - $this->feedback($message . ' ' . esc_html( $errors->get_error_data() ) ); + $this->feedback($message . ' ' . esc_html( strip_tags( $errors->get_error_data() ) ) ); else $this->feedback($message); } @@ -217,7 +217,7 @@ class Bulk_Upgrader_Skin extends WP_Upgrader_Skin { if ( is_wp_error($error) ) { foreach ( $error->get_error_messages() as $emessage ) { if ( $error->get_error_data() && is_string( $error->get_error_data() ) ) - $messages[] = $emessage . ' ' . esc_html( $error->get_error_data() ); + $messages[] = $emessage . ' ' . esc_html( strip_tags( $error->get_error_data() ) ); else $messages[] = $emessage; }