MediaWiki REL1_31
Pbkdf2PasswordFallbackTest.php
Go to the documentation of this file.
1<?php
2
3
9 protected function getTypeConfigs() {
10 return [
11 'pbkdf2' => [
12 'class' => Pbkdf2Password::class,
13 'algo' => 'sha256',
14 'cost' => '10000',
15 'length' => '128',
16 'use-hash-extension' => false,
17 ],
18 ];
19 }
20
21 public static function providePasswordTests() {
22 return [
23 [ true, ":pbkdf2:sha1:1:20:c2FsdA==:DGDID5YfDnHzqbUkr2ASBi/gN6Y=", 'password' ],
24 [ true, ":pbkdf2:sha1:2:20:c2FsdA==:6mwBTcctb4zNHtkqzh1B8NjeiVc=", 'password' ],
25 [ true, ":pbkdf2:sha1:4096:20:c2FsdA==:SwB5AbdlSJq+rUnZJvch0GWkKcE=", 'password' ],
26 [ true, ":pbkdf2:sha1:4096:16:c2EAbHQ=:Vvpqp1VICZ3MN9fwNCXgww==", "pass\x00word" ],
27 ];
28 }
29}
getTypeConfigs()
Return an array of configs to be used for this class's password type.
static providePasswordTests()
An array of tests in the form of (bool, string, string), where the first element is whether the secon...