On 2 Feb 1997, Jason L Tibbitts III wrote:
> BR> If it fails, then it's a bad addr
>
> BR> if ($email =~ /(@.*@)|(\.\.)/ ||
> BR> $email !~ /^.+\@[a-zA-Z0-9\-_\.]+\.[a-zA-Z0-9]{2,3}$/)
>
> First off, I'll give you the benefit of the doubt and assume you mean for
> this to apply to a mailbox specifier and not a fully commented address.
Yes, that's correct.
> Even so, this complains about some perfectly legal addresses, anything with
> more than one `@' in it, like, say,
>
> "tibbs@home"@hpc.uh.edu
I don't have too many of these, do you?
All of what you'll say below is very true, in that this uses a "deny all,
allow . . ." method.
But right now our current checking procedures aren't very good, which is
what I'm really getting at.
The checking procedure I've posted let's the most common addresses
through. It only works for full addresses, nothing unusual and they have
to be stripped.
It's by no means perfect code. Perhaps the allow all then deny is better,
but it needs to be worked on. Maybe we shoudl specify what we wanted
excluded?
-------------------------------------------------------------------------
| Brock Rozen | brozen@webdreams.com | http://www.webdreams.com/~brozen |
-------------------------------------------------------------------------
Follow-Ups:
References:
|
|