Skip to content

Commit

Permalink
Add the option to set a specific (or even empty) token secret when ad…
Browse files Browse the repository at this point in the history
…ding a consumer token.

Fixes issue 105
  • Loading branch information
scherpenisse committed Mar 22, 2011
1 parent 2014a1f commit e520dbb
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion library/store/OAuthStoreOracle.php
Expand Up @@ -979,7 +979,7 @@ public function getConsumerStatic ()
public function addConsumerRequestToken ( $consumer_key, $options = array() )
{
$token = $this->generateKey(true);
$secret = $this->generateKey();
$secret = !isset($options['secret']) ? $this->generateKey() : $options['secret'];


if (isset($options['token_ttl']) && is_numeric($options['token_ttl']))
Expand Down
2 changes: 1 addition & 1 deletion library/store/OAuthStorePostgreSQL.php
Expand Up @@ -1224,7 +1224,7 @@ public function getConsumerStatic ()
public function addConsumerRequestToken ( $consumer_key, $options = array() )
{
$token = $this->generateKey(true);
$secret = $this->generateKey();
$secret = !isset($options['secret']) ? $this->generateKey() : $options['secret'];
$osr_id = $this->query_one('
SELECT osr_id
FROM oauth_server_registry
Expand Down
2 changes: 1 addition & 1 deletion library/store/OAuthStoreSQL.php
Expand Up @@ -1205,7 +1205,7 @@ public function getConsumerStatic ()
public function addConsumerRequestToken ( $consumer_key, $options = array() )
{
$token = $this->generateKey(true);
$secret = $this->generateKey();
$secret = !isset($options['secret']) ? $this->generateKey() : $options['secret'];
$osr_id = $this->query_one('
SELECT osr_id
FROM oauth_server_registry
Expand Down

0 comments on commit e520dbb

Please sign in to comment.