aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorlpsolit%gmail.com <>2005-11-22 03:06:15 +0000
committerlpsolit%gmail.com <>2005-11-22 03:06:15 +0000
commit7a3c2eb8b860cf888bd379fd3c997e8fdacbd8e3 (patch)
tree857afdd1e41840d7ec4d935bd3886088b31f7ec0 /sanitycheck.cgi
parentBug 312441: relogin.cgi allows you to impersonate user accounts you are not a... (diff)
downloadbugzilla-7a3c2eb8b860cf888bd379fd3c997e8fdacbd8e3.tar.gz
bugzilla-7a3c2eb8b860cf888bd379fd3c997e8fdacbd8e3.tar.bz2
bugzilla-7a3c2eb8b860cf888bd379fd3c997e8fdacbd8e3.zip
Bug 95799: sanitycheck.cgi should do email checks using Util::validate_email_syntax() - Patch by Frédéric Buclin <LpSolit@gmail.com> r=wicked a=justdave
Diffstat (limited to 'sanitycheck.cgi')
-rwxr-xr-xsanitycheck.cgi7
1 files changed, 3 insertions, 4 deletions
diff --git a/sanitycheck.cgi b/sanitycheck.cgi
index 7520430a2..1f3f27ddd 100755
--- a/sanitycheck.cgi
+++ b/sanitycheck.cgi
@@ -29,6 +29,7 @@ use lib qw(.);
require "globals.pl";
use Bugzilla::Constants;
+use Bugzilla::Util;
use Bugzilla::User;
###########################################################################
@@ -500,13 +501,11 @@ DoubleCrossCheck("milestones", "product_id", "value",
Status("Checking profile logins");
-my $emailregexp = Param("emailregexp");
SendSQL("SELECT userid, login_name FROM profiles");
while (my ($id,$email) = (FetchSQLData())) {
- unless ($email =~ m/$emailregexp/) {
- Alert "Bad profile email address, id=$id, &lt;$email&gt;."
- }
+ validate_email_syntax($email)
+ || Alert "Bad profile email address, id=$id, &lt;$email&gt;.";
}
###########################################################################