* @license https://files.froxlor.org/misc/COPYING.txt GPLv2 */ use Froxlor\Settings; use Froxlor\System\Crypt; return [ 'htpasswd_edit' => [ 'title' => lng('extras.directoryprotection_edit'), 'image' => 'fa-solid fa-lock', 'self_overview' => ['section' => 'extras', 'page' => 'htpasswds'], 'sections' => [ 'section_a' => [ 'title' => lng('extras.directoryprotection_edit'), 'image' => 'icons/htpasswd_edit.png', 'fields' => [ 'path' => [ 'label' => lng('panel.path'), 'type' => 'label', 'value' => $result['path'] ], 'username' => [ 'label' => lng('login.username'), 'type' => 'label', 'value' => $result['username'] ], 'directory_password' => [ 'label' => lng('login.password'), 'type' => 'password', 'autocomplete' => 'off', 'next_to' => [ 'directory_password_suggestion' => [ 'next_to_prefix' => lng('customer.generated_pwd') . ':', 'type' => 'text', 'visible' => (Settings::Get('panel.password_regex') == ''), 'value' => Crypt::generatePassword(), 'readonly' => true ] ] ], 'directory_authname' => [ 'label' => lng('extras.htpasswdauthname'), 'type' => 'text', 'value' => $result['authname'], 'mandatory' => true ] ] ] ] ] ];