Lines Matching refs:opts

564      * @param array $opts ('algo' => hash algorithm, 'iter' => iterations)
568 public function hash_seafilepbkdf2($clear, $salt = null, $opts = []) argument
571 if (empty($opts['algo'])) {
574 $prefixalgo = $opts['algo'];
577 if (empty($opts['iter'])) {
580 $iter = (int) $opts['iter'];
601 * @param array $opts ('algo' => hash algorithm, 'iter' => iterations)
605 public function hash_djangopbkdf2($clear, $salt = null, $opts = []) argument
608 if (empty($opts['algo'])) {
611 $algo = $opts['algo'];
613 if (empty($opts['iter'])) {
616 $iter = (int) $opts['iter'];
634 * @param array $opts ('iter' => iterations)
638 public function hash_djangopbkdf2_sha256($clear, $salt = null, $opts = []) argument
640 $opts['algo'] = 'sha256';
641 return $this->hash_djangopbkdf2($clear, $salt, $opts);
649 * @param array $opts ('iter' => iterations)
653 public function hash_djangopbkdf2_sha1($clear, $salt = null, $opts = []) argument
655 $opts['algo'] = 'sha1';
656 return $this->hash_djangopbkdf2($clear, $salt, $opts);
722 …* @param array $opts ('rounds' => rounds for sha256/sha512, 'prefix' => selected method from SHA-2…
726 public function hash_sha2($clear, $salt = null, $opts = []) argument
728 if (empty($opts['prefix'])) {
731 $prefix = $opts['prefix'];
733 if (empty($opts['rounds'])) {
736 $rounds = $opts['rounds'];
753 public function hash_sha512($clear, $salt = null, $opts = []) argument
755 $opts['prefix'] = 6;
756 return $this->hash_sha2($clear, $salt, $opts);
760 public function hash_sha256($clear, $salt = null, $opts = []) argument
762 $opts['prefix'] = 5;
763 return $this->hash_sha2($clear, $salt, $opts);