The RSA-SHA1 signature method uses the RSASSA-PKCS1-v1_5 signature algorithm as defined in [RFC3447] section 8.2 (more simply known as PKCS#1), using SHA-1 as the hash function for EMSA-PKCS1-v1_5.

It is assumed that the Consumer has provided its RSA public key in a verified way to the Service Provider, in a manner which is beyond the scope of this specification. - Chapter 9.3 ("RSA-SHA1")

 Methods

Build up the signature NOTE: The output of this function MUST NOT be urlencoded.

build_signature(\Moneybird\Lib\OAuthRequest $request, \Moneybird\Lib\OAuthConsumer $consumer, \Moneybird\Lib\OAuthToken $token) : string

the encoding is handled in OAuthRequest when the final request is serialized

Parameters

Returns

string

Verifies that a given signature is correct

check_signature(\Moneybird\Lib\OAuthRequest $request, \Moneybird\Lib\OAuthConsumer $consumer, \Moneybird\Lib\OAuthToken $token, string $signature) : bool

Parameters

$signature

string

Returns

bool

Needs to return the name of the Signature Method (ie HMAC-SHA1)

get_name() : string

Returns

string

fetch_private_cert()

fetch_private_cert($request) 

Parameters

$request

fetch_public_cert()

fetch_public_cert($request) 

Parameters

$request