PHP Class PayPal\Auth\Oauth\OAuthSignatureMethod

Show file Open project: paypal/sdk-core-php

Public Methods

Method Description
build_signature ( OAuthRequest $request, OAuthConsumer $consumer, OAuthToken $token ) : string Build up the signature NOTE: The output of this function MUST NOT be urlencoded.
check_signature ( OAuthRequest $request, OAuthConsumer $consumer, OAuthToken $token, string $signature ) : boolean Verifies that a given signature is correct
get_name ( ) : string Needs to return the name of the Signature Method (ie HMAC-SHA1)

Method Details

build_signature() abstract public method

the encoding is handled in OAuthRequest when the final request is serialized
abstract public build_signature ( OAuthRequest $request, OAuthConsumer $consumer, OAuthToken $token ) : string
$request OAuthRequest
$consumer OAuthConsumer
$token OAuthToken
return string

check_signature() public method

Verifies that a given signature is correct
public check_signature ( OAuthRequest $request, OAuthConsumer $consumer, OAuthToken $token, string $signature ) : boolean
$request OAuthRequest
$consumer OAuthConsumer
$token OAuthToken
$signature string
return boolean

get_name() abstract public method

Needs to return the name of the Signature Method (ie HMAC-SHA1)
abstract public get_name ( ) : string
return string