mod wsgi - Apache removing spaces before slashes in the PATH of an URI - Stack Overflow

I cannot find it anywhere, nor in the source code of Apache nor on any page references for this happeni

I cannot find it anywhere, nor in the source code of Apache nor on any page references for this happening, but somehow Apache normalizes URIs

from

 /with/space

into


as seem from a django application routed via wsgi.

When using gunicorn (also wsgi) or django's runserver, this normalization does not happen and the code returns 404. With Apache, the space before a slash is removed. I verified via a middleware which shows different results on Apache and Gunicorn/Runserver.

Apache does not normalize spaces anywhere else but right before a slash. Every other space is kept as is.

The RFC 3968 does not say anything about this under the normalization topic (ref).

The Apache source code for ap_normalize_path does not have anything regarding space before slash normalization. It only seems to normalize multiple slashes and dots.

It might be possible mod_wsgi is the culprit here, but I also did not find anything relevant.

发布者:admin,转转请注明出处:http://www.yc00.com/questions/1744650285a4585858.html

相关推荐

发表回复

评论列表(0条)

  • 暂无评论

联系我们

400-800-8888

在线咨询: QQ交谈

邮件:admin@example.com

工作时间:周一至周五,9:30-18:30,节假日休息

关注微信