function SimpleOAuthDataStore::new_token in OAuth 1.0 6
2 calls to SimpleOAuthDataStore::new_token()
File
- ./
OAuth.php, line 703
Class
Code
function new_token($consumer, $type = "request") {
/*{{{*/
$key = md5(time());
$secret = time() + time();
$token = new OAuthToken($key, md5(md5($secret)));
if (!dba_insert("{$type}_{$key}", serialize($token), $this->dbh)) {
throw new OAuthException("doooom!");
}
return $token;
}