Commented out the call to Net::SMTP's verify() method and replaced it with a generic regexp sanity check. It appears that VRFY is not correctly implemented on all servers. (I may be mistaken on this; it might just be a bug somewhere in the PLIF code that is messing something up, but I couldn't find it if so.)

git-svn-id: svn://10.0.0.236/trunk@113407 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
ian%hixie.ch 2002-02-01 06:38:55 +00:00
parent d20cb76545
commit 78a5b28737

View File

@ -89,9 +89,12 @@ sub output {
sub checkAddress {
my $self = shift;
my($app, $username) = @_;
$self->assert(defined($self->handle), 1, 'No SMTP handle, can\'t check address');
my $result = $self->handle->verify($username);
return $result;
return (defined($username) and $username =~ m/^[^@\s]+@[^@\s]+\.[^@.\s]+$/os);
# XXX this doesn't seem to be working:
# $self->assert(defined($self->handle), 1, 'No SMTP handle, can\'t check address');
# $self->assert(defined($username), 1, 'Internal error: no username passed to checkAddress');
# my $result = $self->handle->verify($username);
# return $result;
}
sub DESTROY {