From 865ba5a6cf01b60c84124f28533d39240a2717ae Mon Sep 17 00:00:00 2001 From: Mike McGrath Date: Sun, 9 Sep 2007 02:36:14 +0000 Subject: [PATCH 01/31] Silly rebuild --- cacti.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/cacti.spec b/cacti.spec index a63b842..593abef 100644 --- a/cacti.spec +++ b/cacti.spec @@ -1,6 +1,6 @@ Name: cacti Version: 0.8.6j -Release: 1%{?dist} +Release: 6%{?dist} Summary: An rrd based graphing tool Group: Applications/System @@ -103,6 +103,9 @@ fi %attr(0644,root,root) %{_localstatedir}/lib/%{name}/lib %changelog +* Sat Sep 08 2007 Mike McGrath - 0.8.6j-6 +- rebuild + * Sat May 05 2007 Mike McGrath - 0.8.6j-5 - Upstream released new version From 086703965c46597819e28111f8edc7e979ddf5c7 Mon Sep 17 00:00:00 2001 From: Mike McGrath Date: Fri, 14 Sep 2007 21:26:13 +0000 Subject: [PATCH 02/31] Patches for bug#243592 --- CVE-2007-3112.patch | 29 +++++++++++++++++++++++++++++ cacti.spec | 7 ++++++- 2 files changed, 35 insertions(+), 1 deletion(-) create mode 100644 CVE-2007-3112.patch diff --git a/CVE-2007-3112.patch b/CVE-2007-3112.patch new file mode 100644 index 0000000..e77b2b4 --- /dev/null +++ b/CVE-2007-3112.patch @@ -0,0 +1,29 @@ +--- branches/BRANCH_0_8_6/cacti/graph_image.php 2007/03/04 20:17:57 3898 ++++ branches/BRANCH_0_8_6/cacti/graph_image.php 2007/06/04 06:41:13 3956 +@@ -49,22 +49,22 @@ + $graph_data_array = array(); + + /* override: graph start time (unix time) */ +-if (!empty($_GET["graph_start"])) { ++if (!empty($_GET["graph_start"]) && $_GET["graph_start"] < 1600000000) { + $graph_data_array["graph_start"] = $_GET["graph_start"]; + } + + /* override: graph end time (unix time) */ +-if (!empty($_GET["graph_end"])) { ++if (!empty($_GET["graph_end"]) && $_GET["graph_end"] < 1600000000) { + $graph_data_array["graph_end"] = $_GET["graph_end"]; + } + + /* override: graph height (in pixels) */ +-if (!empty($_GET["graph_height"])) { ++if (!empty($_GET["graph_height"]) && $_GET["graph_height"] < 3000) { + $graph_data_array["graph_height"] = $_GET["graph_height"]; + } + + /* override: graph width (in pixels) */ +-if (!empty($_GET["graph_width"])) { ++if (!empty($_GET["graph_width"]) && $_GET["graph_width"] < 3000) { + $graph_data_array["graph_width"] = $_GET["graph_width"]; + } + diff --git a/cacti.spec b/cacti.spec index 593abef..5dcf174 100644 --- a/cacti.spec +++ b/cacti.spec @@ -1,6 +1,6 @@ Name: cacti Version: 0.8.6j -Release: 6%{?dist} +Release: 7%{?dist} Summary: An rrd based graphing tool Group: Applications/System @@ -12,6 +12,7 @@ Source2: cacti.logrotate Source3: cacti.README.Fedora Patch1: cacti-0.8.6h-dbcfg.patch +Patch2: CVE-2007-3112.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) @@ -32,6 +33,7 @@ used to creating traffic graphs with MRTG. %prep %setup -q %patch1 -p0 +%patch2 -p3 echo "#*/5 * * * * cacti %{_bindir}/php %{_datadir}/%{name}/poller.php > /dev/null 2>&1" >cacti.cron @@ -103,6 +105,9 @@ fi %attr(0644,root,root) %{_localstatedir}/lib/%{name}/lib %changelog +* Fri Sep 14 2007 Mike McGrath - 0.8.6j-7 +- Fix for CVE-2007-3112 bz#243592 + * Sat Sep 08 2007 Mike McGrath - 0.8.6j-6 - rebuild From ece2b07b4fa16e461085f67ca924430088498e23 Mon Sep 17 00:00:00 2001 From: Mike McGrath Date: Fri, 14 Sep 2007 21:30:22 +0000 Subject: [PATCH 03/31] Release bump because Its friday and I'm stupid --- cacti.spec | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cacti.spec b/cacti.spec index 5dcf174..8c0121b 100644 --- a/cacti.spec +++ b/cacti.spec @@ -1,6 +1,6 @@ Name: cacti Version: 0.8.6j -Release: 7%{?dist} +Release: 8%{?dist} Summary: An rrd based graphing tool Group: Applications/System @@ -105,7 +105,7 @@ fi %attr(0644,root,root) %{_localstatedir}/lib/%{name}/lib %changelog -* Fri Sep 14 2007 Mike McGrath - 0.8.6j-7 +* Fri Sep 14 2007 Mike McGrath - 0.8.6j-8 - Fix for CVE-2007-3112 bz#243592 * Sat Sep 08 2007 Mike McGrath - 0.8.6j-6 From c3bc59edf4a3a26b7ce672f18a5f70ae0317f50e Mon Sep 17 00:00:00 2001 From: Mike McGrath Date: Fri, 21 Sep 2007 14:57:08 +0000 Subject: [PATCH 04/31] Added official patches from the cacti site --- cacti.spec | 15 +- dec06-vulnerability-poller-0.8.6i.patch | 137 ------------------ dec06-vulnerability-scripts-0.8.6i.patch | 106 -------------- fix_search_session_clear_issue.patch | 27 ---- ...sql_syntax_related_to_default_rra_id.patch | 22 --- graph_debug_lockup_fix.patch | 18 +++ import_template_argument_space_removal.patch | 14 -- mysql_5x_strict.patch | 52 ------- nth_percentile_empty_return_set_issue.patch | 94 ------------ ping_php_version4_snmpgetnext.patch | 42 ++++++ poller_output_remainder.patch | 46 ------ snmpwalk_fix.patch | 15 ++ thumbnail_graphs_not_working.patch | 20 +++ tree_console_missing_hosts.patch | 20 +++ 14 files changed, 129 insertions(+), 499 deletions(-) delete mode 100644 dec06-vulnerability-poller-0.8.6i.patch delete mode 100644 dec06-vulnerability-scripts-0.8.6i.patch delete mode 100644 fix_search_session_clear_issue.patch delete mode 100644 fix_sql_syntax_related_to_default_rra_id.patch create mode 100644 graph_debug_lockup_fix.patch delete mode 100644 import_template_argument_space_removal.patch delete mode 100644 mysql_5x_strict.patch delete mode 100644 nth_percentile_empty_return_set_issue.patch create mode 100644 ping_php_version4_snmpgetnext.patch delete mode 100644 poller_output_remainder.patch create mode 100644 snmpwalk_fix.patch create mode 100644 thumbnail_graphs_not_working.patch create mode 100644 tree_console_missing_hosts.patch diff --git a/cacti.spec b/cacti.spec index 8c0121b..de88c3c 100644 --- a/cacti.spec +++ b/cacti.spec @@ -1,6 +1,6 @@ Name: cacti Version: 0.8.6j -Release: 8%{?dist} +Release: 9%{?dist} Summary: An rrd based graphing tool Group: Applications/System @@ -13,6 +13,11 @@ Source3: cacti.README.Fedora Patch1: cacti-0.8.6h-dbcfg.patch Patch2: CVE-2007-3112.patch +Patch3: ping_php_version4_snmpgetnext.patch +Patch4: tree_console_missing_hosts.patch +Patch5: thumbnail_graphs_not_working.patch +Patch6: graph_debug_lockup_fix.patch +Patch7: snmpwalk_fix.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) @@ -34,6 +39,11 @@ used to creating traffic graphs with MRTG. %setup -q %patch1 -p0 %patch2 -p3 +%patch3 -p1 +%patch4 -p1 +%patch5 -p1 +%patch6 -p1 +%patch7 -p1 echo "#*/5 * * * * cacti %{_bindir}/php %{_datadir}/%{name}/poller.php > /dev/null 2>&1" >cacti.cron @@ -105,6 +115,9 @@ fi %attr(0644,root,root) %{_localstatedir}/lib/%{name}/lib %changelog +* Fri Sep 21 2007 Mike McGrath - 0.8.6j-9 +- Added rest of official patches + * Fri Sep 14 2007 Mike McGrath - 0.8.6j-8 - Fix for CVE-2007-3112 bz#243592 diff --git a/dec06-vulnerability-poller-0.8.6i.patch b/dec06-vulnerability-poller-0.8.6i.patch deleted file mode 100644 index f19c555..0000000 --- a/dec06-vulnerability-poller-0.8.6i.patch +++ /dev/null @@ -1,137 +0,0 @@ -diff -ruBbd cacti-0.8.6i/cmd.php cacti-0.8.6i-patch/cmd.php ---- cacti-0.8.6i/cmd.php 2006-10-09 00:06:00.000000000 -0400 -+++ cacti-0.8.6i-patch/cmd.php 2007-01-01 12:27:15.328125000 -0500 -@@ -26,7 +26,7 @@ - */ - - /* do NOT run this script through a web browser */ --if (!isset($_SERVER["argv"][0])) { -+if (!isset($_SERVER["argv"][0]) || isset($_SERVER['REQUEST_METHOD']) || isset($_SERVER['REMOTE_ADDR'])) { - die("
This script is only meant to run at the command line."); - } - -@@ -70,6 +71,10 @@ - $print_data_to_stdout = false; - if ($_SERVER["argc"] == "3") { - if ($_SERVER["argv"][1] <= $_SERVER["argv"][2]) { -+ /* address potential exploits */ -+ input_validate_input_number($_SERVER["argv"][1]); -+ input_validate_input_number($_SERVER["argv"][2]); -+ - $hosts = db_fetch_assoc("select * from host where (disabled = '' and " . - "id >= " . - $_SERVER["argv"][1] . -diff -ruBbd cacti-0.8.6i/copy_cacti_user.php cacti-0.8.6i-patch/copy_cacti_user.php ---- cacti-0.8.6i/copy_cacti_user.php 2006-10-09 00:06:00.000000000 -0400 -+++ cacti-0.8.6i-patch/copy_cacti_user.php 2007-01-01 12:27:15.312500000 -0500 -@@ -25,9 +25,10 @@ - */ - - /* do NOT run this script through a web browser */ --if (! isset($_SERVER["argv"][0])) { -- die("This script is only meant to run at the command line.\n"); -+if (!isset($_SERVER["argv"][0]) || isset($_SERVER['REQUEST_METHOD']) || isset($_SERVER['REMOTE_ADDR'])) { -+ die("
This script is only meant to run at the command line."); - } -+ - if (empty($_SERVER["argv"][2])) { - die("\nSyntax:\n php copy_cacti_user.php