Return 429 Too Many Requests for rate limiting

This commit is contained in:
Brian Quinion 2014-01-23 16:47:56 +00:00
parent f56cae4291
commit 8ecd32b7dd

View File

@ -54,6 +54,7 @@
if (strpos(CONST_BlockedIPs, ','.$_SERVER["REMOTE_ADDR"].',') !== false || $fBucketVal >= CONST_ConnectionBucket_BlockLimit)
{
header("HTTP/1.0 429 Too Many Requests");
echo "Your IP has been blocked. \n";
echo CONST_BlockMessage;
exit;