seryi (@seryi)

Forum Replies Created

Viewing 2 replies - 1 through 2 (of 2 total)
  • The same happened to me after upgrading my wordpress to V.2.5.1

    The problem is that auth mechanism in wordpress (based on cookies) has changed and no more compatible with the bbPress’ one. I believe that the next bbPress release will fix it. However now there is only one way to solve the problem – to edit some piece of code(only few lines). This is the instruction:

    1) open your bbpress_dir/bb-includes/pluggable.php

    2) find function wp_validate_auth_cookie

    3) inside this function change next 2 lines of code

    $key = wp_hash($username . $expiration);

    $hash = hash_hmac(‘md5’, $username . $expiration, $key);

    to

    $key = wp_hash($username . ‘|’ . $expiration);

    $hash = hash_hmac(‘md5’, $username . ‘|’ . $expiration, $key);

    4) find function wp_generate_auth_cookie

    5) inside this function change next 2 lines of code

    $key = wp_hash($user->user_login . $expiration);

    $hash = hash_hmac(‘md5’, $user->user_login . $expiration, $key);

    to

    $key = wp_hash($user->user_login . ‘|’ . $expiration);

    $hash = hash_hmac(‘md5’, $user->user_login . ‘|’ . $expiration, $key);

    That’s all!

    NOTE! It’s only actual for wordpress 2.5.1 with bbpress 0.9.0.1

    The same happened to me after upgrading my wordpress to V.2.5.1

    The problem is that auth mechanism in wordpress (based on cookies) has changed and no more compatible with the bbPress’ one. I believe that the next bbPress release will fix it. However now there is only one way to solve the problem – to edit some piece of code(only few lines). This is the instruction:

    1) open your bbpress_dir/bb-includes/pluggable.php

    2) find function wp_validate_auth_cookie

    3) inside this function change next 2 lines of code

    $key = wp_hash($username . $expiration);

    $hash = hash_hmac(‘md5’, $username . $expiration, $key);

    to

    $key = wp_hash($username . ‘|’ . $expiration);

    $hash = hash_hmac(‘md5’, $username . ‘|’ . $expiration, $key);

    4) find function wp_generate_auth_cookie

    5) inside this function change next 2 lines of code

    $key = wp_hash($user->user_login . $expiration);

    $hash = hash_hmac(‘md5’, $user->user_login . $expiration, $key);

    to

    $key = wp_hash($user->user_login . ‘|’ . $expiration);

    $hash = hash_hmac(‘md5’, $user->user_login . ‘|’ . $expiration, $key);

    That’s all!

    NOTE! It’s only actual for wordpress 2.5.1 with bbpress 0.9.0.1

Viewing 2 replies - 1 through 2 (of 2 total)