- etwas mehr Doku
authorheiko
Thu, 12 Jul 2007 10:10:05 +0000
changeset 30 3d78db598b87
parent 29 edae3cb9aca3
child 31 399a7ca402a0
- etwas mehr Doku
Makefile
exiacl.man8
exiacl.pl
--- a/Makefile	Thu Jul 12 10:04:13 2007 +0000
+++ b/Makefile	Thu Jul 12 10:10:05 2007 +0000
@@ -3,7 +3,8 @@
 # $URL$
 
 SCRIPTS = exiacl
-CLEANFILES = exiacl
+MANPAGES = exiacl.8
+CLEANFILES = $(SCRIPTS) $(MANPAGES)
 p = exiacl
 
 prefix = /usr/local
@@ -23,7 +24,7 @@
 
 .PHONY: all install clean uninstall
 
-all:	$(SCRIPTS)
+all:	$(SCRIPTS) $(MANPAGES)
 
 install:    all
 	install -d $(bindir)
@@ -45,5 +46,8 @@
 	@cp -vf $< $@
 	@chmod -w+x $@
 
+%.8:	%.man8
+	pod2man --name $(basename $<) --section 8 --center "exim" $< >$@
+
 
 # vim:sts=4 sw=4 aw ai sm list:
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/exiacl.man8	Thu Jul 12 10:10:05 2007 +0000
@@ -0,0 +1,82 @@
+=head1 NAME
+
+exiacl - exim acl tester
+
+=head1 SYNOPSIS
+
+B<exiacl> [options] B<-f>|B<--from>=I<from> B<-t>|B<--to>=I<to[,...]> [-- I<<exim native options>>]
+
+=head1 DESCRIPTION
+
+This tools tests the exim acl, B<including> performing callouts. 
+
+=head1 OPTIONS
+
+=over
+
+=item B<-f>|B<--from> I<sender address>
+
+The mail address of the sender. (no default)
+
+=item B<-l>|B<--[no]log>
+
+Show the log output to stdout. (default: yes)
+
+=item B<-l>|B<--debug>=I<exim debug options>
+
+Call Exim with some debug options. (e.g. C<-d-all+route>).
+
+=item B<--Helo>=I<helo>
+
+Use the specified HELO when talking to Exim (default: current hostname)
+
+=item B<--From>=I<sender>
+
+The envelope-from for the SMTP dialog. (no default)
+
+=item B<--To>=I<recipient>[,I<recipient>...]
+
+The recipients address. You may use more than once addresse, if they're
+comma separated. (no default)
+
+=item B<--src>=I<src ip>
+
+The source IP address. (default: some random private address)
+
+=item B<--dst>=I<dst ip>
+
+The destination IP address. This you'll need if you've an Exim running
+on more then one interface. (default: IP of the current host)
+
+=item B<--au>=I<user>
+
+Username for authentication. (no default)
+
+=item B<--aa>=I<authenticator>
+
+The authenticator to be used (plain, ....). (no default)
+
+=item B<--exim>=I<exim binary>
+
+The path to the exim binary to be called. (default: exim, but see
+L<ENVIRONMENT> below)
+
+=item B<--config>=I<config file>
+
+The config file to be used. (default: /etc/exim/exim.conf, but see
+L<ENVIRONMENT> below).
+
+=item B<--[no]callout>
+
+Do callouts (not do not). (default: do callouts)
+
+=back
+
+=head1 ENVIRONMENT
+
+B<EXIM> is used to refer to the exim binary to be called. And
+B<EXIM_CONF> is the default configuration file.
+
+=head1 AUTHOR
+
+Heiko Schlittermann L<hs@schlittermann.de>
--- a/exiacl.pl	Thu Jul 12 10:04:13 2007 +0000
+++ b/exiacl.pl	Thu Jul 12 10:10:05 2007 +0000
@@ -10,11 +10,12 @@
 
     --from=s	from:			[!$Cf->from!]
     --to=s	to:			[!$Cf->to!]
+		(comma separated)
 
     --Helo=s	HELO	   		[!$Cf->Helo!]
     --From=s	MAIL FROM:		[!$Cf->From!]
     --To=s	RCPT TO: 		[!$Cf->To!]
-                (comman separated)
+                (comma separated)
 
     --src=s	src ip/name		[!$Cf->src!]
     --dst=s	dst ip/name		[!$Cf->dst!]
@@ -141,7 +142,7 @@
     write_exim $w, "MAIL FROM: ".$Cf->From."\n";
      read_exim $r;
 
-    foreach my $rcpt (split /\s*,\s*/, $Cf->to) {
+    foreach my $rcpt (split /\s*,\s*/, $Cf->To) {
 	write_exim $w, "RCPT TO: $rcpt\n";
 	 read_exim $r, "5";
     }