#! @PERL@ -wT -I@cgibin@ # List the messages in a user's log directory # --S-LICENSE-- # $Revision: 1.35 $ # @configure_input@ # This file must protected with an equivalent to httpd.conf lines # in the README file. use strict 'subs'; use POSIX qw(strftime); use common; my($msg_num, $msg, $msg_link, $date, $last_date, $from, $result, $subject); get_log_msgs($query{msg} || undef, 100); html_head("Messages Logged for $user at $hostname"); print "

"; print $#msgs_num >= 0 ? ($#msgs_num+1) : "No"; print " messages logged for $user at $hostname at "; print strftime "%x %X", localtime; print "

\n

\n

\n"; print $query{result} ? html_str_encode($query{result}) : " "; print "\n

\n"; common_buttons(); print "\n"; if ($#msgs_num >= 0) { print < EOF print_links(); for ($msg_num = $msg_last; $msg_num >= $msg_first; --$msg_num) { $msg = $msgs_num[$msg_num]; next if (!$msg); $date = $msgs_date{$msg}; if ($date =~ s/(.*) .*/$1/ && (!$last_date || $last_date ne $date)) { $from = !$last_date ? 'From' : ' '; $subject = !$last_date ? 'Subject' : ' '; $last_date = $date; if ($msg_part_num) { $date .= " part $msg_part_num"; $msg_part_num= 0; } print <
  $date $from   $subject EOF } $from = $msgs_from{$msg}; $from =~ s/"//g; $from =~ s/^\s*<(.*)>/$1/; $result = $msgs_result{$msg}; $result =~ s/:(.*)/:$1<\/span>/; $msg_link = "$list_msg_link${url_ques}msg=$msg\" name=$msg>"; print "
$msg_link"; print $msg_num+1; print "\n$msg_link$msgs_date{$msg}\n"; print <$from $result $msgs_subject{$msg} EOF } print_links(); print <

Grey greylist embargo OK-Grey greylist embargo ended
DCC bulk according to DCC OK-DCC not bulk according to DCC
Rep bulk DCC Reputation
MTA blacklisted by mail system MTA-OK whitelisted by mail system
BL blacklisted in whiteclnt files    WL whitelisted in whiteclnt files EOF my $args = "$DNSBL_ARGS $DCCM_ARGS $DCCIFD_ARGS"; if ($args =~ /-B/) { if ($args !~ /-B\s*set:group=\d+/i) { print <DNSBL  DNS blacklisted EOF } else { print <DNSBLn  DNS blacklisted EOF } } print <italic checks off
EOF } html_footer(); print "\n\n"; # re-enable mail notifications unlink("$user_dir/notify.marker", "$user_dir/notify.pending", "$user_dir/notify.block"); close(MARK) if (open(MARK, "> $user_dir/notify.marker")); sub print_links { my($msg_num); print "

\n"; print_bounded_link($#msgs_num+1, "Newest"); print_bounded_link($msg_day_last+1, "Next Day"); print_bounded_link($msg_newer, "Newer"); print_bounded_link($msg_first-1, "Older"); print_bounded_link($msg_day_first-1,"Previous Day"); print_bounded_link(0, "Oldest"); } sub print_bounded_link { my($msg_num, $name) = @_; my($msg, $val); # $name .= ':' . ($msg_num+1); $msg_num = 0 if ($msg_num < 0); $msg = $msgs_num[$msg_num]; $val = defined($msg) ? "${url_ques}msg=$msg" : ''; print " $list_log_link$val\">$name  \n"; }