Great Circle Associates Majordomo-Workers
(April 2000)
 

Indexed By Date: [Previous] [Next] Indexed By Thread: [Previous] [Next]

Subject: Re: majordomo.pl address matching
From: Dave Wolfe <dwolfe @ lists . linuxppc . org>
Date: Sun, 23 Apr 2000 22:31:32 -0500
To: relph @ sgi . com
Cc: majordomo-workers @ GreatCircle . COM, majordomo-patches @ cloud . ccsf . cc . ca . us
In-reply-to: <200004231953.MAA87125@mando.engr.sgi.com>; from John Relph on Sun, Apr 23, 2000 at 12:53:21PM -0700
References: <200004231953.MAA87125@mando.engr.sgi.com>

[ John Relph writes: ]
> 
> This patch tries to do better checking to see if two email addresses
> match because they are on different machines in the same domain.  For
> example, as in the example in majordomo.pl, <foo@baz.bax.edu> is
> considered to match <foo@bax.edu>.
> 
> This patch increases the debugging output as well as doing a slightly
> better job of checking.
> 
> Any comments?

Yes, can you please use unified diff format so the old and new lines are
together? For Gnu diff that's the -u option.

I can't tell if your changes even do the same thing, but it appears that
they attempt to deal w/ unqualified addresses (no domain). Don't know
about stock 1.94.5, but other patches disallow unqualified addresses.
Your best bet is to fix your MTA so that you never get unqualified
addresses. It prevents a lot of other problems that way.

> !     local(@addr1,@addr2);
> !     @addr1 = split(/\@/, $a1[0]);
> !     @addr2 = split(/\@/, $a2[0]);
> ! 
> !     if ($partial == 2) {      # see if addresses are

I can't tell what the alternative to the 'if' is now, but it seems odd
to move the splits out of the 'if' given that the only place they were
used was inside it.

> !     if ($#addr1 == 1) {
> !       print STDERR "addr_match: comparing $addr1[1] against $main'whereami\n" if $DEBUG;
> !     }
> !     if ($#addr2 == 1) {
> !       print STDERR "addr_match: comparing $addr2[1] against $main'whereami\n" if $DEBUG;
> !     }

ICK! Please combine the conditions:

    print STDERR "addr_match: comparing $addr1[1] against $main'whereami\n"
	if $DEBUG && $#addr1 == 1;

    print STDERR "addr_match: comparing $addr2[1] against $main'whereami\n"
	if $DEBUG && $#addr2 == 1;

-- 
 Dave Wolfe



References:
Indexed By Date Previous: Re: Outlook and Majordomo help
From: relph@mando.engr.sgi.com (John Relph)
Next: Re: majordomo.pl address matching
From: relph@mando.engr.sgi.com (John Relph)
Indexed By Thread Previous: majordomo.pl address matching
From: John Relph <relph@cthulhu.engr.sgi.com>
Next: Re: majordomo.pl address matching
From: relph@mando.engr.sgi.com (John Relph)

Google
 
Search Internet Search www.greatcircle.com