Lines Matching defs:magic
36 $magic = '';
49 $magic = '1';
53 $magic = 'apr1';
57 $magic = 'S';
61 $magic = 'P';
65 $magic = 'H';
68 $magic = ['algo' => $m[1], 'iter' => $m[2]];
72 $magic = ['algo' => $m[1], 'iter' => $m[2]];
98 $magic = ['prefix' => $m[1], 'rounds' => $m[2]];
122 $newhash = $this->$call($clear, $salt, $magic);
224 * @param string $magic The hash identifier (apr1 or 1)
227 public function hash_apr1($clear, $salt = null, $magic = 'apr1')
232 $text = $clear . '$' . $magic . '$' . $salt;
261 return '$' . $magic . '$' . $salt . '$' . $tmp;
402 * @param string $magic The hash identifier (P or H)
407 protected function stretched_hash($algo, $clear, $salt = null, $magic = 'P', $compute = 8)
451 return '$' . $magic . '$' . $iterc . $salt . $output;
467 * @param string $magic The hash identifier (P or H)
472 public function hash_pmd5($clear, $salt = null, $magic = 'P', $compute = 8)
474 return $this->stretched_hash('md5', $clear, $salt, $magic, $compute);
489 * @param string $magic The hash identifier (S)
494 public function hash_drupal_sha512($clear, $salt = null, $magic = 'S', $compute = 15)
496 return substr($this->stretched_hash('sha512', $clear, $salt, $magic, $compute), 0, 55);
504 * @param string $magic
510 public function hash_hmd5($clear, $salt = null, $magic = 'H', $compute = 8)
512 return $this->hash_pmd5($clear, $salt, $magic, $compute);