class Hmac extends StringMutator (View source)

Generates a hash-based message authentication code (HMAC) using a secret key with the given algorithm.

Traits

Methods

__construct(string $algo, string $key, bool $rawOutput = false)

No description

mixed
__invoke(mixed $value)

Mutate the input value.

from  Mutator
static Hmac
make(string $algo, string $key, bool $rawOutput = false)

No description

mixed
mutate(mixed $value)

Mutate the input value.

string
mutateString(string $value)

No description

string
resolveStringInput(mixed $value)

No description

Details

__construct(string $algo, string $key, bool $rawOutput = false)

No description

Parameters

string $algo

The algorithm to use.

string $key

The secret key.

bool $rawOutput

Whether to output raw binary data (default: false).

final mixed __invoke(mixed $value)

Mutate the input value.

Parameters

mixed $value

Return Value

mixed

static Hmac make(string $algo, string $key, bool $rawOutput = false)

No description

Parameters

string $algo

The algorithm to use.

string $key

The secret key.

bool $rawOutput

Whether to output raw binary data (default: false).

Return Value

Hmac

final mixed mutate(mixed $value)

Mutate the input value.

Parameters

mixed $value

Return Value

mixed

protected string mutateString(string $value)

No description

Parameters

string $value

Return Value

string

protected string resolveStringInput(mixed $value)

No description

Parameters

mixed $value

Return Value

string