TNCSignatory
Table of Contents
- downloadSignatory() : void
- generateKeys() : mixed
- getKeyOrigin() : string
- retrieveSignatory() : NCSignatory
- return Signatory by its Id from cache or from direct request.
- signString() : string
- updateSignatory() : void
- verifyString() : mixed
Methods
downloadSignatory()
public
downloadSignatory(NCSignatory $signatory[, string $keyId = '' ][, array<string|int, mixed> $params = [] ][, NCRequest|null $request = null ]) : void
Parameters
- $signatory : NCSignatory
- $keyId : string = ''
- $params : array<string|int, mixed> = []
- $request : NCRequest|null = null
Tags
Return values
void —generateKeys()
public
generateKeys(NCSignatory $signatory[, string $digest = 'rsa' ][, int $bits = 2048 ][, int $type = OPENSSL_KEYTYPE_RSA ]) : mixed
Parameters
- $signatory : NCSignatory
- $digest : string = 'rsa'
- $bits : int = 2048
- $type : int = OPENSSL_KEYTYPE_RSA
Return values
mixed —getKeyOrigin()
public
getKeyOrigin(string $keyId) : string
Parameters
- $keyId : string
Tags
Return values
string —retrieveSignatory()
return Signatory by its Id from cache or from direct request.
public
retrieveSignatory(string $keyId[, bool $refresh = false ]) : NCSignatory
Should be overwritten.
Parameters
- $keyId : string
- $refresh : bool = false
Tags
Return values
NCSignatory —signString()
public
signString(string $clear, NCSignatory $signatory) : string
Parameters
- $clear : string
- $signatory : NCSignatory
Tags
Return values
string —updateSignatory()
public
updateSignatory(NCSignatory $signatory, array<string|int, mixed> $json[, string $keyId = '' ]) : void
Parameters
- $signatory : NCSignatory
- $json : array<string|int, mixed>
- $keyId : string = ''
Tags
Return values
void —verifyString()
public
verifyString(string $clear, string $signed, string $publicKey[, string $algo = NCSignatory::SHA256 ]) : mixed
Parameters
- $clear : string
- $signed : string
- $publicKey : string
- $algo : string = NCSignatory::SHA256