mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-27 21:58:52 +00:00
[ticket/security-253] Check form key when exporting PM data
SECURITY-253
This commit is contained in:
parent
7d90f84306
commit
c44c398626
1 changed files with 7 additions and 0 deletions
|
@ -32,6 +32,8 @@ function view_folder($id, $mode, $folder_id, $folder)
|
|||
|
||||
$folder_info = get_pm_from($folder_id, $folder, $user->data['user_id']);
|
||||
|
||||
add_form_key('ucp_pm_view_folder');
|
||||
|
||||
if (!$submit_export)
|
||||
{
|
||||
$user->add_lang('viewforum');
|
||||
|
@ -197,6 +199,11 @@ function view_folder($id, $mode, $folder_id, $folder)
|
|||
$enclosure = $request->variable('enclosure', '');
|
||||
$delimiter = $request->variable('delimiter', '');
|
||||
|
||||
if (!check_form_key('ucp_pm_view_folder'))
|
||||
{
|
||||
trigger_error('FORM_INVALID');
|
||||
}
|
||||
|
||||
if ($export_type == 'CSV' && ($delimiter === '' || $enclosure === ''))
|
||||
{
|
||||
$template->assign_var('PROMPT', true);
|
||||
|
|
Loading…
Add table
Reference in a new issue