skypanther
Exalted Code Master!
I'm afraid my CFML is a bit rusty, as I mostly do PHP nowadays. One of my client's forms is being hijacked by spammers. In this case, it's a "tell a friend" form with an accompanying action page which does the actual mailing. The spammers are "stuffing" the send-mail page, bypassing the entry form.
In PHP, I use the following to prevent such attacks:
Which basically checks for a match between the host name of the referrer (form page) and that of the current page (send-mail page). If they don't match, the user is redirected.
How would I do this in CFML?
Many thanks,
Tim
In PHP, I use the following to prevent such attacks:
PHP:
if(strpos($_SERVER['HTTP_REFERER'], $_SERVER['HTTP_HOST']) === FALSE) {
header('location:index.php');
die();
}
Which basically checks for a match between the host name of the referrer (form page) and that of the current page (send-mail page). If they don't match, the user is redirected.
How would I do this in CFML?
Many thanks,
Tim