I first check out the main branch which failed miserably, so i read the issues and went to the 6.x-3.0 beta2 which is identical to 6.x-3.x-dev which is odd because they are different in date greatly and people in issues say the dev is newer but they are basically identical. I tried the various patches read different people work and couldn't get any of them to work for me, so I wrote my own patch. Using OAuth 6.x-2.02 and Twitter 6.x-3.0 beta2.

It seems that the class TwitterOAuth extends Twitter in auth_request() seems to call the base method request() with and it seems that the base model has an issue with POST Requests. They were doing a http_build_query($params) and using that as the HTTP POST Body but that doesn't work as the & between the parameters are turned into & and thus the OAuth signature doesn't match what they calculate on their end and user authentication fails, thus the command fails. The function status_update() does its work as a POST were a lot of the other lifting in the module is done as a GET. But this works for me, I can add a new twitter account on my profile page, and when I make a new post they actually get posted which is far improvement of what I had before.

Also because of my installation site that I don't have access to upgrade I was on php 5.0.4 and the module designed for 5.1 and oauth requires HASH Message Digest Framework and I didn't have any of that so I added checks for the missing methods and added substitution replacements for them. If anyone else needs these I have included the patches.

Comments

bryjeep’s picture

Formatting changed the presentation of my message, here what should have said: ...as the & between the parameters are turned into & and thus...

aaron.r.carlton’s picture

Version: 6.x-3.0-beta2 » 6.x-3.0-beta3
Priority: Normal » Major

subscribing. i am also experiencing this behavior in the beta-3 branch. thanks for putting in the effort to generate a patch, however, your patch doesn't apply for me. i went through and tried to fix it manually, but I'm still getting an 'uncaught exception' for Unauthorized. Would you mind re-rolling your patch against the latest dev version? I'll take a look myself, also.

Thanks!

steinmb’s picture

Title: statuses/update.json "Could not authenticate you." » statuses/update.json "Could not authenticate you." running PHP 5.0
Version: 6.x-3.0-beta3 » 6.x-3.x-dev
Priority: Major » Normal

Any idea what to do with this issue? Could contain hints to weaknesses in the existing code base?

13rac1’s picture

Version: 6.x-3.x-dev » 6.x-5.x-dev
Status: Active » Postponed (maintainer needs more info)

Please update to the current 5.x version of the module. Does the problem still exist?

xurizaemon’s picture

Status: Postponed (maintainer needs more info) » Closed (cannot reproduce)

No response in 1 year