[Greylist-users] network-enabled milter?
Deke Clinger
dclinger at qualcomm.com
Mon Jul 14 00:22:35 PDT 2003
Looks good. I like the reverse-whitelisting idea.
-Deke
On Mon, 14 Jul 2003, Evan Harris wrote:
>
> Thanks for the suggestion. Check out the latest checkin to CVS.
>
> Evan
>
>
> On Fri, 11 Jul 2003, Deke Clinger wrote:
>
> > Greetings,
> >
> > I'm trying out greylisting here starting today and wanted to offer a
> > suggestion that might be helpful at some sites. Currently relaydelay.pl uses
> > the Sendmail::Milter auto_setconn call to configure the milter listener.
> > Unfortunately this method doesn't support remote milters that are accessed
> > over the network.
> >
> > http://search.cpan.org/author/CYING/Sendmail-Milter-0.18/Milter.pm says:
> >
> >
> > auto_setconn NAME [, SENDMAIL_CF_FILENAME]
> >
> > This function automatically sets the connection information by parsing the
> > sendmail .cf file for the appropriate X line containing the connection
> > information for the NAME mail filter and calling setconn if it was
> > successful. It is provided as a helper function and does not exist in the
> > current Milter library.
> >
> > Note: This connection information isn't useful for implementing a Milter that
> > resides on a machine that is remote to the machine running sendmail. In those
> > cases, you will want to set the connection information manually with setconn.
> >
> >
> > I've defined the $conn variable at the top of relaydelay.pl, commented the
> > call to auto_setconn and changed the usage accordingly (diff at the end of
> > this message). This change allows relaydelay to run configured for network use
> > (inet:3005 at warlock.qualcomm.com). It shouldn't break local sockets, either. Is
> > anyone else doing something like this?
> >
> > So far (5-odd hours in, 47k+ rows in relaytofrom) everything appears to be
> > working properly. I've tested a single message (same triplet) against two mail
> > servers talking to the one milter and got the results I expected. I'm going to
> > post another message with some errors I'm seeing (with $verbose and -w on) but
> > so far everything looks pretty solid.
> >
> > Thanks for reading.
> >
> > Deke Clinger
> > Postmaster
> > Qualcomm Incorporated
> > San Diego, CA
> >
> >
> > ------------------------------diff starts here------------------------------
> >
> > 1c1
> > < #!/usr/bin/perl
> > ---
> > > #!/prj/postmaster/greylist/ActivePerl-5.8/bin/perl -w
> > 48d47
> > < my $config_file = "/etc/mail/relaydelay.conf";
> > 49a49
> > > my $config_file = "/prj/postmaster/greylist/relaydelay.conf";
> > 50a51
> > >
> > 57c58
> > < my $verbose = 1;
> > ---
> > > my $verbose = 0;
> > 58a60,62
> > > # Connection information
> > > my $conn="inet:3005\@warlock.qualcomm.com";
> > >
> > 844,847c848,851
> > < if (scalar(@ARGV) < 2) {
> > < print "Usage: perl $0 <name_of_filter> <path_to_sendmail.cf>\n";
> > < exit;
> > < }
> > ---
> > > if (scalar(@ARGV) < 1) {
> > > print "Usage: perl $0 <name_of_filter>\n";
> > > exit;
> > > }
> > 849c853
> > < my $conn = Sendmail::Milter::auto_getconn($ARGV[0], $ARGV[1]);
> > ---
> > > print "Connection: $conn\n";
> > 851,852d854
> > < print "Found connection info for '$ARGV[0]': $conn\n";
> > <
> > 867,869c869,891
> > < if (not Sendmail::Milter::auto_setconn($ARGV[0], $ARGV[1])) {
> > < print "Failed to detect connection information.\n";
> > < exit;
> > ---
> > > ## from http://search.cpan.org/author/CYING/Sendmail-Milter-0.18/Milter.pm:
> > > ##
> > > ## auto_setconn NAME [, SENDMAIL_CF_FILENAME]
> > > ##
> > > ## This function automatically sets the connection information by parsing
> > > ## the sendmail .cf file for the appropriate X line containing the
> > > ## connection information for the NAME mail filter and calling setconn if
> > > ## it was successful. It is provided as a helper function and does not
> > > ## exist in the current Milter library.
> > > ##
> > > ## Note: This connection information isn't useful for implementing a
> > > ## Milter that resides on a machine that is remote to the machine running
> > > ## sendmail. In those cases, you will want to set the connection
> > > ## information manually with setconn.
> > >
> > > # if (not Sendmail::Milter::auto_setconn($ARGV[0], $ARGV[1])) {
> > > # print "Failed to detect connection information.\n";
> > > # exit;
> > > # }
> > >
> > > if (not Sendmail::Milter::setconn("$conn")) {
> > > print "Failed to set up connection: $?\n";
> > > exit;
> >
> > _______________________________________________
> > Greylist-users mailing list
> > Greylist-users at lists.puremagic.com
> > http://lists.puremagic.com/cgi-bin/mailman/listinfo/greylist-users
> >
>
> _______________________________________________
> Greylist-users mailing list
> Greylist-users at lists.puremagic.com
> http://lists.puremagic.com/cgi-bin/mailman/listinfo/greylist-users
>
More information about the Greylist-users
mailing list