Skip to main content

AuthenticityClient

Represents a client for interacting with the Bloock Authenticity service.

  • Full name: \Bloock\Client\AuthenticityClient

Properties

bridge

private $bridge

config

private $config

Methods

__construct

Creates a new instance of the AuthenticityClient with default configuration.

public __construct(\Bloock\ConfigData|null $config = null): mixed

Parameters:

ParameterTypeDescription
$config\Bloock\ConfigData|null

generateEcdsaKeyPair

Generates ECDSA key pair for signing records.

public generateEcdsaKeyPair(): \Bloock\Entity\Key\EcdsaKeyPair
  • Warning: this method is deprecated. This means that this method will likely be removed in a future version.

sign

Signs a Bloock record using the specified signer.

public sign(\Bloock\Entity\Record\Record $record, \Bloock\Entity\Authenticity\Signer $signer): \Bloock\Entity\Authenticity\Signature

Parameters:

ParameterTypeDescription
$record\Bloock\Entity\Record\Record
$signer\Bloock\Entity\Authenticity\Signer

Throws:


verify

Verifies the authenticity of a Bloock record.

public verify(\Bloock\Entity\Record\Record $record): bool

Parameters:

ParameterTypeDescription
$record\Bloock\Entity\Record\Record

Throws:


getSignatures

Gets the signatures associated with a Bloock record.

public getSignatures(\Bloock\Entity\Record\Record $record): array

Parameters:

ParameterTypeDescription
$record\Bloock\Entity\Record\Record

Throws:



Automatically generated on 2024-04-02