99精品国产综合久久久久五月天,免费观看欧美大片毛片不用播放器 ,AV无码理论片在线观看免费网站,国产精品国产成人国产三级

Board logo

標(biāo)題: [BUG反饋] nginx,N+A組合的WEB引擎中,rewrite功能用不了么? [打印本頁]

作者: hotmy    時(shí)間: 2017-5-23 17:37     標(biāo)題: nginx,N+A組合的WEB引擎中,rewrite功能用不了么?

如何設(shè)置呢?
作者: hotmy    時(shí)間: 2017-5-27 16:29

方法:
1、增加rewrite規(guī)則文件
名稱:joomla_nginx.conf
內(nèi)容如下:
  1. if ( $args ~ "mosConfig_[a-zA-Z_]{1,21}(=|\%3d)" ) {
  2. set $args "";
  3. rewrite ^.*$ http://$host/index.php last;
  4. return 403;}

  5. if ( $args ~ "base64_encode.*\(.*\)") {
  6. set $args "";
  7. rewrite ^.*$ http://$host/index.php last;
  8. return 403;}

  9. if ( $args ~ "(\|%3E)") {
  10. set $args "";
  11. rewrite ^.*$ http://$host/index.php last;
  12. return 403;}

  13. if ( $args ~ "GLOBALS(=|\[|\%[0-9A-Z]{0,2})") {
  14. set $args "";
  15. rewrite ^.*$ http://$host/index.php last;
  16. return 403;}

  17. if ( $args ~ "_REQUEST(=|\[|\%[0-9A-Z]{0,2})") {
  18. set $args "";
  19. rewrite ^.*$ http://$host/index.php last;
  20. return 403;}

  21. if (!-e $request_filename) {

  22. rewrite (/|\.php|\.html|\.htm|\.feed|\.pdf|\.raw|/[^.]*)$ /index.php last;
  23. break;
  24. }
復(fù)制代碼
2、在創(chuàng)建站點(diǎn)或編輯站點(diǎn)的“支持rewrite”選項(xiàng)下選擇文件 joomla_nginx.conf
保存即可。

以上內(nèi)容存檔共勉




歡迎光臨 WDlinux官方論壇 (http://fudaan.com/bbs/) Powered by Discuz! 7.2