[英]Jetty returning 403 Forbidden
Hi I am porting my web app from tomcat to Jetty. 嗨,我将我的网络应用程序从tomcat移植到Jetty。 I am using the Jetty runner to launch it. 我正在使用Jetty跑步者来启动它。 I am using the following command to launch Jetty: 我使用以下命令启动Jetty:
java -jar jetty-runner.jar --port --path url-path path-to-war java -jar jetty-runner.jar --port --path url-path path-to-war
However when I try to browse to the from the browser I get the following error: 但是当我尝试从浏览器浏览到时,我收到以下错误:
HTTP ERROR 403 HTTP错误403
Problem accessing . 访问问题。 Reason: 原因:
Forbidden
In the logs i see the following Warning: 在日志中,我看到以下警告:
WARN:oejs.SecurityHandler:No authenticator for: {RoleInfo,C[*, all_auth_users]} 警告:oejs.SecurityHandler:没有以下身份验证器:{RoleInfo,C [*,all_auth_users]}
I am trying to use Jetty out of the box and haven't customized any config anywhere. 我试图开箱即用Jetty并没有在任何地方定制任何配置。 Is there any additional configuration required to make this work? 是否需要任何其他配置才能使其工作?
Likely cause: your war/webapp has security constraints defined, but you haven't specified what authentication type to use on the server side. 可能的原因:您的war / webapp已定义安全性约束,但您尚未指定在服务器端使用哪种身份验证类型。
Either: 或者:
<security-constraint>
in your war/webapp WEB-INF/web.xml
file. 删除war / webapp WEB-INF/web.xml
文件中的<security-constraint>
。 or.. 要么.. etc/jetty-testrealm.xml
for an example using the HashLoginService authenticator. 使用HashLoginService身份验证器查看etc/jetty-testrealm.xml
以获取示例。 In my case I forget that paste the index.html example page. 在我的情况下,我忘了粘贴index.html示例页面。 Its all. 这一切。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.