hash
symfony/var-dumper
Supported Versions: PHP 5 >= 5.1.2, PHP 7, PHP 8, PECL hash >= 1.1
Generate a hash value (message digest)
hash
(
string $algo
,
string $data
,
bool $binary
=
false
,
array $options
= []):
string
$pin
=
openssl_pkey_get_details
(
$pin
)[
'key'
];
$pin
=
\array_slice
(
explode
(
"\n"
,
$pin
),
1
, -
2
);
$pin
=
base64_decode
(
implode
(
''
,
$pin
));
$pin
=
base64_encode
(
hash
(
'sha256'
,
$pin
,
true
));
$a
+= [
'subject'
=> new
EnumStub
(
array_intersect_key
(
$info
[
'subject'
], [
'organizationName'
=>
true
,
'commonName'
=>
true
])),
Caster/ResourceCaster.php
return [
'command_line'
=>
$commandLine
=
implode
(
' '
,
$_SERVER
[
'argv'
] ?? []),
'identifier'
=>
hash
(
'crc32b'
,
$commandLine
.
$_SERVER
[
'REQUEST_TIME_FLOAT'
]),
];
}
}
Dumper/ContextProvider/CliContextProvider.php