Closed GoogleCodeExporter closed 9 years ago
[deleted comment]
the issue appeared because current twitcurl implementation can't get access
token. to resolve it u should update libtwitcurl\oauthlib.h:
change oAuthTwitterApiUrls from
const std::string OAUTHLIB_TWITTER_REQUEST_TOKEN_URL = "twitter.com/oauth/request_token";
const std::string OAUTHLIB_TWITTER_AUTHORIZE_URL = "twitter.com/oauth/authorize?oauth_token=";
const std::string OAUTHLIB_TWITTER_ACCESS_TOKEN_URL = "twitter.com/oauth/access_token";
to
const std::string OAUTHLIB_TWITTER_REQUEST_TOKEN_URL = "api.twitter.com/oauth/request_token";
const std::string OAUTHLIB_TWITTER_AUTHORIZE_URL = "api.twitter.com/oauth/authorize?oauth_token=";
const std::string OAUTHLIB_TWITTER_ACCESS_TOKEN_URL = "api.twitter.com/oauth/access_token";
Original comment by ffo...@gmail.com
on 25 Feb 2013 at 3:04
I am having a similar problem. I am attempting to get the Request token and it
is returning nothing.
// Step 2: Get request token key and secret
twitterObj.oAuthRequestToken( tmpStr );
It just returns OAUTHLIB_TWITTER_AUTHORIZE_URL without appending the necessary
oauth_token. I tested the TwitterClient.exe in the download section and that
application no longer works either.
Original comment by cesar...@gmail.com
on 25 Feb 2013 at 9:25
Have you tried my solution for that issue? twitterClient app need rebuild to
work properly as before.
Original comment by ffo...@gmail.com
on 25 Feb 2013 at 9:31
Yeah it didn't work, I think the "http" is required.
const std::string OAUTHLIB_TWITTER_REQUEST_TOKEN_URL =
"http://api.twitter.com/oauth/request_token";
const std::string OAUTHLIB_TWITTER_AUTHORIZE_URL = "http://api.twitter.com/oauth/authorize?oauth_token=";
const std::string OAUTHLIB_TWITTER_ACCESS_TOKEN_URL = "http://api.twitter.com/oauth/access_token";
Original comment by cesar...@gmail.com
on 25 Feb 2013 at 9:44
Even though twitter gives us these as:
Request token URL https://api.twitter.com/oauth/request_token
Authorize URL https://api.twitter.com/oauth/authorize
Access token URL https://api.twitter.com/oauth/access_token
The https:// does not work as:
bool twitCurl::performGet( const std::string& getUrl, const std::string&
oAuthHttpHeader );
doesn't seem to handle those https request very well. The http will still work.
I have updated my application and it seems to be working as good as ever.
Thanks for the point in the right direction.
Original comment by cesar...@gmail.com
on 25 Feb 2013 at 9:50
The solution provided above have solved the problem everything is working as
before perfectly. Thanks, please commit the above fix in the code.
Original comment by q...@0x80.org
on 25 Feb 2013 at 10:20
"Yeah it didn't work, I think the "http" is required."
the correct protocol added as well (just look at twitCurl::oAuthRequestToken:
correct url created as "twitCurlDefaults::TWITCURL_PROTOCOLS[m_eProtocolType] +
oAuthTwitterApiUrls::OAUTHLIB_TWITTER_REQUEST_TOKEN_URL"). so that it's no need
to add it separately.
Did you make a rebuild of twitcurl.lib before linking twitterClient?
Original comment by ffo...@gmail.com
on 26 Feb 2013 at 5:43
Thanks, correct OAuth URLs are updated in oauthlib.h.
Original comment by swatkat....@gmail.com
on 22 Jun 2013 at 7:08
Original issue reported on code.google.com by
q...@0x80.org
on 21 Feb 2013 at 9:33