Joke Collection Website - Public benefit messages - How wordpress Modifies Encryption Algorithm
How wordpress Modifies Encryption Algorithm
the process of p>WordPress user password generation is that when it is necessary to generate a user password, a salt is randomly generated, and then salt and password are added, and md5 is performed for count times. Finally, a password starting with $P$ is obtained by adding the hash value of encode64, and the result of this password is different every time. The following is the code for generating WordPress password. Put it in the root directory of WordPress to generate an encrypted password. Replace the user_pass field of wp_users data table with this password to modify the password.
< ? php
$password = 'abc';
global $wp_hasher;
if ( empty($wp_hasher) ) {
require_once( './wp-includes/class-phpass.php');
$wp_hasher = new PasswordHash(8, TRUE);
}
echo $wp_hasher-> HashPassword($password); >
however, there is an easier way to modify the password of a WordPress user, that is, directly change the user_pass field in the wp_users data table to a 32-bit md5(passowrd) to change the password to a password. This password form is of course not very secure, so when this user logs in at WordPress, the system will automatically change the MD5 password to a password beginning with $P$.
WordPress's password supporting simple md5 format makes it easier for users of other systems (such as Ucenter system) to integrate WordPress.
I hope I can help you!
- Related articles
- Uplink and downlink speeds of 3G and 4G mobile phones.
- What if I can't receive the SMS verification code? You will understand after reading it.
- What fire safety should be paid attention to during May Day?
- Don't worry about the yellow code of health code, change it to the green code? Will you inform your family?
- Meizu note2 often can't receive calls from friends, and the mobile phone has no interception settings.
- I have no problem with that. If I find an ambiguous message on my husband's mobile phone, does it mean that my husband is having an affair?
- Interpersonal communication SMS English
- How to prevent online loans from being bombed by address books
- I am a user of China Mobile M-Zone. Can I send short messages with foreign countries? Do you need to open a business in the business hall?
- Which cartoon is this from?