1.

In Nginx How You Can Prevent Processing Requests With Undefined Server Names?

Answer»

A server that just drops the REQUESTS can be defined as Server
{
listen 80;
server_name “ “ ;
return 444;
}
Here the server name is kept as an EMPTY string which will match request without the “Host” header FIELD, and a SPECIAL Nginx’s non­standard code 444 is RETURNED that terminates the connection.

A server that just drops the requests can be defined as Server
{
listen 80;
server_name “ “ ;
return 444;
}
Here the server name is kept as an empty string which will match request without the “Host” header field, and a special Nginx’s non­standard code 444 is returned that terminates the connection.



Discussion

No Comment Found