@@ 255-261 (lines=7) @@ | ||
252 | ||
253 | $random = ''; |
|
254 | ||
255 | if (CRYPT_BLOWFISH == 1 && !$this->portable_hashes) { |
|
256 | $random = $this->get_random_bytes(16); |
|
257 | $hash = |
|
258 | crypt($password, $this->gensalt_blowfish($random)); |
|
259 | if (strlen($hash) == 60) { |
|
260 | return $hash; |
|
261 | } |
|
262 | } |
|
263 | ||
264 | if (CRYPT_EXT_DES == 1 && !$this->portable_hashes) { |
|
@@ 264-271 (lines=8) @@ | ||
261 | } |
|
262 | } |
|
263 | ||
264 | if (CRYPT_EXT_DES == 1 && !$this->portable_hashes) { |
|
265 | if (strlen($random) < 3) { |
|
266 | $random = $this->get_random_bytes(3); |
|
267 | } |
|
268 | $hash = |
|
269 | crypt($password, $this->gensalt_extended($random)); |
|
270 | if (strlen($hash) == 20) { |
|
271 | return $hash; |
|
272 | } |
|
273 | } |
|
274 |