[LRUG] Spammers

Philip Cowans pcowans at gmail.com
Wed Sep 3 13:26:46 PDT 2008


2008/9/3 David Nolan <dave at textgoeshere.org.uk>
>
> What I'd like the list's advice on is what to render on spam submission, and how to implement it.
>
> - normal model validation, non-model spam? accessor, custom ActiveController::SpammyMiscreant exception caught in the controller, ...?
> - render http status 500, 404, 200 or something else?
> - if 200, render nothing, a normal form error message, or something else?

I'd either render a regular 200 response explaining why it has been
blocked, and ideally giving instructions on how to get support if the
request is acually non-spam, or a 403 status code with an error page
containing the same information. The easy way to implement this would
presumably just be to do an explicit render with a status code in the
controller.

Phil



More information about the Chat mailing list