check for a match against a lowercase host in wp_safe_redirect(). props BoltClock. fixes #5114 for trunk

git-svn-id: https://develop.svn.wordpress.org/trunk@6219 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Mark Jaquith 2007-10-10 19:25:23 +00:00
parent 3df52cab4b
commit 000bbba87b

View File

@ -437,7 +437,7 @@ function wp_safe_redirect($location, $status = 302) {
$allowed_hosts = (array) apply_filters('allowed_redirect_hosts', array($wpp['host']), $lp['host']);
if ( isset($lp['host']) && !in_array($lp['host'], $allowed_hosts) )
if ( isset($lp['host']) && ( !in_array($lp['host'], $allowed_hosts) && $lp['host'] != strtolower($wpp['host'])) )
$location = get_option('siteurl') . '/wp-admin/';
wp_redirect($location, $status);