如何登录使用密码Tomcat Administration?
2015-02-09 00:00
513 查看
如何登录Tomcat Administration? 按照页面的帮助文档: You are not authorized to view this page. If you have not changed any configuration files, please examine the file conf/tomcat-users.xml in your installation. That file must contain the credentials to let you use this webapp. For example, to add the manager-gui role to a user named tomcat with a password of s3cret, add the following to the config file listed above. <role rolename="manager-gui"/> <user username="tomcat" password="s3cret" roles="manager-gui"/> Note that for Tomcat 6.0.30 onwards, the roles required to use the manager application were changed from the single manager role to the following four roles. You will need to assign the role(s) required for the functionality you wish to access. manager-gui - allows access to the HTML GUI and the status pages manager-script - allows access to the text interface and the status pages manager-jmx - allows access to the JMX proxy and the status pages manager-status - allows access to the status pages only The HTML interface is protected against CSRF but the text and JMX interfaces are not. To maintain the CSRF protection: The deprecated manager role should not be assigned to any user. Users with the manager-gui role should not be granted either the manager-script or manager-jmx roles. If the text or jmx interfaces are accessed through a browser (e.g. for testing since these interfaces are intended for tools not humans) then the browser must be closed afterwards to terminate the session. 我们可以知道,修改conf/tomcat-users.xml文件,可以实现用户密码与权限的分配,目前有四种角色可以设置: manager-gui 允许用户访问HTML来看tomcat的状态页面 manager-script 允许用户访问命令界面(不能GUI看)和查看tomcat的status页面 manager-jmx 允许用户查看JMX代理和状态页面 manager-status 仅允许用户查看状态页面 默认情况下,是没有设置任何的密码与用户的,需要你自己设置 。 一、过时的经理用户不能分配给任何用户,现在为用户设置一个管理角色: #vim /usr/local/tomcat/conf/tomcat-users.xml <role rolename="manager-gui"/> <user username="cheng" password="redhat" roles="manager-gui"/> 二、重启tomcat,测试!可以尝试打开status,Tomcat Manager页面进行测试!
相关文章推荐
- 如何登录使用密码Tomcat Administration?
- Ubuntu root默认密码?及如何使用root登录.
- jenkins发布项目到远程主机上,配置两台linux如何使用SSH免密码登录
- jenkins发布项目到远程主机上,配置两台linux如何使用SSH免密码登录
- Ubuntu 12.04 root默认密码? 如何使用root登录?
- 如何使用H5判断登录页面手机号码长度是否正确和账号密码不能为空,从而减少对服务器的请求(注册也一样)
- 如何使用PLSQL添加用户和密码,登录时可以免输入密码 PLSQL配置新数据库连接
- Ubuntu 12.04 root默认密码? 如何使用root登录?
- Ubuntu 12.04 root默认密码? 如何使用root登录?
- SVN客户端(TortoiseSVN)保存密码自动登录后,如何切换使用其它帐户登录方法
- Ubuntu 12.04 root默认密码? 如何使用root登录? (转载)
- 浅谈:如何用C#实现简单的带有验证码及密码使用MD5加密的“登录”WinForm小程序
- 如何解决“HTTP 错误 500.19 无法使用虚拟目录密码作为用户 administrator 在本地登录到”?
- Ubuntu 12 root默认密码? 如何使用root登录
- 如何使用PLSQL添加用户和密码,登录时可以免输入密码 PLSQL配置新数据库连接
- eclipse 中main()函数中的String[] args如何使用?通过String[] args验证账号密码的登录类?静态的主方法怎样才能调用非static的方法——通过生成对象?在类中制作一个方法——能够修改对象的属性值?
- 如何使用Xshell秘钥认证登录CentOS(无密码登录)
- SVN客户端(TortoiseSVN)保存密码自动登录后,如何切换使用其它帐户登录方法
- Ubuntu 12.04 root默认密码? 如何使用root登录?
- Ubuntu 12.04 root默认密码? 如何使用root登录?