web.xml 独占 url 模式

发布于 2024-12-27 11:42:34 字数 174 浏览 1 评论 0原文

我想限制对整个应用程序的访问 /* 但对于某些 Servlet 则不然。它们应该是公开的。

有没有一种方法可以轻松做到这一点(我想象一些排除或可能覆盖?)或者我是否必须将文件排列在子文件夹中并允许访问一个文件,同时限制另一个文件?

I want to restrict access to the whole application
<url-pattern>/*</url-pattern>
But not to some Servlets. They should be public.

Is there a way to do that easily (I imagine some exclusion or maybe overriding?) or do I have to arrange files in subfolders and allow access to one while restricting to the other?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

ま昔日黯然 2025-01-03 11:42:34

有没有办法轻松做到这一点(我想象有一些排除或可能覆盖?)

没有。


或者我是否必须将文件排列在子文件夹中并允许访问其中一个而限制另一个?

是的。

Is there a way to do that easily (I imagine some exclusion or maybe overriding?)

No.


or do I have to arrange files in subfolders and allow access to one while restricting to the other?

Yes.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文