germanzero / oauth-php

Automatically exported from code.google.com/p/oauth-php
MIT License
0 stars 0 forks source link

Something wrong about HMAC_SHA1 #108

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?

I use oauth-php as a OAuth Server, and use Zend_Oauth as a Consumer, when use 
HMAC_SHA1 as signature method, it will throw this exception:
{{{
 OAuthException2('Verification of signature failed (signature base string was "'.$this->signatureBaseString().'").' 
                    . " with  " . print_r(array($secrets['consumer_secret'], $secrets['token_secret'], $token_type), true));
            }
}}}

and I use oauth.signpost in java as a Consumer, also has this problem.  

When I change signature to PlainText , Zend_Oauth and Java oauth.signpost are 
both working fine. no exception.

What is the expected output? What do you see instead?

What version of the product are you using? On what operating system?
oauth-php-175.tar.gz

Please provide any additional information below.

Original issue reported on code.google.com by lds1...@gmail.com on 19 Apr 2011 at 10:47

GoogleCodeExporter commented 8 years ago
Update: this problem only happens when request param's value has a blank space.

like: 
$client->setParameterPost('content', "content");  // OK
$client->setParameterPost('content', "content content");  // Fail

Original comment by lds1...@gmail.com on 20 Apr 2011 at 2:32

GoogleCodeExporter commented 8 years ago
Same bug reported as bug #99

Original comment by dbelli...@gmail.com on 15 Jul 2011 at 11:31