| Total Complexity | 4 |
| Total Lines | 53 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 11 | class Method implements MethodInterface |
||
| 12 | { |
||
| 13 | /** |
||
| 14 | * The number of back-up codes that should be generated for a user. Note that changing this value will not |
||
| 15 | * regenerate or generate new codes to meet the new number. The user will have to manually regenerate codes to |
||
| 16 | * receive the new number of codes. |
||
| 17 | * |
||
| 18 | * @config |
||
| 19 | * @var int |
||
| 20 | */ |
||
| 21 | private static $backup_code_count = 9; |
||
|
|
|||
| 22 | |||
| 23 | /** |
||
| 24 | * The length of each individual backup code |
||
| 25 | * |
||
| 26 | * @config |
||
| 27 | * @var int |
||
| 28 | */ |
||
| 29 | private static $backup_code_length = 6; |
||
| 30 | |||
| 31 | /** |
||
| 32 | * Get a URL segment for this method. This will be used in URL paths for performing authentication by this method |
||
| 33 | * |
||
| 34 | * @return string |
||
| 35 | */ |
||
| 36 | public function getURLSegment() |
||
| 39 | } |
||
| 40 | |||
| 41 | /** |
||
| 42 | * Return the LoginHandler that is used to start and verify login attempts with this method |
||
| 43 | * |
||
| 44 | * @return LoginHandlerInterface |
||
| 45 | */ |
||
| 46 | public function getLoginHandler() |
||
| 47 | { |
||
| 48 | return Injector::inst()->create(LoginHandler::class); |
||
| 49 | } |
||
| 50 | |||
| 51 | /** |
||
| 52 | * Return the RegisterHandler that is used to perform registrations with this method |
||
| 53 | * |
||
| 54 | * @return RegisterHandlerInterface |
||
| 55 | */ |
||
| 56 | public function getRegisterHandler() |
||
| 59 | } |
||
| 60 | |||
| 61 | public function getDetails() |
||
| 64 | } |
||
| 65 | } |
||
| 66 |