Questions tagged «verification»

1
随机数验证如何工作?
我可以看到wp_nonce_field在隐藏字段中生成一个值。 <input type="hidden" id="message-send" name="message-send" value="cabfd9e42d" /> 但是据我所知,wp_verify_nonce没有使用该值,但我可能是错的。 看起来它正在使用会话令牌进行验证。 $expected = substr( wp_hash( $i . '|' . $action . '|' . $uid . '|' . $token, 'nonce'), -12, 10 ); if ( hash_equals( $expected, $nonce ) ) { return 1; } 那么在隐藏字段中具有value属性有什么意义呢?
By using our site, you acknowledge that you have read and understand our Cookie Policy and Privacy Policy.
Licensed under cc by-sa 3.0 with attribution required.