Home
Operation and Maintenance
Nginx
How to modify the Nginx version name to disguise any web server



How to modify the Nginx version name to disguise any web server
web
nginx
server
How to modify the default name of nginx, you can disguise it a little, or you can install There is a ngx_http_special_response.c.
Tips: Generally, modifications are made before nginx is compiled. After modification, you need to recompile
The code is as follows:
#define nginx_version "1.4.7"
#define nginx_ver "nginx/" nginx_version
is modified to: (In fact, the version number can also be modified at will)
The code is as follows:
#define nginx_ver "jdws/" nginx_version
In fact, modifying most of the above will take effect ! ! !
The code is as follows:
static char ngx_http_server_string[] = "server: nginx" crlf;
Modify to:
/src/http/ngx_http_special_response.c
static u_char ngx_http_error_tail[] ="
"