This is a non-exhaustive (but still near complete) changelog for phpBB 2.0.x including beta and release candidate versions. Our thanks to all those people who've contributed bug reports and code fixes.
-
l.i. Changes since 2.0.16
+
l.i. Changes since 2.0.17
+
+
+
[Fix] incorrect handling of password resets if admin activation is enabled (Bug #88)
+
[Fix] retrieving category rows in index.php (Bug #90)
+
[Fix] wrong topic redirection after login redirect (Bug #94)
+
[Fix] improved handling of username lists in admin_ug_auth.php (Bug #98)
+
[Fix] incorrect removal of bbcode_uid values if bbcode has been turned off (Bug #100)
+
[Fix] incorrect alt tag on generated search images in viewtopic.php and usercp_viewprofile.php (Bug #102)
+
[Fix] consistent forum ordering in all dropdown boxes (Bug #106)
+
[Fix] correctly get compression status in page_tail.php and page_footer_admin.php (Bug #117)
+
[Fix] handling of both forms of translation information used in language packs (Bug #159)
+
[Fix] key length for activation keys fixed in usercp_sendpassword.php (Bug #171)
+
[Fix] use GENERAL_MESSAGE constant in message_die instead of MESSAGE (Bug #176)
+
[Fix] incorrect handling of move stubs (Bug #179)
+
[Fix] wrong mode_type in memberlist (Bug #187)
+
[Fix] removed unused variable from topic_notify email template (Bug #210)
+
[Fix] invalid HTML in overall_header.tpl when user is logged in (Bug #211)
+
[Fix] removed unset variable from smilies popup window title (Bug #224)
+
[Fix] removed duplicate template assignment from admin_board.php (Bug #226)
+
[Fix] incorrect search link for guest posts in modcp.php (Bug #254)
+
[Fix] correctly check returned value from strpos in append_sid function (Bug #275)
+
[Fix] correctly display username in private message notification (Bug #278)
+
[Fix] fixed "var-by-ref" errors (Bug #322)
+
+
l.ii. Changes since 2.0.16
Added extra checks to the deletion code in privmsg.php - reported by party_fan
@@ -78,7 +103,7 @@ p,ul,td {font-size:10pt;}
Correctly set username on posts when deleting a user from the admin panel
-
l.ii. Changes since 2.0.15
+
l.iii. Changes since 2.0.15
Fixed critical issue with highlighting - Discovered and fix provided by Ron van Daal
@@ -90,7 +115,7 @@ p,ul,td {font-size:10pt;}
Fixed bug in admin re-authentication redirect for servers not having index.php as one of their default files set
-
l.iii. Changes since 2.0.14
+
l.iv. Changes since 2.0.14
Fixed moderator status removal in groupcp.php
@@ -112,7 +137,7 @@ p,ul,td {font-size:10pt;}
Empty url/img bbcodes no longer get parsed
-
l.iv. Changes since 2.0.13
+
l.v. Changes since 2.0.13
Hardened author and keyword search a bit to not allow very server intensive searches
@@ -129,7 +154,7 @@ p,ul,td {font-size:10pt;}
Fixed case-sensitivity issues in postgres7.php - R45
-
l.v. Changes since 2.0.12
+
l.vi. Changes since 2.0.12
Ommitted preg_replace warning in viewtopic due to improper working of preg_quote in PHP - originally reported by matrix_killer, fix submitted by another party
@@ -137,7 +162,7 @@ p,ul,td {font-size:10pt;}
Minimum requirements raised to PHP 4.0.3 or above due to fixing vulnerability issues breaking PHP3 compatibility.
-
l.vi. Changes since 2.0.11
+
l.vii. Changes since 2.0.11
Added confirm table to admin_db_utilities.php
@@ -152,7 +177,7 @@ p,ul,td {font-size:10pt;}
Fixed path disclosure bug in viewtopic.php caused by a PHP 4.3.10 bug - matrix_killer
-
l.vii. Changes since 2.0.10
+
l.viii. Changes since 2.0.10
Fixed vulnerability in highlighting code (very high severity, please update your installation as soon as possible)
@@ -163,7 +188,7 @@ p,ul,td {font-size:10pt;}
Added visual confirmation mod to code base
-
l.viii. Changes since 2.0.9
+
l.ix. Changes since 2.0.9
Fixed deleting of styles in admin_styles.php
@@ -176,7 +201,7 @@ p,ul,td {font-size:10pt;}
Fixed visual confirmation code. The image was not created due to a wrong regular expression.
-
l.ix. Changes since 2.0.8
+
l.x. Changes since 2.0.8
Fixed one vulnerability in admin_board.php - Xore
@@ -195,7 +220,7 @@ p,ul,td {font-size:10pt;}
Fixed problem with SID not delivered to next page in groupcp.php
-
l.x. Changes since 2.0.7
+
l.xi. Changes since 2.0.7
Fixed several vulnerabilities in admin pages
@@ -207,7 +232,7 @@ p,ul,td {font-size:10pt;}
Fixed sql injection vulnerability in privmsg - 2.0.8a
-
1.xi. Changes since 2.0.6
+
1.xii. Changes since 2.0.6
Fixed several vulnerabilities in modcp - Robert Lavierck
@@ -221,7 +246,7 @@ p,ul,td {font-size:10pt;}
Fixed potential vulnerability in avatar gallery
-
1.xii. Changes since 2.0.5
+
1.xiii. Changes since 2.0.5
Fixed various email issues
@@ -237,7 +262,7 @@ p,ul,td {font-size:10pt;}
Fixed sql injection with reset date format field in profile - tendor
-
1.xiii. Changes since 2.0.4
+
1.xiv. Changes since 2.0.4
Removed user facing session_id checks
@@ -309,7 +334,7 @@ p,ul,td {font-size:10pt;}
Default English support for visual confirmation - translators are encouraged to support this
-
1.xiv. Changes since 2.0.3
+
1.xv. Changes since 2.0.3
Fixed cross-browser scripting issue with highlight param
@@ -436,7 +461,7 @@ p,ul,td {font-size:10pt;}
Fixed potential SQL vulnerability with marking of private messages - Ulf Harnhammar
-
1.xv. Changes since 2.0.2
+
1.xvi. Changes since 2.0.2
Fixed potential cross-site scripting vulnerability with avatars - Showscout
@@ -445,7 +470,7 @@ p,ul,td {font-size:10pt;}
Fixed (hopefully) issue with MS Access and multiple pages
-
1.xvi. Changes since 2.0.1
+
1.xvii. Changes since 2.0.1
Fixed missing "username" lang variable in user admin template
@@ -480,7 +505,7 @@ p,ul,td {font-size:10pt;}
Fix emailer to allow sending emails with language-specific character sets
-
1.xvii. Changes since 2.0.0
+
1.xviii. Changes since 2.0.0
Fixed delete image bug for normal users
@@ -537,7 +562,7 @@ p,ul,td {font-size:10pt;}
Added database closure to admin frameset page
-
1.xviii. Changes since RC-4
+
1.xix. Changes since RC-4
Fixed improper report of general error when posting messages containing errors
@@ -567,7 +592,7 @@ p,ul,td {font-size:10pt;}
Fixed various remaining usergroup display issues
-
1.xix. Changes since RC-3
+
1.xx. Changes since RC-3
Addressed serious security issue with included files
@@ -598,7 +623,7 @@ p,ul,td {font-size:10pt;}
Fix (hopefully) remaining ICQ overlay issue with view profile in subSilver
-
1.xx. Changes since RC-2
+
1.xxi. Changes since RC-2
Fixed infamous install parse error
@@ -631,7 +656,7 @@ p,ul,td {font-size:10pt;}
Hidden usergroups are now completely hidden from view
-
1.xxi. Changes since RC-1
+
1.xxii. Changes since RC-1
Fixed numerous PostgreSQL related issues
@@ -651,7 +676,7 @@ p,ul,td {font-size:10pt;}
Various other fixes and updates
-
1.xxii. Changes since RC-1 (pre)
+
1.xxiii. Changes since RC-1 (pre)
Upgrade script completed for initial fully functional release
diff --git a/phpBB/includes/functions_admin.php b/phpBB/includes/functions_admin.php
index 3fa941787d..c26943d893 100644
--- a/phpBB/includes/functions_admin.php
+++ b/phpBB/includes/functions_admin.php
@@ -32,7 +32,7 @@ function make_forum_select($box_name, $ignore_forum = false, $select_forum = '')
$sql = "SELECT forum_id, forum_name
FROM " . FORUMS_TABLE . "
- ORDER BY cat_id, forum_order";
+ ORDER BY cat_order, forum_order";
if ( !($result = $db->sql_query($sql)) )
{
message_die(GENERAL_ERROR, 'Couldn not obtain forums information', '', __LINE__, __FILE__, $sql);
@@ -140,10 +140,45 @@ function sync($type, $id = false)
if ( $row = $db->sql_fetchrow($result) )
{
- $sql = ( $row['total_posts'] ) ? "UPDATE " . TOPICS_TABLE . " SET topic_replies = " . ( $row['total_posts'] - 1 ) . ", topic_first_post_id = " . $row['first_post'] . ", topic_last_post_id = " . $row['last_post'] . " WHERE topic_id = $id" : "DELETE FROM " . TOPICS_TABLE . " WHERE topic_id = $id";
- if ( !$db->sql_query($sql) )
+ if ($row['total_posts'])
{
- message_die(GENERAL_ERROR, 'Could not update topic', '', __LINE__, __FILE__, $sql);
+ // Correct the details of this topic
+ $sql = 'UPDATE ' . TOPICS_TABLE . '
+ SET topic_replies = ' . ($row['total_posts'] - 1) . ', topic_first_post_id = ' . $row['first_post'] . ', topic_last_post_id = ' . $row['last_post'] . "
+ WHERE topic_id = $id";
+
+ if (!$db->sql_query($sql))
+ {
+ message_die(GENERAL_ERROR, 'Could not update topic', '', __LINE__, __FILE__, $sql);
+ }
+ }
+ else
+ {
+ // There are no replies to this topic
+ // Check if it is a move stub
+ $sql = 'SELECT topic_moved_id
+ FROM ' . TOPICS_TABLE . "
+ WHERE topic_id = $id";
+
+ if (!($result = $db->sql_query($sql)))
+ {
+ message_die(GENERAL_ERROR, 'Could not get topic ID', '', __LINE__, __FILE__, $sql);
+ }
+
+ if ($row = $db->sql_fetchrow($result))
+ {
+ if (!$row['topic_moved_id'])
+ {
+ $sql = 'DELETE FROM ' . TOPICS_TABLE . " WHERE topic_id = $id";
+
+ if (!$db->sql_query($sql))
+ {
+ message_die(GENERAL_ERROR, 'Could not remove topic', '', __LINE__, __FILE__, $sql);
+ }
+ }
+ }
+
+ $db->sql_freeresult($result);
}
}
break;
diff --git a/phpBB/includes/functions_post.php b/phpBB/includes/functions_post.php
index 0877877311..e5d868ff4e 100644
--- a/phpBB/includes/functions_post.php
+++ b/phpBB/includes/functions_post.php
@@ -213,7 +213,7 @@ function prepare_post(&$mode, &$post_data, &$bbcode_on, &$html_on, &$smilies_on,
//
// Post a new topic/reply/poll or edit existing post/poll
//
-function submit_post($mode, &$post_data, &$message, &$meta, &$forum_id, &$topic_id, &$post_id, &$poll_id, &$topic_type, &$bbcode_on, &$html_on, &$smilies_on, &$attach_sig, &$bbcode_uid, &$post_username, &$post_subject, &$post_message, &$poll_title, &$poll_options, &$poll_length)
+function submit_post($mode, &$post_data, &$message, &$meta, &$forum_id, &$topic_id, &$post_id, &$poll_id, &$topic_type, &$bbcode_on, &$html_on, &$smilies_on, &$attach_sig, &$bbcode_uid, $post_username, $post_subject, $post_message, $poll_title, &$poll_options, &$poll_length)
{
global $board_config, $lang, $db, $phpbb_root_path, $phpEx;
global $userdata, $user_ip;
@@ -769,7 +769,7 @@ function generate_smilies($mode, $page_id)
$gen_simple_header = TRUE;
- $page_title = $lang['Emoticons'] . " - $topic_title";
+ $page_title = $lang['Emoticons'];
include($phpbb_root_path . 'includes/page_header.'.$phpEx);
$template->set_filenames(array(
diff --git a/phpBB/includes/functions_search.php b/phpBB/includes/functions_search.php
index 72ebcf1896..277a8563de 100644
--- a/phpBB/includes/functions_search.php
+++ b/phpBB/includes/functions_search.php
@@ -89,7 +89,7 @@ function clean_words($mode, &$entry, &$stopword_list, &$synonym_list)
return $entry;
}
-function split_words(&$entry, $mode = 'post')
+function split_words($entry, $mode = 'post')
{
// If you experience problems with the new method, uncomment this block.
/*
diff --git a/phpBB/includes/page_tail.php b/phpBB/includes/page_tail.php
index c91145ab77..2386034cda 100644
--- a/phpBB/includes/page_tail.php
+++ b/phpBB/includes/page_tail.php
@@ -25,6 +25,8 @@ if ( !defined('IN_PHPBB') )
die('Hacking attempt');
}
+global $do_gzip_compress;
+
//
// Show the overall footer.
//
@@ -35,7 +37,7 @@ $template->set_filenames(array(
);
$template->assign_vars(array(
- 'TRANSLATION_INFO' => ( isset($lang['TRANSLATION_INFO']) ) ? $lang['TRANSLATION_INFO'] : '',
+ 'TRANSLATION_INFO' => (isset($lang['TRANSLATION_INFO'])) ? $lang['TRANSLATION_INFO'] : ((isset($lang['TRANSLATION'])) ? $lang['TRANSLATION'] : ''),
'ADMIN_LINK' => $admin_link)
);
diff --git a/phpBB/includes/sessions.php b/phpBB/includes/sessions.php
index 7bb5f8a2fd..b064c8c7e2 100644
--- a/phpBB/includes/sessions.php
+++ b/phpBB/includes/sessions.php
@@ -415,7 +415,7 @@ function append_sid($url, $non_html_amp = false)
if ( !empty($SID) && !preg_match('#sid=#', $url) )
{
- $url .= ( ( strpos($url, '?') != false ) ? ( ( $non_html_amp ) ? '&' : '&' ) : '?' ) . $SID;
+ $url .= ( ( strpos($url, '?') !== false ) ? ( ( $non_html_amp ) ? '&' : '&' ) : '?' ) . $SID;
}
return $url;
diff --git a/phpBB/includes/usercp_activate.php b/phpBB/includes/usercp_activate.php
index f0633e91af..11f106364c 100644
--- a/phpBB/includes/usercp_activate.php
+++ b/phpBB/includes/usercp_activate.php
@@ -47,9 +47,16 @@ if ( $row = $db->sql_fetchrow($result) )
}
else if ((trim($row['user_actkey']) == trim($HTTP_GET_VARS['act_key'])) && (trim($row['user_actkey']) != ''))
{
- if (intval($board_config['require_activation']) == USER_ACTIVATION_ADMIN && $userdata['user_level'] != ADMIN)
+ if (intval($board_config['require_activation']) == USER_ACTIVATION_ADMIN && $row['user_newpasswd'] == '')
{
- message_die(GENERAL_MESSAGE, $lang['Not_Authorised']);
+ if (!$userdata['session_logged_in'])
+ {
+ redirect(append_sid('login.' . $phpEx . '?redirect=profile.' . $phpEx . '&mode=activate&' . POST_USERS_URL . '=' . $row['user_id'] . '&act_key=' . trim($HTTP_GET_VARS['act_key'])));
+ }
+ else if ($userdata['user_level'] != ADMIN)
+ {
+ message_die(GENERAL_MESSAGE, $lang['Not_Authorised']);
+ }
}
$sql_update_pass = ( $row['user_newpasswd'] != '' ) ? ", user_password = '" . str_replace("\'", "''", $row['user_newpasswd']) . "', user_newpasswd = ''" : '';
diff --git a/phpBB/includes/usercp_register.php b/phpBB/includes/usercp_register.php
index 9dd7922149..03b1600d38 100644
--- a/phpBB/includes/usercp_register.php
+++ b/phpBB/includes/usercp_register.php
@@ -818,7 +818,7 @@ if( isset($HTTP_POST_VARS['avatargallery']) && !$error )
$allowviewonline = !$allowviewonline;
- display_avatar_gallery($mode, $avatar_category, $user_id, $email, $current_email, $coppa, $username, $email, &$new_password, &$cur_password, $password_confirm, $icq, $aim, $msn, $yim, $website, $location, $occupation, $interests, $signature, $viewemail, $notifypm, $popup_pm, $notifyreply, $attachsig, $allowhtml, $allowbbcode, $allowsmilies, $allowviewonline, $user_style, $user_lang, $user_timezone, $user_dateformat, $userdata['session_id']);
+ display_avatar_gallery($mode, $avatar_category, $user_id, $email, $current_email, $coppa, $username, $email, $new_password, $cur_password, $password_confirm, $icq, $aim, $msn, $yim, $website, $location, $occupation, $interests, $signature, $viewemail, $notifypm, $popup_pm, $notifyreply, $attachsig, $allowhtml, $allowbbcode, $allowsmilies, $allowviewonline, $user_style, $user_lang, $user_timezone, $user_dateformat, $userdata['session_id']);
}
else
{
diff --git a/phpBB/includes/usercp_sendpasswd.php b/phpBB/includes/usercp_sendpasswd.php
index 7b51dcaa36..b8617a04b9 100644
--- a/phpBB/includes/usercp_sendpasswd.php
+++ b/phpBB/includes/usercp_sendpasswd.php
@@ -50,7 +50,7 @@ if ( isset($HTTP_POST_VARS['submit']) )
$user_actkey = gen_rand_string(true);
$key_len = 54 - strlen($server_url);
- $key_len = ( $str_len > 6 ) ? $key_len : 6;
+ $key_len = ($key_len > 6) ? $key_len : 6;
$user_actkey = substr($user_actkey, 0, $key_len);
$user_password = gen_rand_string(false);
diff --git a/phpBB/includes/usercp_viewprofile.php b/phpBB/includes/usercp_viewprofile.php
index 3b2162bced..daa115add1 100644
--- a/phpBB/includes/usercp_viewprofile.php
+++ b/phpBB/includes/usercp_viewprofile.php
@@ -165,7 +165,7 @@ $yim_img = ( $profiledata['user_yim'] ) ? '' . $lang['YIM'] . '' : '';
$temp_url = append_sid("search.$phpEx?search_author=" . urlencode($profiledata['username']) . "&showresults=posts");
-$search_img = '';
+$search_img = '';
$search = '' . sprintf($lang['Search_user_posts'], $profiledata['username']) . '';
//
diff --git a/phpBB/index.php b/phpBB/index.php
index bb9823864b..03baa4723d 100644
--- a/phpBB/index.php
+++ b/phpBB/index.php
@@ -119,7 +119,10 @@ if( !($result = $db->sql_query($sql)) )
}
$category_rows = array();
-while( $category_rows[] = $db->sql_fetchrow($result) );
+while ($row = $db->sql_fetchrow($result))
+{
+ $category_rows[] = $row;
+}
$db->sql_freeresult($result);
if( ( $total_categories = count($category_rows) ) )
diff --git a/phpBB/language/lang_english/email/topic_notify.tpl b/phpBB/language/lang_english/email/topic_notify.tpl
index 9682ebbe69..574f955c40 100644
--- a/phpBB/language/lang_english/email/topic_notify.tpl
+++ b/phpBB/language/lang_english/email/topic_notify.tpl
@@ -1,7 +1,7 @@
Subject: Topic Reply Notification - {TOPIC_TITLE}
Charset: iso-8859-1
-Hello {USERNAME},
+Hello,
You are receiving this email because you are watching the topic, "{TOPIC_TITLE}" at {SITENAME}. This topic has received a reply since your last visit. You can use the following link to view the replies made, no more notifications will be sent until you visit the topic.
diff --git a/phpBB/language/lang_english/lang_main.php b/phpBB/language/lang_english/lang_main.php
index 8eceb7cf3c..b52f863f02 100644
--- a/phpBB/language/lang_english/lang_main.php
+++ b/phpBB/language/lang_english/lang_main.php
@@ -530,7 +530,6 @@ $lang['Email_address'] = 'E-mail address';
$lang['Email'] = 'E-mail';
$lang['Send_private_message'] = 'Send private message';
$lang['Hidden_email'] = '[ Hidden ]';
-$lang['Search_user_posts'] = 'Search for posts by this user';
$lang['Interests'] = 'Interests';
$lang['Occupation'] = 'Occupation';
$lang['Poster_rank'] = 'Poster rank';
diff --git a/phpBB/memberlist.php b/phpBB/memberlist.php
index 2d882faf22..a5538e0320 100644
--- a/phpBB/memberlist.php
+++ b/phpBB/memberlist.php
@@ -61,7 +61,7 @@ else
// Memberlist sorting
//
$mode_types_text = array($lang['Sort_Joined'], $lang['Sort_Username'], $lang['Sort_Location'], $lang['Sort_Posts'], $lang['Sort_Email'], $lang['Sort_Website'], $lang['Sort_Top_Ten']);
-$mode_types = array('joindate', 'username', 'location', 'posts', 'email', 'website', 'topten');
+$mode_types = array('joined', 'username', 'location', 'posts', 'email', 'website', 'topten');
$select_sort_mode = '