Documentation

MaterialsProviderV2
in package
implements MaterialsProviderInterfaceV2

Interfaces, Classes and Traits

MaterialsProviderInterfaceV2

Table of Contents

$supportedKeySizes  : mixed
decryptCek()  : string
Takes an encrypted content encryption key (CEK) and material description for use decrypting the key according to the Provider's specifications.
generateCek()  : array<string|int, mixed>
generateIv()  : string
getWrapAlgorithmName()  : string
Returns the wrap algorithm name for this Provider.
isSupportedKeySize()  : bool
Returns if the requested size is supported by AES.

Properties

$supportedKeySizes

private static mixed $supportedKeySizes = [128 => true, 256 => true]

Methods

decryptCek()

Takes an encrypted content encryption key (CEK) and material description for use decrypting the key according to the Provider's specifications.

public abstract decryptCek(string $encryptedCek, string $materialDescription, string $options) : string
Parameters
$encryptedCek : string

Encrypted key to be decrypted by the Provider for use decrypting other data.

$materialDescription : string

Material Description for use in decrypting the CEK.

$options : string

Options for use in decrypting the CEK.

Return values
string

generateCek()

public abstract generateCek(string $keySize, array<string|int, mixed> $context, array<string|int, mixed> $options) : array<string|int, mixed>
Parameters
$keySize : string

Length of a cipher key in bits for generating a random content encryption key (CEK).

$context : array<string|int, mixed>

Context map needed for key encryption

$options : array<string|int, mixed>

Additional options to be used in CEK generation

Return values
array<string|int, mixed>

generateIv()

public generateIv(string $openSslName) : string
Parameters
$openSslName : string

Cipher OpenSSL name to use for generating an initialization vector.

Return values
string

getWrapAlgorithmName()

Returns the wrap algorithm name for this Provider.

public abstract getWrapAlgorithmName() : string
Return values
string

isSupportedKeySize()

Returns if the requested size is supported by AES.

public static isSupportedKeySize(int $keySize) : bool
Parameters
$keySize : int

Size of the requested key in bits.

Return values
bool

Search results