Problem Getting Access Token
-
I spent half my day debugging this. Turns out, the plugin is signing the request for an access token with both a token and a token secret – but at this stage of the OAuth flow, there is no token secret.
I was able to work around the issue by updating the fetch_access_token function in the class-oauth.php file to the following:
public function fetch_access_token(&$request) { $this->get_version($request); $consumer = $this->get_consumer($request); // requires authorized request token $token = $this->get_token($request, $consumer, "request"); $token->secret = ""; //Clear out the secret - there is none at this point $this->check_signature($request, $consumer, $token); // Rev A change $verifier = $request->get_parameter('oauth_verifier'); $new_token = $this->data_store->new_access_token($token, $consumer, $verifier); return $new_token; }
- The topic ‘Problem Getting Access Token’ is closed to new replies.