Skip to content

Commit cea9e2d

Browse files
committed
Multisite: Use wp_rand() in signup key creation.
Built from https://develop.svn.wordpress.org/trunk@39795 git-svn-id: http://core.svn.wordpress.org/trunk@39733 1a063a9b-81f0-0310-95a4-ce76da25c4cd
1 parent 061e878 commit cea9e2d

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

Diff for: wp-includes/ms-functions.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -669,7 +669,7 @@ function wpmu_validate_blog_signup( $blogname, $blog_title, $user = '' ) {
669669
function wpmu_signup_blog( $domain, $path, $title, $user, $user_email, $meta = array() ) {
670670
global $wpdb;
671671

672-
$key = substr( md5( time() . rand() . $domain ), 0, 16 );
672+
$key = substr( md5( time() . wp_rand() . $domain ), 0, 16 );
673673
$meta = serialize($meta);
674674

675675
$wpdb->insert( $wpdb->signups, array(
@@ -719,7 +719,7 @@ function wpmu_signup_user( $user, $user_email, $meta = array() ) {
719719
// Format data
720720
$user = preg_replace( '/\s+/', '', sanitize_user( $user, true ) );
721721
$user_email = sanitize_email( $user_email );
722-
$key = substr( md5( time() . rand() . $user_email ), 0, 16 );
722+
$key = substr( md5( time() . wp_rand() . $user_email ), 0, 16 );
723723
$meta = serialize($meta);
724724

725725
$wpdb->insert( $wpdb->signups, array(

Diff for: wp-includes/version.php

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
*
55
* @global string $wp_version
66
*/
7-
$wp_version = '4.8-alpha-39772';
7+
$wp_version = '4.8-alpha-39795';
88

99
/**
1010
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.

0 commit comments

Comments
 (0)