Unlike letting the other party know their real webserver environment, they have to modify our webserer software! Sometimes we have to modify our webserer software to disguise our real server environment! Today, I checked the webserver of baidu.com and thought it was modified by nginx.
C: \ curl-7.18.0> curl.exe-I www. baidu. comHTTP/1.1 200 OKDate: Tue, 11 Mar 2008 05:00:39 GMTServer: BWS/1.0Content-Length: 3022Content-Type: text/htmlCache-Control: privateExpires: Tue, 11 Mar 2008 05:00:39 GMTSet-Cookie: BAIDUID = 41BB2845D3E8BC1AEE99D4CECB90C50A: FG = 1; expires = Tue, 11-8 05:00:39 GMT; path =/; domain =. baidu. comP3P: CP = "oti dsp cor iva our ind com"
Ha just feels that people may develop their own products with strong development backing! So I flipped through the nginx source code and found that it was easy to modify.
Cd/usr/local/src/nginx-0.5.35/src/core/[root @ zyatt core] # cat nginx. h/** Copyright (C) igor Sysoev */# ifndef _ nginx_h_encoded _ # define _ defined _ # define NGINX_VERSION "1.0" # define NGINX_VER "LPKWS/" NGINX_VERSION # define NGINX_VAR "LPKWS" # define limit ". oldbin "# endif/* _ NGINX_H_INCLUDED _*/
Test results
C: \ curl-7.18.0> curl.exe-I 211.100.11.122/info. php (this Nginx is not optimized and expires and gzip are configured for testing only) HTTP/1.1 200 OKServer: LPKWS/1.0 Date: Tue, 11 Mar 2008 04:53:02 GMTContent-Type: text/htmlTransfer-Encoding: chunkedConnection: keep-aliveKeep-Alive: timeout = 20X-Powered-By: PHP/5.2.4
Ha, just for entertainment. to really optimize and consider security, you should read the source code carefully and do a good job in detail!