简体   繁体   English

Nginx路由是否涵盖了最终/之后的内容

[英]Does nginx routing cover what’s after the final /

如果我在/上设置了一个nginx规则,那么如果有人想滥用对该路由的POST请求,该规则还涵盖/classes/User吗?

Yes, if you set it up like this: 是的,如果您这样设置:

location / {
    ...
}

Then that will match every url that starts with / and does not match a more specific location. 然后,它将匹配以/开头且不匹配更特定位置的每个url。

You can read more about the different location matching configurations on the nginx docs 您可以在Nginx文档上阅读有关不同位置匹配配置的更多信息

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM