保护您的表单免受垃圾邮件发送者侵害的最简单方法是什么?

发布于 2024-09-09 03:45:29 字数 43 浏览 9 评论 0原文

阻止垃圾邮件发送者探查您的表单的最简单方法是什么(最好不阻止真正的用户)

Whats the easiest way of stopping spammers from probing your forms (preferably without deterring real users)

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(7

洒一地阳光 2024-09-16 03:45:29

一个非常简单的方法称为 蜜罐

  1. 您创建一个隐藏字段,用户可以使用无法填写。
  2. 如果您收到填写了该字段的表格,请将其丢弃。

您可以通过设置不显示来隐藏它,或者将 div 绝对定位在其他东西后面,或者完全在屏幕之外。

最好的部分是它根本不会影响您的常规用户。

A very simple method is known as the honeypot

  1. You create a hidden field that users can't fill out.
  2. If you recieve a form that has that field filled out, discard it.

You can hide it by setting display none, or absolutely positioning the div behind something else, or completely off screen.

The best part is that it does not affect your regular users at all.

三五鸿雁 2024-09-16 03:45:29

验证码。用户不再受它们困扰,他们已经习惯了它们。

http://www.captcha.net/captchas/

这似乎很容易设置验证码网站,我没用过,不过google上很早。

A captcha. Users aren't bothered by them anymore, they've gotten used to them.

http://www.captcha.net/captchas/

That seems like a good easy to set up captcha website, I've never used it, but it was early on google.

两人的回忆 2024-09-16 03:45:29

最简单的方法可能是添加一个具有常用名称的附加字段,例如“电话:”,然后将其设置为显示:无;并检查服务器端该值是否仍然为空。大多数垃圾邮件机器人(不是全部)都会被愚弄并填写该字段 - 因此您可以忽略他们的输入。

它并不完美,但它很“简单”,并且会阻止很多垃圾邮件。

如果失败的话,是的,验证码。

The simplest way may be adding an additional field with a commonly required name, like "Phone:" and then setting it to display:none; and checking whether the value is still blank on the server side. Most spam bots (not all) will be fooled and fill the field out - so you can ignore their input.

It's not perfect but it is "easy" and will stop a lot of the spam.

Failing that, yeah, Captcha.

笑着哭最痛 2024-09-16 03:45:29

我一直更喜欢隐藏的电子邮件字段与简单的逻辑问题相结合,例如“如果冰是冷的,火是:___”或“十二减二是__”。只需提出一系列问题,让机器人不断猜测即可。您甚至可以让它们变得幽默,让您的用户感到高兴。

http://textcaptcha.com/ 是一个很好的起点。他们甚至提供用于生成随机问题的网络服务。

验证码很棒,但在我看来,需要填写 PITA。即使是最流行的,也存在巨大的可访问性问题。我无法告诉你有多少次我不得不求助于音频样本(尽管拥有完美的视力)却发现音频更难破译。

I've always preferred a hidden email field combined with a simple logic question like "If ice is cold, fire is: ___" or "twelve minus two is __". Just make an array of questions to keep the bots guessing. You can even make them humorous to keep your users happy.

http://textcaptcha.com/ is a good place to start. They even offer a webservice for generating random questions.

CAPTCHAS are great but a PITA to fill out IMO. There are huge accessibility concerns with even the most popular ones. I can't tell you how many times I've had to resort to the audio sample (despite having perfect vision) only to find that the audio is even harder to decipher.

GRAY°灰色天空 2024-09-16 03:45:29

我不知道这是否足以阻止真正的用户,但一个易于解决的验证码应该可以解决问题。我不会太打扰用户,而且它会阻止自动填写表单的垃圾邮件发送者。

I don't know if this qualifies as deterring real users, but an easy to solve captcha should do the trick. I won't bother users very much, and it will stop auto-form-filling spammers.

北城挽邺 2024-09-16 03:45:29

完全自动化的公共图灵测试来区分计算机和人类(简而言之:验证码)非常棒。

我喜欢 recaptcha 项目的座右铭:停止垃圾邮件,读书。

Completely Automated Public Turing tests to tell Computers and Humans Apart (in short: captchas) are great.

I like the motto of the recaptcha project: Stop spam, read books.

〆凄凉。 2024-09-16 03:45:29

除非必要,否则不要使用验证码。大多数网站的重要性不足以浪费人们的时间和注意力。如果您想出售某些东西而不是提供免费服务,这一点尤其适用。

只需使您的表单变得非标准就足够了。除非您足够重要,足以吸引某人编写特定于您网站的代码,否则您可以通过添加一个标记为“请输入单词橙色”的字段来阻止所有通用垃圾邮件发送者。

如果您的规模足够大,可以成为目标,请开始实施行为垃圾邮件检测、隐藏字段等。如果您不知所措,请拿出验证码;甚至可能是暂时的。你的热狗摊联系页面不值得浪费人们的时间......

Don't use captcha until you have to. Most sites are not important enough to waste people's time and and attention jumping through hoops. This particularly applies if you are trying to sell something, rather than providing a free service.

Just making your form non-standard is enough. Unless you're important enough to attract someone to write code specific to your site, you can block every generic spammer by including a field labelled "please type the word orange".

If you're big enough to be targeted, start implementing behavioral spam detection, hidden fields and so on. If you're overwhelmed, the bring out the captcha ; possibly even temporarily. Your hot dog stand contact page does not deserve to waste people's time......

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文