Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7183085
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T17:54:29+00:00 2026-05-28T17:54:29+00:00

First, a note: My host does not have the PECL OAUTH or HTTP extensions

  • 0

First, a note: My host does not have the PECL OAUTH or HTTP extensions installed.

The purpose of this: I’m hoping to create an interface to easily follow and unfollow a given list of Tumblr names.

Problem: Can’t get past the authentication step.

Code:

$request_url = 'http://www.tumblr.com/oauth/request_token';
$consumer_key = COSUMER_KEY;
$consumer_secret = CONSUMER_SECRET;
$oauth_key = urlencode_rfc3986($consumer_secret) . '&';
$time = time();
$nonce = md5(microtime() . mt_rand());
$callback_url = 'http://krisallengallery.com/easyfollowr/index.php';
$params = array('oauth_consumer_key' => $consumer_key,
                'oauth_signature_method' => 'HMAC-SHA1',
                'oauth_timestamp' => $time,
                'oauth_nonce' => $nonce,
                'oauth_version' => '1.0a',
                'oauth_callback' => $callback_url);             
uksort($params, 'strcmp');

$oauth_header = 'Authorization: OAuth ';

$raw_signature = 'GET&' . urlencode_rfc3986($request_url) . '&';
$raw_suffix = array();
foreach($params as $key => $param)
{
    $raw_suffix[] = $key . '=' . $param;
}
$raw_signature .= urlencode_rfc3986(implode('&', $raw_suffix));
$oauth_signature = urlencode_rfc3986(base64_encode(hash_hmac('sha1', $raw_signature, $oauth_key, true)));

$params['oauth_signature'] = $oauth_signature;
uksort($params, 'strcmp');

$raw_head = array();
foreach($params as $key => $param)
{
    $raw_head[] = $key . '="' . $param . '"';
}
$oauth_header .= implode(',', $raw_head);

$session = curl_init($request_url);
curl_setopt($session, CURLOPT_RETURNTRANSFER, true);
curl_setopt($session, CURLOPT_HEADER, true);
curl_setopt($session, CURLOPT_HTTPHEADER, array($oauth_header));
$response = curl_exec($session);
curl_close($session);
echo $response;

function urlencode_rfc3986($input)
{
    return str_replace('+', ' ', str_replace('%7E', '~', rawurlencode($input)));
}

Any ideas of where I’m going wrong?

ETA: Made some modifications. It’s still not working, but the error I’m getting now is oauth_signature does not match expected value

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-28T17:54:30+00:00Added an answer on May 28, 2026 at 5:54 pm

    I’m not entirely sure what I was doing wrong, but fortunately, I found fangel’s OAuth script on GitHub that implements everything I need to generate tokens. It looks like I was on the the right track, though.

    ETA: Furthermore, there is jacobbudin’s TumblrOAuth library on GitHub, which uses fangel’s script and some forked then updated code, that handles all the Tumblr authentication for a user for your application.

    I’m sure I’ll be back with more questions when I start trying to build my Followr script.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

First as a note I am using this plugin in a Rails app. Ok
NOTE: I am not set on using VI, it is just the first thing
Consider this XML file. Note the first Tutorial has an Author child element, and
First do note that my english in not the best here. If anyone is
First note: mathematically, I'm not that skilled at all. I played a game on
I have two questions here, why does the following function in a script not
I'd like to note first that this is an education attempt on my own
First, let me note that the connection infomation is not the correct info. I
First note, im not asking for code, more insight on the process flow. i
How can I retrieve the first and last record from a table. Note :

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.