compare email domain to website domain [closed]
Want to improve this question? Update the question so it's on-topic for Stack Overflow.
Closed 12 years ago.
Improve this questionIs it possible to register an email domain identical w开发者_高级运维ith the domain of a website you don't own? For instance myname@cnn.com.
I'm creating an app which compares your email to a domain name so I'm trying to determine if there are any loopholes in terms of verifying if you own a site based on your email.
No loopholes. Email is routed based on the DNS, and purchasing a domain name gives you control over every DNS entry that's a child to the domain. This includes the A entries that point to IP addresses, and the MX entries that specify mailing servers.
Just to clarify the question, how would you like to treat gmail or yahoo email addresses? Are you trying to verify that the user of the email address is the domain's registering party?
At any rate, the easiest way to verify domain control is to request the potential user add a tag like...
<meta name="(whatever)" content="(unique assigned hash)" />
... to the head in the index page of their site. Then get_file_contents()
, parse and compare the values.
精彩评论