1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-07-30 21:40:43 +02:00

[ticket/12352] Add passwords driver for passwords that should be converted

This driver will only be used for getting the new $CP$ prefix that will signal
that the hash is a legacy hash that needs to be converted.

PHPBB3-12352
This commit is contained in:
Marc Alexander
2014-05-11 22:23:23 +02:00
parent 57e4fb3810
commit 1e758ba7f0
3 changed files with 63 additions and 1 deletions

View File

@@ -0,0 +1,50 @@
<?php
/**
*
* @package phpBB3
* @copyright (c) 2014 phpBB Group
* @license http://opensource.org/licenses/gpl-2.0.php GNU General Public License v2
*
*/
namespace phpbb\passwords\driver;
/**
* @package passwords
*/
class convert_password extends base
{
const PREFIX = '$CP$';
/**
* @inheritdoc
*/
public function get_prefix()
{
return self::PREFIX;
}
/**
* @inheritdoc
*/
public function hash($password, $user_row = '')
{
return false;
}
/**
* @inheritdoc
*/
public function check($password, $hash, $user_row = array())
{
return false;
}
/**
* @inheritdoc
*/
public function get_settings_only($hash, $full = false)
{
return false;
}
}