Files

33 lines
637 B
PHP
Raw Permalink Normal View History

<?php
2026-10-05 18:10:18 -04:00
declare(strict_types=1);
2018-01-19 20:01:56 -06:00
namespace Pterodactyl\Http\Requests\Api\Remote;
use Illuminate\Foundation\Http\FormRequest;
class SftpAuthenticationFormRequest extends FormRequest
{
/**
* Authenticate the request.
*/
2022-10-14 10:59:20 -06:00
public function authorize(): bool
{
return true;
}
/**
* Rules to apply to the request.
2026-10-05 18:10:18 -04:00
*
* @return ValidationRules
*/
2022-10-14 10:59:20 -06:00
public function rules(): array
{
return [
'type' => ['nullable', 'in:password,public_key'],
'username' => ['required', 'string'],
'password' => ['required', 'string'],
];
}
}