feat(altcha): add altcha validation layer to login
Some checks are pending
Cadoles/hydra-sql/pipeline/pr-develop Build started...
Some checks are pending
Cadoles/hydra-sql/pipeline/pr-develop Build started...
This commit is contained in:
39
src/Altcha/Form/AltchaModel.php
Normal file
39
src/Altcha/Form/AltchaModel.php
Normal file
@ -0,0 +1,39 @@
|
||||
<?php
|
||||
|
||||
namespace App\Altcha\Form;
|
||||
|
||||
use Symfony\Component\Validator\Constraints as Assert;
|
||||
|
||||
class AltchaModel
|
||||
{
|
||||
/**
|
||||
* @Assert\NotBlank()
|
||||
* @Assert\Regex("/^(SHA-1|SHA-256|SHA-512)$/")
|
||||
*/
|
||||
public string $algorithm;
|
||||
|
||||
/**
|
||||
* @Assert\NotBlank()
|
||||
*/
|
||||
public string $challenge;
|
||||
|
||||
/**
|
||||
* @Assert\NotBlank()
|
||||
*/
|
||||
public string $salt;
|
||||
|
||||
/**
|
||||
* @Assert\NotBlank()
|
||||
*/
|
||||
public int $number;
|
||||
|
||||
/**
|
||||
* @Assert\NotBlank()
|
||||
*/
|
||||
public string $signature;
|
||||
|
||||
/**
|
||||
* @Assert\NotBlank()
|
||||
*/
|
||||
public int $took;
|
||||
}
|
Reference in New Issue
Block a user