File Manager Lite
Dir:
/home/codewavebd/public_html/vendor/laravel/framework/src/Illuminate/Hashing
Upload
[..]
AbstractHasher.php (760 B)
Edit
Rename
Del
Argon2IdHasher.php (1.21 KB)
Edit
Rename
Del
ArgonHasher.php (5.75 KB)
Edit
Rename
Del
HashManager.php (3 KB)
Edit
Rename
Del
LICENSE.md (1.05 KB)
Edit
Rename
Del
composer.json (823 B)
Edit
Rename
Del
Edit: Argon2IdHasher.php
<?php namespace Illuminate\Hashing; use RuntimeException; class Argon2IdHasher extends ArgonHasher { /** * Check the given plain value against a hash. * * @param string $value * @param string $hashedValue * @param array $options * @return bool * * @throws \RuntimeException */ public function check(#[\SensitiveParameter] $value, $hashedValue, array $options = []) { if (is_null($hashedValue) || (string) $hashedValue === '') { return false; } if ($this->verifyAlgorithm && ! $this->isUsingCorrectAlgorithm($hashedValue)) { throw new RuntimeException('This password does not use the Argon2id algorithm.'); } return password_verify($value, $hashedValue); } /** * Verify the hashed value's algorithm. * * @param string $hashedValue * @return bool */ protected function isUsingCorrectAlgorithm($hashedValue) { return $this->info($hashedValue)['algoName'] === 'argon2id'; } /** * Get the algorithm that should be used for hashing. * * @return int */ protected function algorithm() { return PASSWORD_ARGON2ID; } }
Simpan