OAuth 1.0a and 2 support

This commit is contained in:
Evan Seguin
2012-10-02 15:59:55 -07:00
parent 0e6e912176
commit 33ba91700b
11 changed files with 125 additions and 16 deletions

View File

@@ -3,15 +3,15 @@ require_once(dirname(__FILE__) . "/HeaderAuthentication.php");
class BasicAuthentication extends HeaderAuthentication {
private $header;
private $headers;
function __construct($username, $password) {
$headerValue = $username . ":" . $password;
$this->header = "Authorization: Basic " . base64_encode($headerValue);
$this->headers = array("Authorization: Basic " . base64_encode($headerValue));
}
public function handleHeader() {
return $this->header;
public function handleHeaders() {
return $this->headers;
}
public function handleParams() {