[英]Tomcat 403 Error
Here's my tomcat-users.xml
: 这是我的
tomcat-users.xml
:
<?xml version='1.0' encoding='utf-8'?>
<tomcat-users>
<role rolename="tomcat"/>
<role rolename="role1"/>
<role rolename="admin"/>
<role rolename="manager"/>
<user username="tomcat" password="tomcat" roles="tomcat"/>
<user username="MyAdmin" password="pswd" roles="admin,manager"/>
</tomcat-users>
I restart tomcat and go to localhost:8080/manager
. 我重新启动tomcat并转到
localhost:8080/manager
。 It asks me to log in. I enter the admin/manager credentials (u = MyAdmin and p = pswd) and it fails, giving me the following 403: 它要求我登录。我输入管理员/管理员凭据(u = MyAdmin和p = pswd),但操作失败,显示以下403:
Whats going on here? 这里发生了什么? I'm almost 100% sure I have the XML configured right!?!
我几乎100%确定我已正确配置XML !!! Is it possible something else isn't configured properly?
是否有其他可能配置不正确?
I just realized from your screenshot you are using Tomcat 7. Roles have changed a little bit. 我刚刚从您的屏幕快照中意识到您正在使用Tomcat7。角色有些变化。 See the updated documentation
请参阅更新的文档
You can find the role names in the web.xml file of the Manager web application.
您可以在Manager Web应用程序的web.xml文件中找到角色名称。 The available roles are:
可用角色为:
manager-gui — Access to the HTML interface.
manager-gui-访问HTML界面。
manager-status — Access to the "Server Status" page only.
manager-status-仅访问“服务器状态”页面。
manager-script — Access to the tools-friendly plain text interface that is described in >this document, and to the "Server Status" page.
manager-script —访问本文档中描述的工具友好的纯文本界面,以及“服务器状态”页面。
manager-jmx — Access to JMX proxy interface and to the "Server Status" page.
manager-jmx-访问JMX代理界面和“服务器状态”页面。
update your role to the appropriate setting. 将您的角色更新为适当的设置。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.