tomcat7.0.11managerapphostmanager访问错误密码确保无误401UnauthorizedYouarenotauthorizedtoviewthispage.Ifyouhavenotchangedanyconfigurationfiles,pleaseexaminethefileconf/tomcat-users.xmlinyourinstallation.Thatfi
tomcat7.0.11managerapphostmanager访问错误密码确保无误
401Unauthorized
Youarenotauthorizedtoviewthispage.Ifyouhavenotchangedanyconfigurationfiles,pleaseexaminethefileconf/tomcat-users.xmlinyourinstallation.Thatfilemustcontainthecredentialstoletyouusethiswebapp.
Forexample,toaddthemanager-guiroletoausernamedtomcatwithapasswordofs3cret,addthefollowingtotheconfigfilelistedabove.
NotethatforTomcat7onwards,therolesrequiredtousethemanagerapplicationwerechangedfromthesinglemanagerroletothefollowingfourroles.Youwillneedtoassigntherole(s)requiredforthefunctionalityyouwishtoaccess.
•manager-gui-allowsaccesstotheHTMLGUIandthestatuspages
•manager-script-allowsaccesstothetextinterfaceandthestatuspages
•manager-jmx-allowsaccesstotheJMXproxyandthestatuspages
•manager-status-allowsaccesstothestatuspagesonly
TheHTMLinterfaceisprotectedagainstCSRFbutthetextandJMXinterfacesarenot.TomaintaintheCSRFprotection:
•Userswiththemanager-guiroleshouldnotbegrantedeitherthemanager-scriptormanager-jmxroles.
•Ifthetextorjmxinterfacesareaccessedthroughabrowser(e.g.fortestingsincetheseinterfacesareintendedfortoolsnothumans)thenthebrowsermustbeclosedafterwardstoterminatethesession.
Formoreinformation-pleaseseetheManagerAppHOW-TO.