SetaPDF_Signer_Tsp_Token Class representing a Timestamp Token

File: /SetaPDF v2/Signer/Tsp/Token.php

Class hierarchy

Summary

Static Properties

$usePhpseclibForRsaPss

Flag defining whether usage of phpseclib or default OpenSSL methods for RSA_PSS validation.

$verifyCallback

static public null|callable SetaPDF_Signer_Asn1_Signed::$verifyCallback

A callable that can be used to implement individual verification logic.


Properties

$_detachedSignedData

$_message

$_signedAttributes

All signed attributes. Indexed by their OID.

$_tstInfo

$_unsignedAttributes

All unsigned attributes. Indexed by their OID.


Methods

_getSignedData()

Get SignedData element from the ASN.1 structure.

_getSignerInfo()

Get the SignerInfo element from the ASN.1 structure.

Exceptions

Throws SetaPDF_Signer_Exception

_getTstInfo()

Get the timestamp token info element.

Exceptions

Throws SetaPDF_Signer_Asn1_Exception

getAsn1()

Get the ASN.1 instance of the SignedData element.

getCertificates()

Get all certificates embedded in the SignedData structure.

Exceptions

Throws SetaPDF_Signer_Asn1_Exception

getDigestAlgorithm()

getDigestAlgorithms()

Get the digest algorithms and parameters.

Return Values

An array of arrays where the first value holds the OID of the algorithm. The second value is the ASN.1 structure of the parameters.

Exceptions

Throws SetaPDF_Signer_Exception

getGenerationTime()

Get the gerneation time.

Exceptions

Throws SetaPDF_Signer_Asn1_Exception

getIssuerAndSerialNumber()

Get issuer and serial number of the signee.

Exceptions

Throws SetaPDF_Signer_Asn1_Exception

Throws SetaPDF_Signer_Exception

getMessageImprint()

Get the message imprint element.

Exceptions

Throws SetaPDF_Signer_Asn1_Exception

getNonce()

public SetaPDF_Signer_Tsp_Token::getNonce (
void
): bool|string

Get the none value.

Exceptions

Throws SetaPDF_Signer_Asn1_Exception

getSerialNumber()

public SetaPDF_Signer_Tsp_Token::getSerialNumber (
void
): string

Get the serial number of the token.

Exceptions

Throws SetaPDF_Signer_Asn1_Exception

getSignatureAlgorithm()

Return Values

The first value holds the OID of the algorithm. The second value is the ASN.1 structure of the parameters.

Exceptions

Throws SetaPDF_Signer_Exception

getSignatureValue()

public SetaPDF_Signer_Cms_SignedData::getSignatureValue (
[ bool $hex = true ]
): string
Parameters
$hex : bool
 
Exceptions

Throws SetaPDF_Signer_Exception

getSignedAttribute()

Get a signed attribute by its OID.

Parameters
$oid : string
 
Exceptions

Throws SetaPDF_Signer_Exception

getSignedAttributes()

Get all signed attributes.

Exceptions

Throws SetaPDF_Signer_Exception

getSigningCertificate()

getSubjectKeyIdentifier()

Get the subject key identifier.

Exceptions

Throws SetaPDF_Signer_Exception

getUnsignedAttribute()

Get an unsigned attribute by its OID.

Parameters
$oid : string
 
Exceptions

Throws SetaPDF_Signer_Exception

getUnsignedAttributes()

Get all unsigned attributes.

Exceptions

Throws SetaPDF_Signer_Exception

setDetachedSignedData()

Overwritte to disable this method. It is not allowed to use it in a timestamp token instance.

Parameters
$detachedSignedData : SetaPDF_Core_Reader_FilePath|string
 

verify()

Parameters
$signerCertificate : SetaPDF_Signer_X509_Certificate
 
Exceptions

Throws SetaPDF_Signer_Asn1_Exception

Throws SetaPDF_Signer_Exception

verifyMessageImprint()

Verifies the message imprint.

Parameters
$data : string|SetaPDF_Core_Reader_FilePath
 
Exceptions

Throws SetaPDF_Signer_Asn1_Exception

Throws SetaPDF_Signer_Exception