LTI Integration Library 5.2.0
PHP class library for building LTI integrations
 
Loading...
Searching...
No Matches
ceLTIc\LTI\OAuth\OAuthServer Class Reference

Class to represent an OAuth server. More...

Public Member Functions

 __construct (OAuthDataStore $data_store)
 Class constructor.
 
void add_signature_method (OAuthSignatureMethod $signature_method)
 Add a signature method.
 
OAuthToken null fetch_request_token (OAuthRequest &$request)
 Process a request_token request.
 
OAuthToken null fetch_access_token (OAuthRequest &$request)
 Process an access_token request.
 
array verify_request (OAuthRequest &$request)
 Verify an API call, checks all the parameters.
 

Protected Attributes

int $timestamp_threshold = 300
 Timestamp threshhold.
 
string $version = '1.0'
 Version string.
 
array $signature_methods = []
 Signature methods.
 
OAuthDataStore $data_store
 Data store.
 

Detailed Description

Class to represent an OAuth server.

Version
2008-08-04
Licence: https://opensource.org/licenses/MIT The MIT License

Constructor & Destructor Documentation

◆ __construct()

ceLTIc\LTI\OAuth\OAuthServer::__construct ( OAuthDataStore $data_store)

Class constructor.

Parameters
OAuthDataStore$data_storeData store

Member Function Documentation

◆ add_signature_method()

void ceLTIc\LTI\OAuth\OAuthServer::add_signature_method ( OAuthSignatureMethod $signature_method)

Add a signature method.

Parameters
OAuthSignatureMethod$signature_methodSignature method

References ceLTIc\LTI\OAuth\OAuthRequest\get_parameter().

◆ fetch_access_token()

OAuthToken null ceLTIc\LTI\OAuth\OAuthServer::fetch_access_token ( OAuthRequest & $request)

Process an access_token request.

Returns the access token on success

Parameters
OAuthRequest$requestRequest
Returns
OAuthToken|null

References $version, and ceLTIc\LTI\OAuth\OAuthRequest\get_parameter().

◆ fetch_request_token()

OAuthToken null ceLTIc\LTI\OAuth\OAuthServer::fetch_request_token ( OAuthRequest & $request)

Process a request_token request.

Returns the request token on success

Parameters
OAuthRequest$requestRequest
Returns
OAuthToken|null

◆ verify_request()

array ceLTIc\LTI\OAuth\OAuthServer::verify_request ( OAuthRequest & $request)

Verify an API call, checks all the parameters.

Parameters
OAuthRequest$requestRequest
Returns
array

References ceLTIc\LTI\OAuth\OAuthRequest\get_parameter().

Member Data Documentation

◆ $data_store

OAuthDataStore ceLTIc\LTI\OAuth\OAuthServer::$data_store
protected

Data store.

◆ $signature_methods

array ceLTIc\LTI\OAuth\OAuthServer::$signature_methods = []
protected

Signature methods.

◆ $timestamp_threshold

int ceLTIc\LTI\OAuth\OAuthServer::$timestamp_threshold = 300
protected

Timestamp threshhold.

◆ $version

string ceLTIc\LTI\OAuth\OAuthServer::$version = '1.0'
protected

Version string.

Referenced by fetch_access_token().