Re: [Boston.pm] Email filtering...

2003-02-12 Thread Chris Devers
On Tue, 11 Feb 2003, John Tobey wrote: > On Tue, Feb 11, 2003 at 06:26:56PM -0500, Chris Devers wrote: > > > > The short of it is, if you can get away with it, to *never* use these > > anywhere in your programs (and by proxy to that, don't use modules > > that use these constructs, such as

Re: [Boston.pm] Email filtering...

2003-02-11 Thread John Tobey
On Tue, Feb 11, 2003 at 06:26:56PM -0500, Chris Devers wrote: > > The short of it is, if you can get away with it, to *never* use these > anywhere in your programs (and by proxy to that, don't use modules that > use these constructs, such as Carp.pm or English.pm). This is based on the English

Re: [Boston.pm] Email filtering...

2003-02-11 Thread John Tobey
On Tue, Feb 11, 2003 at 06:27:15PM -0500, Uri Guttman wrote: > > "BR" == Bob Rogers <[EMAIL PROTECTED]> writes: > > > BR>I would like to point out that your code can be improved by replacing > BR>uses of $& and $` with parentheses in the regexes followed by $1 and > BR>$2.

Re: [Boston.pm] Email filtering...

2003-02-11 Thread Uri Guttman
> "BR" == Bob Rogers <[EMAIL PROTECTED]> writes: BR>I would like to point out that your code can be improved by replacing BR>uses of $& and $` with parentheses in the regexes followed by $1 and BR>$2. This is from the Devel::SawAmpersand doc . . . BR> I was unaware of

Re: [Boston.pm] Email filtering...

2003-02-11 Thread Chris Devers
On Tue, 11 Feb 2003, Bob Rogers wrote: >From: John Tobey <[EMAIL PROTECTED]> > >I would like to point out that your code can be improved by replacing >uses of $& and $` with parentheses in the regexes followed by $1 and >$2. This is from the Devel::SawAmpersand doc . . . > > I

Re: [Boston.pm] Email filtering...

2003-02-11 Thread John Tobey
On Tue, Feb 11, 2003 at 03:16:32PM -0500, Bob Rogers wrote: >Also, I've attached a code fragment I wrote to validate email address > syntax. Thanks very much for the code sample and link to Bernstein's great RFC 822 info site. I would like to point out that your code can be improved by

RE: [Boston.pm] Email filtering...

2003-02-11 Thread Wizard
Sorry I took so long to get back, I was at an interview > > I don't see how '*@*.aol.*' can match '[EMAIL PROTECTED]'. > > How do you account for the first '.' in the match expression? > > For that matter, can a regular expression validly begin with "*" at all? > What does that mean? > > And why

RE: [Boston.pm] Email filtering...

2003-02-11 Thread Bob Rogers
From: "Wizard" <[EMAIL PROTECTED]> Date: Tue, 11 Feb 2003 10:35:11 -0500 > Here's another one: future proofing. The two or three character TLD > constraint you see today isn't necessary, and maybe in the future we'll > see longer addresses ([EMAIL PROTECTED]). Or Rendezvous >

RE: [Boston.pm] Email filtering...

2003-02-11 Thread Wizard
> I don't see how '*@*.aol.*' can match '[EMAIL PROTECTED]'. > How do you account for the first '.' in the match expression? By splitting it into @cnames, $domain, $tld and $cc, so that (pseudocode): $user_cc eq $cc? if $cc $user_tld eq $tld? $user_domain eq $domain? and foreach( @user_cnames )

Re: [Boston.pm] Email filtering...

2003-02-11 Thread darren chamberlain
* Ron Newman [2003-02-11 12:42]: > On Tuesday, February 11, 2003, at 12:23 PM, Gyepi SAM wrote: > > I don't see how '*@*.aol.*' can match '[EMAIL PROTECTED]'. How do you > > account for the first '.' in the match expression? > > For that matter, can a regular expression validly begin with "*"

Re: [Boston.pm] Email filtering...

2003-02-11 Thread Ron Newman
On Tuesday, February 11, 2003, at 12:23 PM, Gyepi SAM wrote: I don't see how '*@*.aol.*' can match '[EMAIL PROTECTED]'. How do you account for the first '.' in the match expression? For that matter, can a regular expression validly begin with "*" at all? What does that mean? And why would

Re: [Boston.pm] Email filtering...

2003-02-11 Thread Gyepi SAM
On Tue, Feb 11, 2003 at 11:10:51AM -0500, Wizard wrote: > Here's an example that I just sent to the NMS list: > > I want it to be universal. For instance, how would you parse this: > *@*.aol.* > > into: > [EMAIL PROTECTED] > [EMAIL PROTECTED] > and > [EMAIL PROTECTED] > > It should match the

Re: [Boston.pm] Email filtering...

2003-02-11 Thread Paul Makepeace
On Tue, Feb 11, 2003 at 11:12:28AM -0500, darren chamberlain wrote: > * Stephen Reppucci [2003-02-11 11:00]: > > Except for one thing: you'll want to swap those first two statements > > in the for loop -- otherwise you'll end up escaping your regex '.'s > > that replaced the wildcard '*'s... > >

RE: [Boston.pm] Email filtering...

2003-02-11 Thread Wizard
> Did you volunteer for this? Did anyone laugh when you spoke up? Just in my head. They're always laughing at me. What? I couldn't KILL HER... Grant M. (& Co.) ___ Boston-pm mailing list [EMAIL PROTECTED] http://mail.pm.org/mailman/listinfo/boston-pm

Re: [Boston.pm] Email filtering...

2003-02-11 Thread David Cantrell
On Tue, Feb 11, 2003 at 10:56:00AM -0500, Wizard wrote: > Yes, it's something very like that. I've already used it on IP address > filtering. What sort of address filtering are you doing? Take a look at Net::CIDR which is Really Useful when dealing with address ranges. -- Grand Inquisitor

Re: [Boston.pm] Email filtering...

2003-02-11 Thread Stephen Reppucci
On Tue, 11 Feb 2003, darren chamberlain wrote: > > *@aol.* > > *@*.parliment.uk > > fred@*.sourceforge.* > > etc. > > Hmm, nice: > > # Assume @addrs is the above list: > for (my $i = 0; $i < @addrs; $i++) { > $addrs[$i] =~ s/\*/.*/g; > $addrs[$i] =~ s/\./\\./g; > $addrs[$i]

Re: [Boston.pm] Email filtering...

2003-02-11 Thread Simon Wilcox
On Tue, 2003-02-11 at 15:49, darren chamberlain wrote: > * Simon Wilcox [2003-02-11 10:47]: > > We can actually use CPAN modules (as long as they are pure perl) but > > we need to distribute them as part of the code. > > Well, then, bundle in Email::Valid, because it's wonderful, and is (more >

RE: [Boston.pm] Email filtering...

2003-02-11 Thread Hanes, Philipp
> > Here's another one: future proofing. The two or three character TLD > > constraint you see today isn't necessary, and maybe in the > future we'll > > see longer addresses ([EMAIL PROTECTED]). Or > Rendezvous > > might catch on, and addresses of the form > [EMAIL PROTECTED] might become > >

RE: [Boston.pm] Email filtering...

2003-02-11 Thread Wizard
> dude- the nightmare is only beginning ... Would that be "Nightmare on /usr/bin/elm Street"? ;-) Grant M. ___ Boston-pm mailing list [EMAIL PROTECTED] http://mail.pm.org/mailman/listinfo/boston-pm

Re: [Boston.pm] Email filtering...

2003-02-11 Thread darren chamberlain
* Simon Wilcox [2003-02-11 10:47]: > We can actually use CPAN modules (as long as they are pure perl) but > we need to distribute them as part of the code. Well, then, bundle in Email::Valid, because it's wonderful, and is (more or less) the definitive way to do what it does. (darren) --

Re: [Boston.pm] Email filtering...

2003-02-11 Thread David Cantrell
On Tue, Feb 11, 2003 at 10:28:17AM -0500, Wizard wrote: > David Cantrell wrote: > > Yes, anything in .us. > Meaning, CNAMES*.DOAMIN.us? Or CNAMES*.DOMAIN.TLD.us? Or both? Oh .us is FUN. You have, IIRC: just_about_anything_the_crack_monkeys_can_think_of.state_abbr.us;

Re: [Boston.pm] Email filtering...

2003-02-11 Thread Simon Wilcox
On Tue, 2003-02-11 at 15:31, Ron Newman wrote: > > On Tuesday, February 11, 2003, at 10:04 AM, Wizard wrote: > > > >> i'd think there are several things on CPAN you can use. > > > > I Can't use any modules not in a standard 5.0004(?) distribution; the > > script > > is for NMS

RE: [Boston.pm] Email filtering...

2003-02-11 Thread Wizard
> Here's another one: future proofing. The two or three character TLD > constraint you see today isn't necessary, and maybe in the future we'll > see longer addresses ([EMAIL PROTECTED]). Or Rendezvous > might catch on, and addresses of the form [EMAIL PROTECTED] might become > common in some

Re: [Boston.pm] Email filtering...

2003-02-11 Thread darren chamberlain
* Wizard [2003-02-11 10:17]: > > Why not use Email::Valid? > > As I said in another email, this is for NMS, so I can't use anything that > doesn't come with the standard 5.0004(?) perl. Ah, I see. OK, then, I have a small module (Email.pm) that rips off from Email::Valid (I think, or it might

RE: [Boston.pm] Email filtering...

2003-02-11 Thread Wizard
> > 2.> Do email addresses ever have port numbers appended, like this: > > [EMAIL PROTECTED]:24 > > > > I don't think so. Which port would they use? The SMTP port? The POP3 > port? IMAP? Could you have the same email address with different > mailboxes if you used the IMAP vs POP3 port?

RE: [Boston.pm] Email filtering...

2003-02-11 Thread Wizard
> What's non-standard about it? (apart from the spelling) Sorry, "not-typical". > Indeed it's not typical, but it is standard in that it has all the right > records in all the right places like the DNS*. And yes, PLENTY of other > countries have longword.cc-style domains. France, for instance,

Re: [Boston.pm] Email filtering...

2003-02-11 Thread David Cantrell
On Tue, Feb 11, 2003 at 09:42:59AM -0500, Wizard wrote: > I'm writing a script to do email filtering, and I have some questions: > 1.> These are all valid email address: > [EMAIL PROTECTED] > [EMAIL PROTECTED] > [EMAIL PROTECTED] > [EMAIL PROTECTED] <- this is valid, but not standard What's