它使用裸cookie并在客户端存储登录状态信息。

+

=
wordpress\\u 7339a175323c25a8547b5a6d26c49afa=您的用户名%7C1457109155%7C170f103ef3dc57cdb1835662d97c1e13;
这些饼干和盐是从哪里来的
盐在wp配置中。php文件:
/**#@+
* Authentication Unique Keys and Salts.
*
* Change these to different unique phrases!
* You can generate these using the {@link https://api.wordpress.org/secret-key/1.1/salt/ WordPress.org secret-key service}
* You can change these at any point in time to invalidate all existing cookies. This will force all users to have to log in again.
*
* @since 2.6.0
*/
define(\'AUTH_KEY\', \'put your unique phrase here\');
define(\'SECURE_AUTH_KEY\', \'put your unique phrase here\');
define(\'LOGGED_IN_KEY\', \'put your unique phrase here\');
define(\'NONCE_KEY\', \'put your unique phrase here\');
define(\'AUTH_SALT\', \'put your unique phrase here\');
define(\'SECURE_AUTH_SALT\', \'put your unique phrase here\');
define(\'LOGGED_IN_SALT\', \'put your unique phrase here\');
define(\'NONCE_SALT\', \'put your unique phrase here\');
独特的短语用于
cryptographic hash function身份验证cookie,其名称存储在AUTH\\u cookie中,AUTH\\u cookie是通过将“wordpress\\u”与默认常量中设置的siteurl的md5和串联而形成的。php。这是默认行为,可以通过预先设置一些常量从配置文件内部重写。
身份验证cookie是用户名的串联,是身份验证cookie有效的时间戳。,还有一个HMAC,对于那些提取TL的人来说,它是一种偏向于键的哈希;立即进行DR。这三个变量与管道字符|相连。
以下是HMAC的构造方式:
$hash = hash_hmac(\'md5\', $username . \'|\' . $expiration, wp_hash($username . substr($user->user_pass, 8, 4) . \'|\' . $expiration, $scheme));
这安全吗根据
this article 这个答案中的大部分信息来自哪里?如果黑客知道你的唯一短语是什么,那么他们需要大约一周的时间才能以每秒30次的速度发送请求,如果你的密钥是唯一的,那么发送请求的难度将是20000000000000000000000000000000000000000000000倍。