--- a/exiacl.pl Fri Aug 19 13:10:19 2005 +0000
+++ b/exiacl.pl Fri Aug 19 13:22:47 2005 +0000
@@ -20,6 +20,8 @@
--exim=s exim binary [!$Cf->exim!]
--config=s exim config file [!$Cf->config!]
+
+ --[no]callout [!$Cf->callout!]
$Id$
$URL$
@@ -63,6 +65,8 @@
config => { ARGS => "=s", DEFAULT => $ENV{EXIM_CONF} || "/etc/exim/exim.conf.t" ,
ALIAS => "C" },
+
+ callout => { ARGS => "!", DEFAULT => 1 },
help => { ARGS => "!" },
);
@@ -81,12 +85,6 @@
unless $Cf->Helo;
$Cf->dst(addr(HOSTNAME)) unless $Cf->dst;
- $@ = "";
- foreach (qw/from to src dst/) {
- $Cf->get($_) or $@ = join " ", $@, $_;
- }
-
- die ME.": Missing values: $@\n" if $@;
MAIN: {
@@ -96,7 +94,7 @@
my @cmd = ($Cf->exim,
-C => $Cf->config,
-oMi => addr($Cf->dst),
- -bhc => addr($Cf->src),
+ ($Cf->callout? "-bhc" : "-bh" ) => addr($Cf->src),
@ARGV); # remaining args are exim native
if ($Cf->help) {
@@ -104,6 +102,12 @@
print; exit;
}
+ $@ = "";
+ foreach (qw/from to src dst/) {
+ $Cf->get($_) or $@ = join " ", $@, $_;
+ }
+ die ME.": Missing values: $@\n" if $@;
+
my $s = new IO::Select;
print "**> @cmd\n";