From 23baa90a7216f9159ca1569554bea064ef28a726 Mon Sep 17 00:00:00 2001 From: marcelloc Date: Tue, 15 Nov 2011 01:55:13 -0200 Subject: postfix - version 2.2 relased + widget --- config/postfix/postfix.php | 2 +- config/postfix/postfix.widget.php | 117 ++++++++++++++++++++++++++++++++++++++ config/postfix/postfix.xml | 6 +- config/postfix/postfix_search.php | 17 +++++- pkg_config.8.xml | 5 +- pkg_config.8.xml.amd64 | 5 +- 6 files changed, 143 insertions(+), 9 deletions(-) create mode 100755 config/postfix/postfix.widget.php diff --git a/config/postfix/postfix.php b/config/postfix/postfix.php index 992c82c2..d50fd326 100644 --- a/config/postfix/postfix.php +++ b/config/postfix/postfix.php @@ -268,7 +268,7 @@ if ($_REQUEST['files']!= ""){ $stm_fetch=array(); $total_result=0; foreach ($files as $postfix_db) - if (file_exists($postfix_dir.'/'.$postfix_db)){ + if (file_exists($postfix_dir.'/'.$postfix_db)){ $last_next=""; $dbhandle = sqlite_open($postfix_dir.'/'.$postfix_db, 0666, $error); $stm='select * from '.$queue; diff --git a/config/postfix/postfix.widget.php b/config/postfix/postfix.widget.php new file mode 100755 index 00000000..dd43afa4 --- /dev/null +++ b/config/postfix/postfix.widget.php @@ -0,0 +1,117 @@ +"; + echo" "; +} +function close_table(){ + echo" "; + echo""; + +} + +$pfb_table=array(); +$img['Sick']=""; +$img['Healthy']=""; + + +#var_dump($pfb_table); +#exit; +?>
-3; $z--){ + +if ($z==0) + $postfix_db=date("Y-m-d"); +else + $postfix_db=date("Y-m-d",strtotime("$z day",$curr_time)); + +if (file_exists($postfix_dir.'/'.$postfix_db.".db")){ + $dbhandle = sqlite_open($postfix_dir.'/'.$postfix_db.".db", 0666, $error); + #noqueue + open_table(); + print "
$postfix_db
"; + close_table(); + open_table(); + $stm="select count(*) as total from mail_noqueue"; + $result = sqlite_query($dbhandle, $stm); + $row_noqueue = sqlite_fetch_array($result, SQLITE_ASSOC); + + #queue + $result = sqlite_query($dbhandle, $stm); + $stm="select status,count(*) as total from mail_queue group by status order by status"; + $result = sqlite_query($dbhandle, $stm); + $reader=""; + $count=""; + for ($i = 1; $i <= 15; $i++) { + $row = sqlite_fetch_array($result, SQLITE_ASSOC); + if (is_array($row)){ + if (preg_match("/\w+/",$row['status'])){ + $reader.="".ucfirst($row['status'])."\n"; + if ($row['status']=="reject") + $row['total']=+$row_noqueue['total']; + $count.="".$row['total']."\n"; + } + } + } + print "".$reader.""; + print "".$count.""; + close_table(); + echo "
"; + $result = sqlite_query($dbhandle, $stm); + sqlite_close($dbhandle); +} +} +echo" "; +echo"
"; + +?> + diff --git a/config/postfix/postfix.xml b/config/postfix/postfix.xml index 06caf4ec..aaa279f7 100644 --- a/config/postfix/postfix.xml +++ b/config/postfix/postfix.xml @@ -109,7 +109,11 @@ /usr/local/www/ 0755 - + + http://www.pfsense.org/packages/config/postfix/postfix.widget.php + /usr/local/www/widget/widget/ + 0755 + http://www.pfsense.org/packages/config/postfix/adexport.pl /usr/local/etc/postfix/ diff --git a/config/postfix/postfix_search.php b/config/postfix/postfix_search.php index f347dbf0..d11505d4 100755 --- a/config/postfix/postfix_search.php +++ b/config/postfix/postfix_search.php @@ -91,7 +91,7 @@ include("head.inc"); -
+
@@ -168,7 +168,7 @@ include("head.inc"); - " onclick="getsearch_results(true)"> + " onclick="getsearch_results(true)"> @@ -197,12 +197,20 @@ function loopSelected(id) } function getsearch_results() { - scroll(0,0); var $new_from=$('from').value.replace("\n", "','"); var $new_to=$('to').value.replace("\n", "','"); var $new_sid=$('sid').value.replace("\n", "','"); var $files=loopSelected('Select1'); var $fields=loopSelected('fields'); + if ($files ==""){ + alert ("Please select at least one file."); + } + if ($fields ==""){ + alert ("Please select at least one message field to display results."); + } + else{ + $('search').value="Searching..."; + $('search_results').innerHTML=""; var $queuetype=$('queuetype').options[$('queuetype').selectedIndex].text; var $queuemax=$('queuemax').options[$('queuemax').selectedIndex].text; var $pars="from="+$new_from+"&to="+$new_to+"&sid="+$new_sid+"&limit="+$queuemax+"&fields="+$fields+"&status="+$('status').value; @@ -217,8 +225,11 @@ function getsearch_results() { onComplete: activitycallback_postfix_search }); } + } function activitycallback_postfix_search(transport) { $('search_results').innerHTML = transport.responseText; + scroll(0,900); + $('search').value="Search"; } diff --git a/pkg_config.8.xml b/pkg_config.8.xml index 1ec6820f..5eb664fd 100644 --- a/pkg_config.8.xml +++ b/pkg_config.8.xml @@ -59,7 +59,7 @@ countryblock.xml - pfBlocker-dev + pfBlocker Assign many IP urls lists from sites like I-blocklist to a single alias and then choose rule action to take.
@@ -390,9 +390,10 @@ Postfix can also detect zombies, check RBLS, SPF, seach ldap for valid recipients and use third part antispam engines like policyd and mailscanner for better antispam solution.]]>
Services http://www.pfsense.com/packages/config/postfix/postfix.xml + http://forum.pfsense.org/index.php/topic,40622.0.html http://files.pfsense.org/packages/8/All/ postfix-2.8.5,1.tbz - 2.8.5,1 pkg v.2.1 + 2.8.5,1 pkg v.2.2 RC1 2.0 postfix.xml diff --git a/pkg_config.8.xml.amd64 b/pkg_config.8.xml.amd64 index 2e45d0ae..4d3702d7 100644 --- a/pkg_config.8.xml.amd64 +++ b/pkg_config.8.xml.amd64 @@ -134,7 +134,7 @@ countryblock.xml
- pfBlocker-dev + pfBlocker Assign many IP urls lists from sites like I-blocklist to a single alias and then choose rule action to take.
@@ -471,11 +471,12 @@ It can do first and second line antispam combat before sending incoming mail to local mail servers.
Postfix can also detect zombies, check RBLS, SPF, seach ldap for valid recipients and use third part antispam engines like policyd and mailscanner for better antispam solution.]]>
Services + http://forum.pfsense.org/index.php/topic,40622.0.html http://www.pfsense.com/packages/config/postfix/postfix.xml http://files.pfsense.org/packages/amd64/8/All/ postfix-2.8.5,1.tbz spamd-4.9.1-amd64.pbi - 2.8.5,1 pkg v.2.1 + 2.8.5,1 pkg v.2.2 RC1 2.0 postfix.xml -- cgit v1.2.3