LTI Integration Library 5.1.4
PHP class library for building LTI integrations
 
Loading...
Searching...
No Matches
OAuthSignatureMethod_HMAC_SHA256 Class Reference

Class to represent an OAuth HMAC_SHA256 signature method. More...

+ Inheritance diagram for OAuthSignatureMethod_HMAC_SHA256:

Public Member Functions

 get_name ()
 Name of the Signature Method.
 
string build_signature (OAuthRequest $request, OAuthConsumer $consumer, ?OAuthToken $token)
 Build up the signature.
 
- Public Member Functions inherited from OAuthSignatureMethod
bool check_signature (OAuthRequest $request, OAuthConsumer $consumer, ?OAuthToken $token, string $signature)
 Verifies that a given signature is correct.
 

Detailed Description

Class to represent an OAuth HMAC_SHA256 signature method.

Author
Stephen P Vickers steph.nosp@m.en@s.nosp@m.pvsof.nosp@m.twar.nosp@m.eprod.nosp@m.ucts.nosp@m..com
Version
2015-11-30
Licence: https://opensource.org/licenses/MIT The MIT License
The HMAC-SHA256 signature method uses the HMAC-SHA256 signature algorithm as defined in [RFC6234] where the Signature Base String is the text and the key is the concatenated values (each first encoded per Parameter Encoding) of the Consumer Secret and Token Secret, separated by an '&' character (ASCII code 38) even if empty.

Member Function Documentation

◆ build_signature()

string build_signature ( OAuthRequest $request,
OAuthConsumer $consumer,
?OAuthToken $token )

Build up the signature.

NOTE: The output of this function MUST NOT be urlencoded. the encoding is handled in OAuthRequest when the final request is serialized

Parameters
OAuthRequest$requestRequest
OAuthConsumer$consumerConsumer
OAuthToken$tokenToken
Returns
string

Reimplemented from OAuthSignatureMethod.

◆ get_name()

get_name ( )

Name of the Signature Method.

Returns
string

Reimplemented from OAuthSignatureMethod.