ldc-gen-game-web/app/Http/Requests/Fo/UpdatePasswordRequest.php

40 lines
889 B
PHP

<?php
namespace App\Http\Requests\Fo;
use Illuminate\Foundation\Http\FormRequest;
use Illuminate\Validation\Rules\Password;
class UpdatePasswordRequest extends FormRequest
{
/**
* Determine if the user is authorized to make this request.
*
* @return boolean
*/
public function authorize()
{
// * Autorisation vérifiée dans le controlleur.
return true;
}
/**
* Get the validation rules that apply to the request.
*
* @return array
*/
public function rules()
{
return [
'password' => [
'required', 'confirmed', 'min:8', 'max:255',
Password::min(8)
->mixedCase()
->letters()
->numbers()
->symbols()
->uncompromised()
]
];
}
}