Verify that email domain exists(验证电子邮件域是否存在)
问题描述
是否有人在验证步骤中检查电子邮件地址的域?例如.如果用户指定 blah@gmail.com 作为其地址,请确认 gmail.com 存在.
Does anyone check the domain of an email address as part of their verification steps? eg. Confirm that gmail.com exists if the user specified blah@gmail.com as their address.
我应该注意,在我的 web 应用中,现有用户可以将邀请转发给他们的朋友.我根本不需要验证这些邀请.相反,我只是想警告我的用户,如果拼写错误等可能会向错误的人发送邀请.这还值得吗?
I should note that in my webapp an existing user can forward invites to their friends. I have no need to verify those invites at all. Rather, I just want to warn my user if a typo etc. may be sending an invite to the wrong person. Is this even worthwhile to do?
推荐答案
您可以在 上进行 dns 查找mx 记录.这是代码项目中的一个示例:
http://www.codeproject.com/KB/IP/dnslookupdotnet.aspx
You could do a dns lookup on the mx record. Here's an example at Code Project:
http://www.codeproject.com/KB/IP/dnslookupdotnet.aspx
这应该可以回答您的问题,但作为旁注,我同意@Franci 的观点,即发送验证消息的旧备用方式更好.如果有人做了所有其他正确的事情来欺骗您的验证,那么您在检查域时真的不会花太多钱.
That should answer your question as asked, but as a side note I agree with @Franci that the old standby of sending a verification message is better. If someone's done everything else right to fool your validation, you're really not buying much in also checking the domain.
这篇关于验证电子邮件域是否存在的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!
本文标题为:验证电子邮件域是否存在
基础教程推荐
- 有没有办法忽略 2GB 文件上传的 maxRequestLength 限制? 2022-01-01
- c# Math.Sqrt 实现 2022-01-01
- 将 XML 转换为通用列表 2022-01-01
- 为什么Flurl.Http DownloadFileAsync/Http客户端GetAsync需要 2022-09-30
- SSE 浮点算术是否可重现? 2022-01-01
- rabbitmq 的 REST API 2022-01-01
- 将 Office 安装到 Windows 容器 (servercore:ltsc2019) 失败,错误代码为 17002 2022-01-01
- 如何在 IDE 中获取 Xamarin Studio C# 输出? 2022-01-01
- MS Visual Studio .NET 的替代品 2022-01-01
- 如何激活MC67中的红灯 2022-01-01