mirror of
https://github.com/phpbb/phpbb.git
synced 2025-08-12 03:34:04 +02:00
Merge branch '3.1.x' into 3.2.x
* 3.1.x: [ticket/14789] Add form tokens to tests and uncomment add_form_key [ticket/14789] Add link hashes and form tokens to all acp links/buttons
This commit is contained in:
@@ -244,6 +244,11 @@ class acp_language
|
||||
break;
|
||||
|
||||
case 'install':
|
||||
if (!check_link_hash($request->variable('hash', ''), 'acp_language'))
|
||||
{
|
||||
trigger_error($user->lang['FORM_INVALID'] . adm_back_link($this->u_action), E_USER_WARNING);
|
||||
}
|
||||
|
||||
$lang_iso = $request->variable('iso', '');
|
||||
$lang_iso = basename($lang_iso);
|
||||
|
||||
@@ -405,7 +410,7 @@ class acp_language
|
||||
'ISO' => htmlspecialchars($lang_ary['iso']),
|
||||
'LOCAL_NAME' => htmlspecialchars($lang_ary['local_name'], ENT_COMPAT, 'UTF-8'),
|
||||
'NAME' => htmlspecialchars($lang_ary['name'], ENT_COMPAT, 'UTF-8'),
|
||||
'U_INSTALL' => $this->u_action . '&action=install&iso=' . urlencode($lang_ary['iso']))
|
||||
'U_INSTALL' => $this->u_action . '&action=install&iso=' . urlencode($lang_ary['iso']) . '&hash=' . generate_link_hash('acp_language'))
|
||||
);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user