[wp-trac] [WordPress Trac] #17433: localhost is not accepted as email domain

WordPress Trac wp-trac at lists.automattic.com
Thu Aug 11 21:08:22 UTC 2011


#17433: localhost is not accepted as email domain
--------------------------+------------------------------
 Reporter:  sanvila       |       Owner:
     Type:  defect (bug)  |      Status:  new
 Priority:  normal        |   Milestone:  Awaiting Review
Component:  Formatting    |     Version:  3.2
 Severity:  normal        |  Resolution:
 Keywords:  has-patch     |
--------------------------+------------------------------

Comment (by westi):

 Replying to [comment:5 kurtpayne]:
 > This patch will allow dotless e-mail domains as long as the server can
 resolve the domain via a DNS lookup.  It should allow "localhost" and
 other development domains, but prevent "fakedomain" (unless fakedomain
 resolves on your network).
 >
 > If DNS times out on an invalid dotless domain, there may be a delay of
 up to 2 seconds.  This should be encountered rarely, but, due to the
 stacking of sanitize_email() and is_email() may be encountered twice in a
 row.
 >
 > Thoughts about this approach?

 We don't want to add dns lookups to every call to is_email as it could
 slow down a site unnecessary and lead to other issues.

 In general we should probably consider moving all of our validation
 filtering like this to use the filter_var stuff in PHP 5.2 now it is
 available to us.

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/17433#comment:6>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list