TYPE-0 PERFECT SEIHA
Server Info:
FreeBSD scimitar.blueboard.cz 13.5-STABLE FreeBSD 13.5-STABLE stable/13-4f2925105 GENERIC amd64
Software:
Apache
User:
www
Crot
Crot File
Crot Dir
Crot Command
[LockSelf]
[HOME]
data
www
19068
fszoo_net
addlogo
home
vendor
nette
security
src
Security
Show Hidden Files
Edit File: /data/www/19068/fszoo_net/addlogo/home/vendor/nette/security/src/Security/Passwords.php
<?php /** * This file is part of the Nette Framework (http://nette.org) * Copyright (c) 2004 David Grudl (http://davidgrudl.com) */ namespace Nette\Security; use Nette; /** * Passwords tools. Requires PHP >= 5.3.7. */ class Passwords { const BCRYPT_COST = 10; /** * Computes salted password hash. * @param string * @param array with cost (4-31), salt (22 chars) * @return string 60 chars long */ public static function hash($password, array $options = NULL) { $cost = isset($options['cost']) ? (int) $options['cost'] : self::BCRYPT_COST; $salt = isset($options['salt']) ? (string) $options['salt'] : Nette\Utils\Random::generate(22, '0-9A-Za-z./'); if (PHP_VERSION_ID < 50307) { throw new Nette\NotSupportedException(__METHOD__ . ' requires PHP >= 5.3.7.'); } elseif (($len = strlen($salt)) < 22) { throw new Nette\InvalidArgumentException("Salt must be 22 characters long, $len given."); } elseif ($cost < 4 || $cost > 31) { throw new Nette\InvalidArgumentException("Cost must be in range 4-31, $cost given."); } $hash = crypt($password, '$2y$' . ($cost < 10 ? 0 : '') . $cost . '$' . $salt); if (strlen($hash) < 60) { throw new Nette\InvalidStateException('Hash returned by crypt is invalid.'); } return $hash; } /** * Verifies that a password matches a hash. * @return bool */ public static function verify($password, $hash) { return preg_match('#^\$2y\$(?P<cost>\d\d)\$(?P<salt>.{22})#', $hash, $m) && $m['cost'] >= 4 && $m['cost'] <= 31 && self::hash($password, $m) === $hash; } /** * Checks if the given hash matches the options. * @param string * @param array with cost (4-31) * @return bool */ public static function needsRehash($hash, array $options = NULL) { $cost = isset($options['cost']) ? (int) $options['cost'] : self::BCRYPT_COST; return !preg_match('#^\$2y\$(?P<cost>\d\d)\$(?P<salt>.{22})#', $hash, $m) || $m['cost'] < $cost; } }
Crotin
Name
Size
Permissions
Modified
User/Group
IIdentity.php
422
0644
2015-09-30 18:28:48
Unknown/Unknown
SimpleAuthenticator.php
1401
0644
2015-09-30 18:28:48
Unknown/Unknown
Identity.php
2452
0644
2015-09-30 18:28:49
Unknown/Unknown
IAuthenticator.php
651
0644
2015-09-30 18:28:48
Unknown/Unknown
IUserStorage.php
1248
0644
2015-09-30 18:28:48
Unknown/Unknown
Passwords.php
1958
0644
2015-09-30 18:28:49
Unknown/Unknown
User.php
5810
0644
2015-09-30 18:28:48
Unknown/Unknown
IResource.php
369
0644
2015-09-30 18:28:48
Unknown/Unknown
AuthenticationException.php
255
0644
2015-09-30 18:28:48
Unknown/Unknown
Permission.php
20297
0644
2015-09-30 18:28:49
Unknown/Unknown
IAuthorizator.php
641
0644
2015-09-30 18:28:48
Unknown/Unknown
IRole.php
363
0644
2015-09-30 18:28:49
Unknown/Unknown
NGANU
Rename
Hapus
Chmod
Chown
Touch
Zip
Unzip
Download
Crotin