正如标题所说,我很难在 Ubuntu 中启用 AllowEncodedSlashes
我把
AllowEncodedSlashes On
在/etc/apache2/apache2.conf 和/etc/apache2/sites-available/default 里面,但是在访问带有编码斜杠的 url 之后仍然有 404 页
最佳答案
我一直在寻找这个。但是找不到 Ubuntu 14.4 和 Apache 2.4.7 的明确答案。我想到了。这是我所做的:
转到 /etc/apache2/sites-available
打开 000-default.conf 文件。
添加AllowEncodedSlashes NoDecode
在<VirtualHost>
里面标签
保存并重启 Apache。
** apache2.conf
不需要修改。仅修改 000-default.conf
文件而不是 default-ssl.conf
关于apache - 如何在 ubuntu 中启用 AllowEncodedSlashes,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/36512851/