4 ms·
Me too, kind of. I have nginx reply with a 418 page to bad bots requests. Funny easter egg. As a bonus, that makes nginx avoid checking the filesystem for inex
by palsecam 6y ago
Me too, kind of.
I have nginx reply with a 418 page to bad bots requests. Funny easter egg. As a bonus, that makes nginx avoid checking the filesystem for inexistent files, and makes filtering logs easier.
Nginx config snippet:
# Nothing to hack around here, I’m just a teapot:
location ~* \.(?:php|aspx?|jsp|dll|sql|bak)$ {
return 418;
}
error_page 418 /418.html;
Example: https://FreeSolitaire.win/wp-login.php https://FreeSolitaire.win/wp-login.php
- OldHand2018 6y agoNice. I used to use that for all php requests to my websites (like you, I do not have php installed on my servers). Now I just use the nginx 444, which immediately drops the connection. I wonder if it actually saves much time. Probably not.