The password is dependent on what role you map the contextAdmin servlet
to.

In the the web.xml file of the 'admin' application the role it's mapped
to is called 'admin'.

To enable the application, you need to add an 'admin' role to the
tomcat-users.xml file (located in <TOMCAT_HOME>/conf
(if you're using the SimpleRealm, otherwise you need to add it to the
JDBC database you're using for JDBCRealm support)
I usually add it to the 'tomcat' user. e.g.:

<!-- add 'admin' role to one of the following users to enable
contexAdmin servlet -->
<tomcat-users>
  <user name="tomcat" password="tomcat" roles="tomcat,admin" />
  <user name="role1" password="tomcat" roles="role1" />
  <user name="both" password="tomcat" roles="tomcat,role1" />
</tomcat-users>

Note that case is significant.
If you do so , then the user will be 'tomcat' and the password will be
'tomcat' as per the entry in the tomcat.users file.

P.s. also remember to set the Context trusted attribute to 'true' in
server.xml.
e.g.:

        <Context path="/admin"
                 docBase="webapps/admin"
                 crossContext="true"
                 debug="0"
                 reloadable="true"
                 trusted="true" >
        </Context>



Cheers,

-Thom



Jeff Sum wrote:

> what's the default password of context admin??

Reply via email to