PHP Fatal Error – yii\base\ErrorException
Call to undefined function yii\base\hash_hmac()
О чем это говорит?1. in /home/site/domains/site.ru/public_html/lk/vendor/yiisoft/yii2/base/Security.php at line 408
399 * It indicates whether the hash value in the data is in binary format. If false, it means the hash value consists
400 * of lowercase hex digits only.
401 * hex digits will be generated.
402 * @return string the real data with the hash stripped off. False if the data is tampered.
403 * @throws InvalidConfigException when HMAC generation fails.
404 * @see hashData()
405 */
406 public function validateData($data, $key, $rawHash = false)
407 {
408 $test = @hash_hmac($this->macHash, '', '', $rawHash);
409 if (!$test) {
410 throw new InvalidConfigException('Failed to generate HMAC with hash algorithm: ' . $this->macHash);
411 }
412 $hashLength = StringHelper::byteLength($test);
413 if (StringHelper::byteLength($data) >= $hashLength) {
414 $hash = StringHelper::byteSubstr($data, 0, $hashLength);
415 $pureData = StringHelper::byteSubstr($data, $hashLength, null);
416
417 $calculatedHash = hash_hmac($this->macHash, $pureData, $key, $rawHash);
2. yii\base\ErrorHandler::handleFatalError()