首页 > 其他 > 详细

joomla在centos8+lnmp1.7升级

时间:2020-09-19 18:38:18      阅读:78      评论:0      收藏:0      [点我收藏+]

1.lnmp1.7添加vhost时不能使用pathinfo模式,否则出错

2.joomla伪静态找到解决方法

http://www.vuln.cn/2738

真正解决方法

在/usr/local/nginx/conf/rewrite下建一个conf伪静态配置文件,如:joomla.conf,内容如下:

if ( $args ~ "mosConfig_[a-zA-Z_]{1,21}(=|\%3d)" ) {
 set $args "";
 rewrite ^.*$ http://$host/index.php last;
 return 403;}
 
 if ( $args ~ "base64_encode.*\(.*\)") {
 set $args "";
 rewrite ^.*$ http://$host/index.php last;
 return 403;}
 
 if ( $args ~ "(\|%3E)") {
 set $args "";
 rewrite ^.*$ http://$host/index.php last;
 return 403;}
 
 if ( $args ~ "GLOBALS(=|\[|\%[0-9A-Z]{0,2})") {
 set $args "";
 rewrite ^.*$ http://$host/index.php last;
 return 403;}
 
 if ( $args ~ "_REQUEST(=|\[|\%[0-9A-Z]{0,2})") {
 set $args "";
 rewrite ^.*$ http://$host/index.php last;
 return 403;}
 
 if (!-e $request_filename) {
 
 rewrite (/|\.php|\.html|\.htm|\.feed|\.pdf|\.raw|/[^.]*)$ /index.php last;
 break;
 }

在/usr/local/nginx/conf/vhost/的相应www.xx.conf文件中添加一

include rewrite/joomla.conf;

重启lnmp

joomla在centos8+lnmp1.7升级

原文:https://www.cnblogs.com/yusam/p/13697007.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!